The use of the ESP8266 in the world of IoT

User avatar
By TarekJ
#61793
Piira wrote:At least I can follow the link. I attached the demo that I just downloaded.
I have also seen some library for ESP8266 but that wasn't any good as it used delayMicrosecond() to time the signals and that causes to long execution time for many IR signals. The demo uses timers.


I need to do something that reads IR signal, saves it, transmits it, similar to this:
https://www.youtube.com/watch?v=HYpWGzBteQg

is that possible?
User avatar
By Piira
#61840 Of cause it is possible, I made most parts last year in a project that is on ice. My computer crashed and my backup was a month old so it is quite hard to remember what need to be fixed.

The solution in the video is however quite useless. If you record a signal from an remote for an AC it include all settings for the AC. This means if you record setting the temperature to 22 C while you are using it for cooling you can't use the same recording to set 22 C when it is set in heating mode because then it will also change the mode to cooling. This was at least the case for the 2 AC:s I have.

You can test by changing some mode on your IR when the IR is out of reach for the AC. Then you go within reach and change the temperature and you will see that also the mode changes. To be able to control an AC as described you would have to record every combination of all modes and temperatures your remote supports.

In my solution I had made a lot of work to manually decode the meaning of each bit in the signal the remote sent. Then I would be able to combine my own signals and transmit them. I had the logic to receive IR signals in place to be able to manually ´decode them and also the logic to transmit my own signals that the AC:s understood working before the computer crashed.
User avatar
By TarekJ
#61871
Piira wrote:Of cause it is possible, I made most parts last year in a project that is on ice. My computer crashed and my backup was a month old so it is quite hard to remember what need to be fixed.

The solution in the video is however quite useless. If you record a signal from an remote for an AC it include all settings for the AC. This means if you record setting the temperature to 22 C while you are using it for cooling you can't use the same recording to set 22 C when it is set in heating mode because then it will also change the mode to cooling. This was at least the case for the 2 AC:s I have.

You can test by changing some mode on your IR when the IR is out of reach for the AC. Then you go within reach and change the temperature and you will see that also the mode changes. To be able to control an AC as described you would have to record every combination of all modes and temperatures your remote supports.

In my solution I had made a lot of work to manually decode the meaning of each bit in the signal the remote sent. Then I would be able to combine my own signals and transmit them. I had the logic to receive IR signals in place to be able to manually ´decode them and also the logic to transmit my own signals that the AC:s understood working before the computer crashed.


good job Piira, my question is

- where should I save the signal information? should I copy them and put them hard coded later?
- I need a circuit for recording the signals and then transmitting it.
- are signals simply transmitted? or they need to be coded and encoded?
User avatar
By Piira
#62026 @TarekJ
I would advice you to start with Arduino, I did. It is somewhat easier to program, it is much better documented and there are loads of instructions and examples. You can't do WiFi with the Arduino but once you have got your IR handling working you can decide if you want to just use the ESP as a WiFi access or if you want to move everything to the ESP. My decision at that point was to put everything on the ESP.
To start with the Arduino (but also for the ESP) you should get an IR receiver module. I got one delivered with with a remote so that I easily could start with the examples for that remote. Then you should learn how to connect load to Arduino using a transistor and connect the an IR diode that way, an IR diode need up to 100mA to work on any distance and nether the Arduino nor the ESP can deliiver that much on the GPIO pins. Also for this you can find loads of instructions on the web.
You can of cause also find a lot of instructions and examples on the web about how to do things on the ESP. Many are good but there are also a lot of people providing examples and instructions that doesn't know what they are talking about. I won't say anything on how to do things because then I would also belong to the group of people that doesn't know what they are talking about :( .