Created
September 13, 2025 01:45
-
-
Save agrif/4aa5dc8d24c748f5b87b08e05a8f1aed to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ReceiveCode samsung_vol_up("Samsung VOL UP", 'U', SAMSUNG, 0x707, 0x7); | |
| ReceiveCode samsung_vol_down("Samsung VOL DOWN", 'D', SAMSUNG, 0x707, 0xb); | |
| ReceiveCode samsung_mute("Samsung MUTE", 'M', SAMSUNG, 0x707, 0xf); | |
| ReceiveSequence demo_seq("MMMU"); | |
| // Protocol=NEC Address=0xA5 Command=0xA | |
| // Raw-Data=0xF50A5AA5 32 bits LSB first | |
| TransmitRaw pioneer_vol_up("Pioneer VOL UP", {8580,4220, 580,1570, 530,520, 580,1570, 530,520, 580,520, 530,1570, 580,520, 530,1570, 580,520, 530,1570, 580,520, 530,1570, 580,1570, 530,520, 580,1570, 530,520, 580,520, 530,1570, 580,520, 530,1570, 580,520, 530,520, 580,520, 530,520, 580,1570, 530,520, 580,1570, 530,520, 580,1570, 530,1570, 580,1570, 530,1570, 580}); | |
| // Protocol=NEC Address=0xA5 Command=0xB | |
| // Raw-Data=0xF40B5AA5 32 bits LSB first | |
| TransmitRaw pioneer_vol_down("Pioneer VOL DOWN", {8580,4220, 580,1570, 530,520, 580,1570, 530,520, 580,520, 530,1570, 580,520, 530,1570, 580,520, 530,1570, 580,520, 530,1570, 580,1570, 530,520, 580,1570, 530,520, 580,1570, 530,1570, 580,520, 530,1570, 580,520, 530,520, 580,520, 530,520, 580,520, 530,520, 580,1570, 530,520, 580,1570, 530,1620, 530,1570, 530,1570, 580}); | |
| // Protocol=NEC Address=0xA5 Command=0x12 | |
| // Raw-Data=0xED125AA5 32 bits LSB first | |
| TransmitRaw pioneer_mute("Pioneer MUTE", {8530,4270, 530,1570, 580,520, 530,1570, 580,520, 530,520, 580,1570, 530,520, 580,1570, 530,520, 580,1570, 530,520, 580,1570, 530,1570, 580,520, 530,1570, 580,520, 530,520, 580,1570, 530,520, 580,520, 530,1570, 580,520, 530,520, 580,520, 530,1570, 580,520, 530,1570, 580,1570, 530,520, 580,1570, 530,1570, 580,1570, 530}); | |
| // Protocol=NEC Address=0xA5 Command=0x1C | |
| // Raw-Data=0xE31C5AA5 32 bits LSB first | |
| TransmitRaw pioneer_power("Pioneer POWER", {8580,4220, 580,1520, 580,520, 580,1570, 530,520, 580,520, 530,1570, 580,470, 580,1570, 580,470, 580,1570, 580,470, 580,1570, 580,1520, 580,520, 580,1520, 580,520, 580,470, 580,520, 580,1520, 580,1570, 580,1520, 580,520, 580,470, 580,520, 580,1520, 580,1570, 580,470, 580,520, 580,520, 530,1570, 580,1520, 580,1570, 580}); | |
| // Protocol=UNKNOWN Hash=0x371A3C86 12 bits | |
| // (incl. gap and start) received | |
| TransmitRaw fan_power("Fan POWER", {1330,420, 1330,420, 430,1320, 1280,470, 1280,420, 430,1370, 380,1320, 430,1320, 430,1320, 1280,470, 380,1370, 380}); | |
| std::vector<Rule> rules = { | |
| {&samsung_vol_up, {&pioneer_vol_up}}, | |
| {&samsung_vol_down, {&pioneer_vol_down}}, | |
| {&samsung_mute, {&pioneer_mute}}, | |
| {&demo_seq, {&fan_power}}, | |
| }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment