I bought some multicolor LED candles that are controlled by an IR remote. These are a no name brand that I bought from a shop and it has a remote with no brand on it. I wanted to integrate this into my home automation of domoticz and I am ALMOST there. I have everything else working just can't get the IRTx plugin to work.
Here is a breakdown of what I did for some background information
bought these candles and remote
https://www.amazon.co.uk/Benross-Anika- ... B00M35B4RI
purchased
https://www.aliexpress.com/item/Digital ... 67671.html
https://www.aliexpress.com/item/Compati ... 15940.html
I hooked all the stuff up to my raspberry pi and followed this guide
http://www.instructables.com/id/How-To- ... /?ALLSTEPS
I used Lirc and created a config for my remote and mapped the keys to the hex values
I then tested it by sending ir signals from the LED to my candles 1 meter away from rpi to candles. This works 100% I have all the buttons working like they should be on my raspberry pi
Here is the config of my remote.
Code: Select all
begin remote
bits 16
flags SPACE_ENC|CONST_LENGTH
eps 30
aeps 100
header 9197 4553
one 581 1679
zero 581 594
ptrail 583
repeat 9204 2266
pre_data_bits 16
pre_data 0x1FE
gap 108815
toggle_bit_mask 0x0
begin codes
KEY_POWER 0x48B7
KEY_POWER2 0x58A7
KEY_M 0x7887
KEY_KP0 0x7887
KEY_KP1 0x807F
KEY_KP2 0x40BF
KEY_KP3 0xC03F
KEY_FN_F1 0x20DF
KEY_FN_F2 0xA05F
KEY_FN_F3 0x609F
KEY_FN_F4 0xE01F
KEY_FN_F5 0x10EF
KEY_FN_F6 0x906F
KEY_FN_F7 0x50AF
KEY_FN_F8 0xD827
KEY_FN_F9 0xF807
KEY_FN_F10 0x30CF
KEY_FN_F11 0xB04F
KEY_FN_F12 0x708F
end codes
end remote
I then took a ESP12F loaded easy esp R140 which contains the IRTX plugin. I then removed my irled but left the receiver on the raspberry pi. I hooked up my LED to the esp and configured the IRTX plugin with correct GPIO.
I made sure the LED was working as I put a hex code in it and hit enter. I watched the LED on my camera and I could see it blink purple confirming that it is hooked up correctly
I was using this format to send Hex codes http://192.168.0.xxx/control?cmd=IRSEND,NEC,0x48B7,16
But it doesn’t actually turn on my candles even at 1 cm from it
I have tried 16 and 32 bit
I have also tried all different remote settings NEC, RC4, RC5, Samsung etc
Any suggestions?
with lirc on my rpi I ran mode2 -d /dev/lirc0 to capture the original raw power on from my remote signal here it is ,
Code: Select all
space 16777215
pulse 8899
space 4632
pulse 438
space 671
pulse 527
space 643
pulse 443
space 674
pulse 470
space 697
pulse 438
space 682
pulse 461
space 671
pulse 475
space 674
pulse 463
space 1811
pulse 457
space 1808
pulse 474
space 1803
pulse 404
space 1895
pulse 489
space 1779
pulse 499
space 1770
pulse 498
space 1750
pulse 496
space 1803
pulse 494
space 619
pulse 490
when I run the hex version of the-power on command via the IRTX plugin I capture it with the same command but it is different which is why it doesn’t turn on. I don’t understand why it is different. here os the code Any suggestions from people who know IR better than me?
Code: Select all
space 16777215
pulse 9184
space 4577
pulse 604
space 536
pulse 610
space 623
pulse 548
space 599
pulse 576
space 568
pulse 646
space 560
pulse 575
space 608
pulse 577
space 585
pulse 585
space 1684
pulse 574
space 1684
pulse 575
space 1686
pulse 582
space 1679
pulse 581
space 1686
pulse 580
space 1719
pulse 536
space 1684
pulse 576
space 1710
pulse 549
space 596
pulse 586
space 592
pulse 577
space 1683
pulse 580
space 637
pulse 536
space 592
pulse 592
space 1675
pulse 576
space 616
pulse 560
space 563
pulse 614
space 587
pulse 586
space 1685
pulse 577
space 640
pulse 535
space 1683
pulse 575
space 1692
pulse 575
space 591
pulse 584
space 1655
pulse 606
space 1682
pulse 577
space 1657
pulse 607
space 39744
pulse 9218
space 2274
pulse 575
space 96708
pulse 9206
space 2247
pulse 653
I am guessing I am entering the hex code wrong but I also don’t know how to correct it either if I am doing that. Here is the one that I capture doing the plugin I know it looks like crap but if you take both of them and compare them side by side with excel you can see the differences quite clearly, some of the pauses and sends are the same or close to each other, some aren’t even close
Help?
I also tried irw which correlates button presses with the full hex and did the supposed full 16 bit hex into the plugin and still nothing here is the irw output for the hex I used
0000000001fe48b7 01 KEY_POWER rgb
All last night I tried to flash IRrecDumpV2 onto my uno (Chinese copy) but it keeps erroring out and I have no clue why either. I thought the library I could just easily flash without much hassle and try getting the hex that way to try a secondary way instead of lirc but no luck
Code: Select all
Arduino: 1.8.1 (Windows 10), Board: "Arduino/Genuino Uno"
IRtest:64: error: expected class-name before '{' token
{
^
C:\Program Files (x86)\Arduino\libraries\Robot_Control\Arduino-IRremote-master\examples\IRtest\IRtest.ino: In constructor 'IRsendDummy::IRsendDummy()':
IRtest:71: error: class 'IRsendDummy' does not have any field named 'IRsend'
IRsend() {
^
C:\Program Files (x86)\Arduino\libraries\Robot_Control\Arduino-IRremote-master\examples\IRtest\IRtest.ino: In function 'void testNEC(long unsigned int, int)':
IRtest:137: error: 'class IRsendDummy' has no member named 'sendNEC'
irsenddummy.sendNEC(val, bits);
^
C:\Program Files (x86)\Arduino\libraries\Robot_Control\Arduino-IRremote-master\examples\IRtest\IRtest.ino: In function 'void testSony(long unsigned int, int)':
IRtest:142: error: 'class IRsendDummy' has no member named 'sendSony'
irsenddummy.sendSony(val, bits);
^
C:\Program Files (x86)\Arduino\libraries\Robot_Control\Arduino-IRremote-master\examples\IRtest\IRtest.ino: In function 'void testRC5(long unsigned int, int)':
IRtest:147: error: 'class IRsendDummy' has no member named 'sendRC5'
irsenddummy.sendRC5(val, bits);
^
C:\Program Files (x86)\Arduino\libraries\Robot_Control\Arduino-IRremote-master\examples\IRtest\IRtest.ino: In function 'void testRC6(long unsigned int, int)':
IRtest:152: error: 'class IRsendDummy' has no member named 'sendRC6'
irsenddummy.sendRC6(val, bits);
^
exit status 1
expected class-name before '{' token