Bluetooth & AppInventor (1)


Hello, today we're gonna explain ho to create an app with Appinventor and how to communicate it with Arduino . We connect bluetooth module to Arduino like we told you at  last post with mobile's bluetooth trought a simple app with Appinventor.

First we create a little program for Arduino, only to send an order via Bluetooth and do something easy with Arduino board, for example switch LED on/off .

We will use the next program : 



#define txPin 3 // definimos txpin en que pin de arduino se encuentra
#define rxPin 2 // definimos rxpin en que pin de arduino se encuentra 

SoftwareSerial bluetooth(rxPin, txPin); // el puerto nuevo de comunicacion se llamar bluetooth

char NOMBRE[10]  = "TEST1";  // asignamos un nombre a nuestro modulo bluetooth para cuando lo veamos en linea 
char BPS         = '4';           // 1=1200 , 2=2400, 3=4800, 4=9600, 5=19200, 6=38400, 7=57600, 8=115200
char PASS[10]    = "1234";   // password para realizar la conexion. Sino funciona 0000
char INBYTE;
int  LED = 13; // LED on pin 13 // hacemos que el led 13 de Arduino integrado nos sirva de prueba

void setup() {
  Serial.begin(9600); // velocidad de la comunicacion entre arduino y ordenador 
 Serial.println("Estoy preparado"); //mensaje de comprobacion
   pinMode(LED, OUTPUT);
  bluetooth.flush();            // Borramos el buffer del serial para evitar errores
  pinMode(rxPin, INPUT);     // Configuramos los pines del bluetooth 
  pinMode(txPin, OUTPUT);
  bluetooth.begin(9600);  // marcamos la velocidad del puerto bluetooth 

void loop()
  while (!bluetooth.available());   // mientras el puerto este disponible ejecuta el programa
  INBYTE =;        // lee la comunicacion bluetooth
  if( INBYTE == '2' ) 
      digitalWrite(LED, LOW);  // si pulsas el numero 3 escribe en el led apagado
      bluetooth.println("Has presionado 2"); //muestra en el ordenador que tecla se ha pulsado
  if( INBYTE == '1' ) 
    digitalWrite(LED, HIGH); // si pulsas el numero 4 escribe led encendido
    bluetooth.println("Has presionado 1");
The line "if INBYTE ==…. then …" told us what happend when you push 1 or 2 on keyboard. If you push 1 on app button then switch ON LED and when you push 2 on app button then switch OFF LED. 

(Download program)

Now e have finished the program, let's go to create the app on Appinventor. We create a new project and we drag and drop two buttons, one dor switch ON and switch OFF.

Now we change the name of the buttons (optional) 

We arrange the buttons horitzontaly

We add a "list pick" to create the "bluetooth connect button". The button will change the color when bluetooth is active (that's it because we need a list pick instead a simple button)

We add bluetooth to screen 

After that we work with Block Appinventor (top right) and we start to program our app.

This is the bluetooth block . We could see that we check the bluetooth connection first and if is correct the bluetooth change to blue color. 

The two last blocks are create to send the character "1" and "2" to switch ON or OFF our LED in the Arduino board. As you can see we can send whatever character you want, then you could add more functions to send at arduino board. 

After these steps we create a QR code  , we download the app to mobile 

When we open th app we push "conexión" and we could see the MAC of bluetooth module. Then we connect (maybe you have to use the password 1234 or 1111 ). The red led on bluetooth module stops blinking and then is connect correctly.

We test the buttons ON and OFF and we could see how it switch ON or OFF LED


See you in the next article



We are a group of volunteers and opening a brand new scheme in our community.
Your website provided us with helpful information to work on. You have performed a formidable task and our entire neighborhood can be thankful to

Feel free to visit my web-site: penis -

It is in reality a nice and helpful piece of information. I'm glad that
you simply shared this helpful info with us. Plerase keep us up to date like this.
Thanks for sharing.

My page; Fire Emblem Heroes hack 2015 mac -

We're a group of volunteers and opening a new scheme in our community.
Your website offered us with valuable information to
work on. You've done an impressive job and our whole community will be grateful to you.

dinero rapido -

Sobre las críticas que la oposición ha hecho al Gobierno por no haber garantizado la seguridad de los
espectadores que presenciaban los fuegos artificiales cuando fueron arrollados, Valls negó que
el dispositivo fuera insuficiente y señaló
que fue el mismo que estuvo actual en la Eurocopa en el Carnaval de esa ciudad.

Feel free to visit my site; donde hacer resonancia magnetica
zona norte -

You actually make it appear really easy together with your presentation however I to find
this topic to be actually something that I think I'd never understand.
It kind of feels too complex and extremely broad for me.
I am taking a look ahead to your next post, I will
attempt to get the grasp of it!

Feel free to surf to my webpage; Foot Corns -

It's awesome to go to see this web page and reading the views
of all mates regarding this piece of writing, while I am also keen of getting

creditos rapidos con asnef y rai -

What's up everybody, here every person is sharing these kinds of know-how, therefore it's fastidious to read this blog, and I used to visit this web site all
the time.

mini prestamos -

Link exchange is nothing else however it is simply placing
the other person's blog link on your page at appropriate place and
other person will also do similar in support of you.

wholesale jerseys -

Hi Dear, are you actually visiting this web page daily, if so after that you will definitely get pleasant

Here is my blog Delores -

I like what you guys are up too. This sort of clever work and coverage!
Keep up the excellent works guys I've you guys to my blogroll.

Feel free to surf to my blog post Hampson Hughes -

So you, as the restorer, have to set realistic goals as to exactly what parts of the car you
are going to restore to their original states and what parts of the car you are willing to restore "as close as possible" to their original states.

The turbo 4-banger in the Volkswagon GTI Mk5 is fairly unique among such engines in that
it produces huge amounts of torque at a relatively low number of RPMs.
Listed here are some interesting facts about Mercedes-Benz.

My website make money blogging -

whoah this weblog is great i love studying your posts.

Keep up the good work! You understand, lots of persons are searching
around for this info, you can aid them greatly.

creditos rapidos con asnef y rai -

Attractive component of content. I just stumbled upon your web site and in accession capital
to say that I acquire actually enjoyed account your weblog
posts. Any way I will be subscribing in your feeds or even I success you access constantly quickly.

creditos rapidos sin aval -

You wiⅼl notice that tɦe majority of heг pugs not drugs t shirt mens - Jed - , Һas changed
colour, but there is nonetheless ѕome red remaining оn the stripes օf her shirt, aroᥙnd the edges and оn her fingernails.

Great goods from you, man. I have remember your stuff previous to and you're simply too excellent.

I really like what you have obtained right here, certainly like what you're stating and the
way social media companies in delhi - which through which you say it.

You make it entertaining and you still care for to stay it wise.
I can't wait to read far more from you. This is actually a tremendous website.

This is very interesting, You're a very
skilled blogger. I have joined your rss feed and look forward
to seeking more of your magnificent post. Also, I've shared your web site in my social networks!

creditos rapidos online sin aval -

The proceeds of selling your older car can go to the operations of the charity like giving food or
clothing to the family that they supported.
Be smart and savvy when negotiating the interest rate for new
cars and don't just sign on the bottom line. It includes 4 different frequencies so you can race against your friends.

My page :: signage company -

You should be a part of a contest for one of the finest websites on the net.
I most certainly will highly recommend this site!

creditos rapidos online asnef -

Hi, I do believe this is an excellent website.

I stumbledupon it ;) I will return once again since I book-marked it.
Money and freedom is the best way to change, may you be rich and continue to help other people.

créditos rápidos urgentes -

Doᥱs уߋur blog havᥱ a contact page?

I'm Һaving trouble locating іt but, ӏ'd
like to shooot you an email. I've got somе suggestions for үour blog you might
be interested іn hearing. Εither աay,
ցreat site aand Ι ⅼook forward tо seeing it improve ⲟveг time.

Feel free to visit mү weblog :: cham soc daa -

I'd like to find out more? I'd love to find out more details.

cheap jerseys -

Along with the car sales, the Japanese used car sellers also supply the dismantled parts of the vehicles in cube containers of size 20ft or 40 ft.
Driven aggressively, the cars will run out of power in about 30 minutes.
According to Campbell Fuller, spokesman for the ICA, buyers need to contact their insurer before agreeing to a

Here is my blog post; C9 Highlights -

Today, I went to the beach with my kids. I found valentines day wishes for a son - sea shell and gave it to my 4 year old daughter and said "You can hear the ocean if you put this to your ear." She placed the shell to her ear and screamed.
There was a hermit crab inside and it pinched her ear.
She never wants to go back! LoL I know this is entirely off topic but I
had to tell someone!

The warranties for some branded cars may go up to 3 or 4 years depending on the model.
The turbo 4-banger in the Volkswagon GTI Mk5 is fairly unique among such engines in that it
produces huge amounts of torque at a relatively low number of
RPMs. It is available in two versions of petrol and diesel and has been a very reasonable price.

Feel free to surf to my web blog; oat bran -

you are actually a just right webmaster. The website loading velocity
is incredible. It sort of feels that you're doing any unique trick.
Furthermore, The contents are masterwork. you've done a great
process in this matter!

prestamos online -

The proceeds of selling your older car can go to the operations of the charity like giving food or clothing to the family that they supported.
Now you will soon forget about key-fobs as well since new biometric revolution is going to allow you to
enter your car with your fingerprint, face detection or eyeball recognition. The damage varies from vehicle to vehicle but can be as small as light hail damage which
is barely visible through to damage caused by falling trees.

Feel free to surf to my blog post :: toronto contest prep
coach -

I'll right away snatch your rss as I can not find your
e-mail subscription hyperlink or e-newsletter service.
Do you have any? Kindly allow me recognise in order that I may
subscribe. Thanks.

Check out my web page: xem them -

Truly no matter if someone doesn't understand afterward its up to other viewers that
they will assist, so here it happens.

Feel free to visit my homepage: hotlink red 2017 -

You can also have the train that the creature
ride on within the TV series. For example, fur boots present the perfect
mixture of functionality and fun. It is fun for the mother to determine that
her youngsters are being unified to produce something possible more than anything else if it is on her.

Visit my web page - revenue moel -

Costs there can be as minimal as $500 for your automobile
in a excellent situation. Driven aggressively, the cars will run out of power in about 30
minutes. Access Free Online Maps via Wi
- Fi or 3G network, such as Google Map.

Here is my blog post: Best way to make money online from
home in 2017 -

I’m not that much of a internet reader to be honest
but your sites really nice, keep it up! I'll go ahead and bookmark your site to come back down the road.
Many thanks
cheap MLB jerseys -

Pois se você ainda não teve a possibilidade de se dedicar a uma das formas mas divertidas de praticar futebol,
aproveite esta maré e também comece a praticar Soccer Stars.

Look at my blog post - Jogos online 3D ( - )

Useful info. Lucky me I found your website unintentionally, and I'm
surprised why this twist Side of Foot Pain - fate didn't came about earlier!

I bookmarked it.

If you desire to increase your knowledge just keep visiting this site and be updated
with the hottest gossip posted here.
cheap NFL jerseys -

Hmm it looks like your blog ate my first comment (it was extremely long)
so I guess I'll just sum it up what I had written and say, I'm thoroughly enjoying your blog.
I too am an aspiring blog writer but I'm still new to everything.
Do you have any suggestions for first-time blog writers?
I'd definitely appreciate it.

Here is my blog Toe Spreaders -

I pay a quick visit everyday some web pages and sites to read articles or reviews,
however this webpage gives quality based content.

creditos rapidos sin papeles -

you're in reality a just right webmaster. The web site loading velocity is amazing.
It kind of feels that you're doing any distinctive trick.
In addition, The contents are masterpiece. you have performed a great task on this matter!

creditos con asnef -

Everything typed was actually very reasonable. However, what about
this? what if you were to write a killer headline? I mean, I don't want to tell you how to run your
blog, however suppose you added a post title to possibly grab folk's attention? I mean Afegeix un nou comentari | gerdsLAB is kinda boring.
You ought to glance at Yahoo's home page and note how they write news titles to grab people to
click. You might add a video or a related picture or two to
grab people interested about everything've got to say.
Just my opinion, it could bring your website a little bit more interesting.

créditos rápidos faciles -

Paragraph writing iis alseo a fun, iff you be acquainted with afterward youu can wdite or else
it is complex to write.

Also visit my blog ... Fire Emblem Heroes Free android hack -

Helpful information. Lucky me I discovered your
web site unintentionally, and I am shocked why this coincidence didn't happened in advance!

I bookmarked it.

Review my blog post - Shoe Lifts -$1799__Silicone_Shoe_Lifts__Free_Delivery/p133745_317467.aspx

Wow, marvelous blog layout! How long have you been blogging for?
you make blogging look easy. The overall look of your site is magnificent,
as well as the content!

creditos rapidos con nomina -

A new technology introduced by one of the
biggest automobile companies, Volvo, will ensure that your car avoid accidents on the roads involving pedestrians.
Producing a very light car will drop its fuel consumption, and oil companies will not appreciate this.
It is available in two versions of petrol and diesel and has been a very reasonable

Here is my weblog: lotto predictions -

GPU de notebook ou GPU onboard raramente atinge mais de 75°C, pois resto da
placa-mãe não é feita para suportar altas temperaturas, por isso que um processador se desliga quando atinge em torno de 70°C.

Feel free to visit my blog post notebook acer americanas -

Touche. Great arguments. Keep up the good effort.

Feel free to visit my blog :: Lord Grabiner -


Add new comment

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.