What to do next

I got a lamp to turn on and off with the esp8266 what project do I do next nothing to complicated I am still a beginner

You’ve mastered the writing, congrats. As a next step - you can try reading sensor data and display it in the Blynk app.

Get another esp8266 and play with the bridge… Turn your lamp on and off with the bridge that will turn on an LED on the Blynk app from the bridge telling you that the lamp is on. Love the bridge… one of my favorite features in Blynk.

I already turned on and off a lamp with blynk

What I was trying to say… use two esp8266 and create a bridge between them. Connect the lamp to the slave, the master will turn on pin 5 on the slave and turn on an LED on the app telling you the lamp is on. Start with this then try different things… connect a sensor to the slave…

The slave cannot be controlled directly from the app… it must be controlled through the master… You cannot send data directly to the app from the slave… it must be sent through the master… :grinning: lots of fun…

//The reads the state of a Button in the App assigned to virtual pin 3 BLYNK_WRITE(3) { int a = param.asInt(); if (a == 0) { //Turn Off pin 5 on the other device bridge1.digitalWrite(5, LOW); } else { //Turns on pin 5 on the other device bridge1.digitalWrite(5, HIGH); } //Turns on a LED connected to Vitrual pin 10 in the mobile App Blynk.virtualWrite(10, a); }

To run a home automated system, or a security system, you will need a bunch of slaves bridged to the master.

1 Like

I agree with @steelgoose here. Bridging is essential functionality to wire up your house. You can try and transfer sensor data from one bridge to another. You might imagine you have a wireless temperature sensor in your garden or humidity in your garage and want to display the data on a central unit :slight_smile:

Hey All,

I am also in a situation like this. I can automate a room now !! thanks for the support. But I have some ideas right now. Can you direct me correctly ? I have a got led strips (RGB) which can be controlled by blynk. Thats Awesome to play around. But I want 2 modes for it :

  1. Controlling it from blynk
  2. Make it react to music

There are plenty of tutorials for 2. Can you tell me how to incorporate the program to blynk ? Like adding the code for 2. and then switching between 1 and 2 with a button widget or something similar .

This sounds (get it … hehe) like a good idea. I have no idea how to have it react to music, but that shouldn’t be to hard I guess.

I suggest you start using your own ideas and ask here when things don’t work or if you can’t figure out some part of the code or something else is not working.

Asking to give us technical info and code in two sentences is not something we can do. We can guide you, but you have to start something on your own :slight_smile:

That was exactly what I had in mind Lichtsignaal. I know the code for making it react to music. I wanted to know how I could incorporate the code along with blynk

Indirect thanks !!! I just found this ! I will replace that code with the music reactive code (y).

Basically, you can make a button on your dashboard in Switch mode. This button will go on/off instead of in Push mode. When in Switch mode it will send a number once and stay that way, e.g. pressed down or not. In Push mode it will only send the value as long as you press it.

Thanxx ! But let me get more precise. I have got an rgb led. It is being controlled by the zebra widget. Working fine. Now I have the code for making it react to music. And it also needs access to the rgb wires. Can you please suggest a method to incorporate the music reactive code without conflicting with the zebra widget ? I want make the led work in any one of the two ways mentioned above. Thank you again

Just add a switch button in Blynk app and attach it to Virtual Pin. If it’s ON - start the “Music” function and if it’s off - stop the function.

Use Virtual Pins for that. http://docs.blynk.cc/#blynk-main-operations-virtual-pins

Many Thanks Pavel :smiley: . But ill also be having the Zebra widget controlling it.Wont there be a conflict ? Or is there a piece of code that can block the zebra widgets access to the RGB pins ?

Well, it depends on how you write your code, right? :wink:

It shouldn’t be a problem as long as you don’t touch the Zebra :horse:

Or add a lion and have the Zebra eaten … :smile_cat:

HAHA ! Good one. Ok thank you all alot for the answers. One last query. If I manually change the state of a pin by coding the arduino, will the status get reflected in blynk ? Like I have pin13 button in blynk app and it is currently pushed ON (HIGH). Now in arduino i wrote digitalWrite(13, LOW) ; somewhere in a function. Will the blynk button be switched back ?!

you can use the Blynk.sync() function for that :slight_smile: Blynk.SyncAll syncs all pins I think. It should be in the latest documentation :slight_smile: