赤外線リモコン スマートリモコン Smart Remote Controller Arduino PlatformIO ESP32
はじめに
ESP32を使って学習リモコンを作る(1) 学習リモコンでどんなことができるの? ではブラウザ画面から学習モード操作および送信モード操作を行った場合について説明しました。ここではそれぞれの操作を行った場合に、USBケーブル接続されたPCにターミナル出力される内容の詳細について記録を残しておきます。動作確認やデバグに利用できます。
準備
本機の ESP32-DevKitC-32E と PC をUSBケーブルで接続しておきます。VS Code を立ち上げて PlatformIO IDE から本機のプロジェクトを ESP32を使って学習リモコンを作る(7) ソフトウエア 本機のプロジェクト に従ってファームウエアとファイルシステムイメージを書込んでおきます。
ファームウエア実行
PROJECT TASKS から Monitor をクリックするとファームウェアの実行が開始されます。
ターミナルウインドウには次のメッセージが出力されます。
* 実行するタスク: C:\Users\tatsu\.platformio\penv\Scripts\platformio.exe device monitor –environment esp32dev
— Terminal on COM5 | 115200 8-N-1
— Available filters and text transformations: colorize, debug, default, direct, esp32_exception_decoder, hexlify, log2file, nocontrol, printable, send_on_enter, time
— More details at https://bit.ly/pio-monitor-filters
— Quit: Ctrl+C | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H
ets Jul 29 2019 12:21:46
rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:1184
load:0x40078000,len:13192
load:0x40080400,len:3028
entry 0x400805e4
START src/main.cpp from Dec 5 2024
Using library version 4.4.0
Ready to receive IR signals of protocols: NEC/NEC2/Onkyo/Apple, Panasonic/Kaseikyo, Denon/Sharp, Sony, RC5, RC6, LG, JVC, Samsung, FAST, Whynter, Lego Power Functions, Bosewave, MagiQuest, Universal Pulse Distance Width, Hash at pin 15
12000 us is the (minimum) gap, after which the start of a new IR packet is assumed
20
Because of the verbose output (>200 ms at 111000 baud), repeats are not dumped correctly!
If you receive protocol NEC, Samsung or LG, run also ReceiveDemo to check if your actual protocol is eventually NEC2 or SamsungLG, which is determined by the repeats
Connecting to Wi-Fi E (786) wifi:Association refused temporarily, comeback time 1999 mSec
…….
WiFi connected.
*IP address: 192.168.xx.xx
メッセージの最終行に表示される IP address をブラウザのアドレスバーに入力すると本機の操作画面が表示されます。(図7)

図7 学習モード時のブラウザ画面表示の説明
ブラウザ画面に表示されるのは、①情報表示窓、②リモコン送信ボタン、③モード切換ボタンおよび④制御ボタンで構成されています。以下に学習モードの操作について説明します。
学習モード操作
1. 「Smart Remote Controller」の文字が「③モード切換ボタン」として動作します。文字が赤色になると「学習モード」に切換り「④制御ボタン」が表示されて制御待受状態になります。(図8)

図8 学習モード制御待受状態

図9 取込待受状態

図10 取込完了
**************************************************************
receive_IR_process started
**************************************************************
Protocol=NEC Address=0x4BBA Command=0xD Raw-Data=0xF20D4BBA 32 bits LSB first
Send with: IrSender.sendNEC(0x4BBA, 0xD, <numberOfRepeats>);
Raw result in internal ticks (50 us) – with leading gap
rawData[68]:
-65535
+181,-88
+12,-11 +12,-32 +12,-11 +12,-32
+12,-33 +12,-33 +12,-10 +12,-33
+12,-32 +13,-33 +11,-11 +12,-33
+11,-11 +12,-10 +12,-33 +12,-11
+11,-33 +12,-11 +11,-33 +12,-33
+11,-11 +12,-11 +11,-11 +11,-11
+12,-11 +11,-33 +12,-11 +11,-11
+11,-34 +11,-33 +12,-33 +11,-33
+13
Sum: 1377
Raw result in microseconds – with leading gap
rawData[68]:
-3276750
+9050,-4400
+ 600,- 550 + 600,-1600 + 600,- 550 + 600,-1600
+ 600,-1650 + 600,-1650 + 600,- 500 + 600,-1650
+ 600,-1600 + 650,-1650 + 550,- 550 + 600,-1650
+ 550,- 550 + 600,- 500 + 600,-1650 + 600,- 550
+ 550,-1650 + 600,- 550 + 550,-1650 + 600,-1650
+ 550,- 550 + 600,- 550 + 550,- 550 + 550,- 550
+ 600,- 550 + 550,-1650 + 600,- 550 + 550,- 550
+ 550,-1700 + 550,-1650 + 600,-1650 + 550,-1650
+ 650
Sum: 68850
Result as internal 8bit ticks (50 us) array – compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[67] = {181,88, 12,11, 12,32, 12,11, 12,32, 12,33, 12,33, 12,10, 12,33, 12,32, 13,33, 11,11, 12,33, 11,11, 12,10, 12,33, 12,11, 11,33, 12,11, 11,33, 12,33, 11,11, 12,11, 11,11, 11,11, 12,11, 11,33, 12,11, 11,11, 11,34, 11,33, 12,33, 11,33, 13}; // Protocol=NEC Address=0x4BBA Command=0xD Raw-Data=0xF20D4BBA 32 bits LSB first
Result as microseconds array – compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[67] = {9030,4420, 580,570, 580,1620, 580,570, 580,1620, 580,1670, 580,1670, 580,520, 580,1670, 580,1620, 630,1670, 530,570, 580,1670, 530,570, 580,520, 580,1670, 580,570, 530,1670, 580,570, 530,1670, 580,1670, 530,570, 580,570, 530,570, 530,570, 580,570, 530,1670, 580,570, 530,570, 530,1720, 530,1670, 580,1670,
530,1670, 630}; // Protocol=NEC Address=0x4BBA Command=0xD Raw-Data=0xF20D4BBA 32 bits LSB first
uint16_t address = 0x4BBA;
uint16_t command = 0xD;
uint64_t rawData = 0xF20D4BBA;
Pronto Hex as string
char prontoData[] = “0000 006D 0022 0000 015D 00A8 0018 0014 0018 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012 0018 003F 0018 003D 001A 003F 0016 0014 0018 003F 0016 0014 0018 0012 0018 003F 0018 0014 0016 003F 0018 0014 0016 003F 0018 003F 0016 0014 0018 0014 0016 0014 0016 0014 0018 0014 0016 003F 0018 0014 0016 0014 0016 0041 0016 003F 0018 003F 0016 003F 001A 06C3 “;
writeStr.length = 360
**************************************************************
receive_IR_process finishd
**************************************************************
char prontoData[]=・・・・赤外線リモコン信号を Hex 形式で取得しました。
writeStr.length =・・・・・赤外線リモコン信号が何バイトかを出力します。極端に少ない場合は読取エラーの可能性があります。

図11 登録待受状態

図12 登録完了
**************************************************************
store_FLASH started
**************************************************************
wrfile = /bt_4/bt_4_1.txt
writeStr= 0000 006D 0022 0000 015D 00A8 0018 0014 0018 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012
0018 003F 0018 003D 001A 003F 0016 0014 0018 003F 0016 0014 0018 0012 0018 003F 0018 0014 0016 003F 0018 0014
0016 003F 0018 003F 0016 0014 0018 0014 0016 0014 0016 0014 0018 0014 0016 003F 0018 0014 0016 0014 0016 0041
0016 003F 0018 003F 0016 003F 001A 06C3
**************************************************************
store_FLASH finished
**************************************************************
**************************************************************
store_FLASH started
**************************************************************
wrfile = /bt_4/num_reg.txt
writeStr= 1
**************************************************************
store_FLASH finished
**************************************************************
/bt_4/bt_4_1.txt・・・・・赤外線リモコン信号を HEX 形式で書き込みます。
/bt_4/num_reg.txt・・・・・bt_4 ボタンに対する登録数が何個目かを文字形式で書き込みます。この場合は 1 個目なので 1 を書込みます。
7. 同一のリモコン送信ボタンに複数の信号を登録したい場合があります。 複数の機器、例えばTVの電源とオーディオの電源を1つのリモコン送信ボタンで制御したい場合は 6. に続けて 2.「取込」ボタンから繰り返します。リモコン送信ボタンに登録できる信号の数に制限はありません。 この例では2つめのリモコン信号を TV グループの右上のボタン(予備_bt_4)に登録しました。 (図13)

図13 2つめのリモコン信号を登録
「取込」ボタンが押されました。
**************************************************************
receive_IR_process started
**************************************************************
Protocol=NEC Address=0x4BBA Command=0xF Raw-Data=0xF00F4BBA 32 bits LSB first
Send with: IrSender.sendNEC(0x4BBA, 0xF, <numberOfRepeats>);
Raw result in internal ticks (50 us) – with leading gap
rawData[68]:
-65535
+180,-89
+12,-10 +12,-33 +12,-10 +12,-33
+12,-32 +13,-32 +12,-11 +12,-32
+12,-33 +12,-33 +12,-10 +12,-33
+12,-10 +12,-10 +12,-33 +12,-10
+13,-32 +12,-33 +12,-32 +13,-32
+12,-11 +12,-10 +12,-11 +11,-11
+12,-10 +12,-11 +11,-11 +12,-11
+11,-33 +12,-33 +11,-33 +12,-33
+12
Sum: 1376
Raw result in microseconds – with leading gap
rawData[68]:
-3276750
+9000,-4450
+ 600,- 500 + 600,-1650 + 600,- 500 + 600,-1650
+ 600,-1600 + 650,-1600 + 600,- 550 + 600,-1600
+ 600,-1650 + 600,-1650 + 600,- 500 + 600,-1650
+ 600,- 500 + 600,- 500 + 600,-1650 + 600,- 500
+ 650,-1600 + 600,-1650 + 600,-1600 + 650,-1600
+ 600,- 550 + 600,- 500 + 600,- 550 + 550,- 550
+ 600,- 500 + 600,- 550 + 550,- 550 + 600,- 550
+ 550,-1650 + 600,-1650 + 550,-1650 + 600,-1650
+ 600
Sum: 68800
Result as internal 8bit ticks (50 us) array – compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[67] = {180,89, 12,10, 12,33, 12,10, 12,33, 12,32, 13,32, 12,11, 12,32, 12,33, 12,33, 12,10, 12,33, 12,10, 12,10, 12,33, 12,10, 13,32, 12,33, 12,32, 13,32, 12,11, 12,10, 12,11, 11,11, 12,10, 12,11, 11,11, 12,11, 11,33, 12,33, 11,33, 12,33, 12}; // Protocol=NEC Address=0x4BBA Command=0xF Raw-Data=0xF00F4BBA 32 bits LSB first
Result as microseconds array – compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[67] = {8980,4470, 580,520, 580,1670, 580,520, 580,1670, 580,1620, 630,1620, 580,570, 580,1620, 580,1670, 580,1670, 580,520, 580,1670, 580,520, 580,520, 580,1670, 580,520, 630,1620, 580,1670, 580,1620, 630,1620, 580,570, 580,520, 580,570, 530,570, 580,520, 580,570, 530,570, 580,570, 530,1670, 580,1670, 530,1670,
580,1670, 580}; // Protocol=NEC Address=0x4BBA Command=0xF Raw-Data=0xF00F4BBA 32 bits LSB first
uint16_t address = 0x4BBA;
uint16_t command = 0xF;
uint64_t rawData = 0xF00F4BBA;
Pronto Hex as string
char prontoData[] = “0000 006D 0022 0000 015B 00AA 0018 0012 0018 003F 0018 0012 0018 003F 0018 003D 001A 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012 0018 003F 0018 0012 0018 0012 0018 003F 0018 0012 001A 003D 0018 003F 0018 003D 001A 003D 0018 0014 0018 0012 0018 0014 0016 0014 0018 0012 0018 0014 0016 0014 0018 0014 0016 003F 0018 003F 0016 003F 0018 003F 0018 06C3 “;
writeStr.length = 360
**************************************************************
receive_IR_process finishd
**************************************************************
「登録」ボタンが押されました。
**************************************************************
store_FLASH started
**************************************************************
wrfile = /bt_4/bt_4_2.txt
writeStr= 0000 006D 0022 0000 015B 00AA 0018 0012 0018 003F 0018 0012 0018 003F 0018 003D 001A 003D 0018 0014
0018 003D 0018 003F 0018 003F 0018 0012 0018 003F 0018 0012 0018 0012 0018 003F 0018 0012 001A 003D 0018 003F
0018 003D 001A 003D 0018 0014 0018 0012 0018 0014 0016 0014 0018 0012 0018 0014 0016 0014 0018 0014 0016 003F
0018 003F 0016 003F 0018 003F 0018 06C3
**************************************************************
store_FLASH finished
**************************************************************
**************************************************************
store_FLASH started
**************************************************************
wrfile = /bt_4/num_reg.txt
writeStr= 2
**************************************************************
store_FLASH finished
**************************************************************
フォルダ名/ファイル名
/bt_4/bt_4_2.txt・・・・・赤外線リモコン信号を HEX 形式で書き込みます。2 個目の信号なのでファイル名末尾は自動的に _2 となります。
/bt_4/num_reg.txt・・・・・bt_4 ボタンに対する登録数が何個目かを文字形式で書き込みます。同一のボタンに2個目なので 2 を書込みます。

図14 終了ボタンを押すと制御待受状態になる
「終了」ボタンが押されました。

図15 モード切換ボタンが青色になれば待受状態
モード切換ボタンが押されました。
送信モード操作

図16 送信モード時のブラウザ画面表示の説明
ブラウザ画面に表示されるのは、①情報表示窓、②リモコン送信ボタンおよび③モード切換ボタンで構成されています。以下に送信モードの操作について説明します。
1. 「Smart Remote Controller」の文字が青色であることを確認します。赤色の場合は文字を押すことにより青色に変わり「送信モード」に設定されます。 (図17)

図17 送信モードに設定

図18 リモコン送信ボタン押下
**************************************************************
restore_FLASH started
**************************************************************
readStr = 2
readStr.length = 2
**************************************************************
restore_FLASH finished
**************************************************************
**************************************************************
restore_FLASH started
**************************************************************
readStr = 0000 006D 0022 0000 015D 00A8 0018 0014 0018 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012
0018 003F 0018 003D 001A 003F 0016 0014 0018 003F 0016 0014 0018 0012 0018 003F 0018 0014 0016 003F 0018 0014
0016 003F 0018 003F 0016 0014 0018 0014 0016 0014 0016 0014 0018 0014 0016 003F 0018 0014 0016 0014 0016 0041
0016 003F 0018 003F 0016 003F 001A 06C3
readStr.length = 361
**************************************************************
restore_FLASH finished
**************************************************************
**************************************************************
send_IR_process started
**************************************************************
readStr.c_str() =
0000 006D 0022 0000 015D 00A8 0018 0014 0018 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012 0018 003F
0018 003D 001A 003F 0016 0014 0018 003F 0016 0014 0018 0012 0018 003F 0018 0014 0016 003F 0018 0014 0016 003F
0018 003F 0016 0014 0018 0014 0016 0014 0016 0014 0018 0014 0016 003F 0018 0014 0016 0014 0016 0041 0016 003F
0018 003F 0016 003F 001A 06C3
send trun on at 854512
**************************************************************
send_IR_process finished
**************************************************************
**************************************************************
restore_FLASH started
**************************************************************
readStr = 0000 006D 0022 0000 015B 00AA 0018 0012 0018 003F 0018 0012 0018 003F 0018 003D 001A 003D 0018 0014
0018 003D 0018 003F 0018 003F 0018 0012 0018 003F 0018 0012 0018 0012 0018 003F 0018 0012 001A 003D 0018 003F
0018 003D 001A 003D 0018 0014 0018 0012 0018 0014 0016 0014 0018 0012 0018 0014 0016 0014 0018 0014 0016 003F
0018 003F 0016 003F 0018 003F 0018 06C3
readStr.length = 361
**************************************************************
restore_FLASH finished
**************************************************************
**************************************************************
send_IR_process started
**************************************************************
readStr.c_str() =
0000 006D 0022 0000 015B 00AA 0018 0012 0018 003F 0018 0012 0018 003F 0018 003D 001A 003D 0018 0014 0018 003D
0018 003F 0018 003F 0018 0012 0018 003F 0018 0012 0018 0012 0018 003F 0018 0012 001A 003D 0018 003F 0018 003D
001A 003D 0018 0014 0018 0012 0018 0014 0016 0014 0018 0012 0018 0014 0016 0014 0018 0014 0016 003F 0018 003F
0016 003F 0018 003F 0018 06C3
send trun on at 855198
**************************************************************
send_IR_process finished
**************************************************************
①登録数読出し ⇒ ②赤外線リモコン信号読出し ⇒ ③赤外線リモコン信号送信 ⇒ ②-③を登録数回繰り返し
おわりに
学習モード操作から送信モード操作まで一連の操作を行った場合にターミナルに出力される内容を順を追って記録しました。ファームウエアの関数ごとに必要な情報をターミナルに出力するようにコードを記述しているので動作確認やデバグに有効だと思います。
これで「ESP32を使って学習リモコンを作る」を(完)とします。
リンク
ESP32を使って学習リモコンを作る(1) 学習リモコンでどんなことができるの?
ESP32を使って学習リモコンを作る(2) ハードウエア
ESP32を使って学習リモコンを作る(3) ソフトウエア 赤外線リモコン受信( irReceive )
ESP32を使って学習リモコンを作る(4) ソフトウエア 赤外線リモコン送信( irSend )
ESP32を使って学習リモコンを作る(5) ソフトウエア webserver
ESP32を使って学習リモコンを作る(6) ソフトウエア FLASH 読書き(SPIFFS)
ESP32を使って学習リモコンを作る(7) ソフトウエア 本機のプロジェクト
ESP32を使って学習リモコンを作る(8) ソフトウエア 本機プロジェクトの勘所
ESP32を使って学習リモコンを作る(9) ハードウエア設計の勘所
ESP32を使って学習リモコンを作る(10) 学習リモコンを操作した時のターミナル出力
Smart_Remote_Controller プロジェクト GitHub
(YI)
付録・・・スクロール無しターミナル出力全文
* 実行するタスク: C:\Users\tatsu\.platformio\penv\Scripts\platformio.exe device monitor –environment esp32dev
— Terminal on COM5 | 115200 8-N-1
— Available filters and text transformations: colorize, debug, default, direct, esp32_exception_decoder, hexlify, log2file, nocontrol, printable, send_on_enter, time
— More details at https://bit.ly/pio-monitor-filters
— Quit: Ctrl+C | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H
ets Jul 29 2019 12:21:46
rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:1184
load:0x40078000,len:13192
load:0x40080400,len:3028
entry 0x400805e4
START src/main.cpp from Dec 5 2024
Using library version 4.4.0
Ready to receive IR signals of protocols: NEC/NEC2/Onkyo/Apple, Panasonic/Kaseikyo, Denon/Sharp, Sony, RC5, RC6, LG, JVC, Samsung, FAST, Whynter, Lego Power Functions, Bosewave, MagiQuest, Universal Pulse Distance Width, Hash at pin 15
12000 us is the (minimum) gap, after which the start of a new IR packet is assumed
20
Because of the verbose output (>200 ms at 111000 baud), repeats are not dumped correctly!
If you receive protocol NEC, Samsung or LG, run also ReceiveDemo to check if your actual protocol is eventually NEC2 or SamsungLG, which is determined by the repeats
Connecting to Wi-Fi E (786) wifi:Association refused temporarily, comeback time 1999 mSec
…….
WiFi connected.
*IP address: 192.168.xx.xx
モード切換ボタンが押されました。
「取込」ボタンが押されました。
**************************************************************
receive_IR_process started
**************************************************************
Protocol=NEC Address=0x4BBA Command=0xD Raw-Data=0xF20D4BBA 32 bits LSB first
Send with: IrSender.sendNEC(0x4BBA, 0xD, <numberOfRepeats>);
Raw result in internal ticks (50 us) – with leading gap
rawData[68]:
-65535
+181,-88
+12,-11 +12,-32 +12,-11 +12,-32
+12,-33 +12,-33 +12,-10 +12,-33
+12,-32 +13,-33 +11,-11 +12,-33
+11,-11 +12,-10 +12,-33 +12,-11
+11,-33 +12,-11 +11,-33 +12,-33
+11,-11 +12,-11 +11,-11 +11,-11
+12,-11 +11,-33 +12,-11 +11,-11
+11,-34 +11,-33 +12,-33 +11,-33
+13
Sum: 1377
Raw result in microseconds – with leading gap
rawData[68]:
-3276750
+9050,-4400
+ 600,- 550 + 600,-1600 + 600,- 550 + 600,-1600
+ 600,-1650 + 600,-1650 + 600,- 500 + 600,-1650
+ 600,-1600 + 650,-1650 + 550,- 550 + 600,-1650
+ 550,- 550 + 600,- 500 + 600,-1650 + 600,- 550
+ 550,-1650 + 600,- 550 + 550,-1650 + 600,-1650
+ 550,- 550 + 600,- 550 + 550,- 550 + 550,- 550
+ 600,- 550 + 550,-1650 + 600,- 550 + 550,- 550
+ 550,-1700 + 550,-1650 + 600,-1650 + 550,-1650
+ 650
Sum: 68850
Result as internal 8bit ticks (50 us) array – compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[67] = {181,88, 12,11, 12,32, 12,11, 12,32, 12,33, 12,33, 12,10, 12,33, 12,32, 13,33, 11,11, 12,33, 11,11, 12,10, 12,33, 12,11, 11,33, 12,11, 11,33, 12,33, 11,11, 12,11, 11,11, 11,11, 12,11, 11,33, 12,11, 11,11, 11,34, 11,33, 12,33, 11,33, 13}; // Protocol=NEC Address=0x4BBA Command=0xD Raw-Data=0xF20D4BBA 32 bits LSB first
Result as microseconds array – compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[67] = {9030,4420, 580,570, 580,1620, 580,570, 580,1620, 580,1670, 580,1670, 580,520, 580,1670, 580,1620, 630,1670, 530,570, 580,1670, 530,570, 580,520, 580,1670, 580,570, 530,1670, 580,570, 530,1670, 580,1670, 530,570, 580,570, 530,570, 530,570, 580,570, 530,1670, 580,570, 530,570, 530,1720, 530,1670, 580,1670,
530,1670, 630}; // Protocol=NEC Address=0x4BBA Command=0xD Raw-Data=0xF20D4BBA 32 bits LSB first
uint16_t address = 0x4BBA;
uint16_t command = 0xD;
uint64_t rawData = 0xF20D4BBA;
Pronto Hex as string
char prontoData[] = “0000 006D 0022 0000 015D 00A8 0018 0014 0018 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012 0018 003F 0018 003D 001A 003F 0016 0014 0018 003F 0016 0014 0018 0012 0018 003F 0018 0014 0016 003F 0018 0014 0016 003F 0018 003F 0016 0014 0018 0014 0016 0014 0016 0014 0018 0014 0016 003F 0018 0014 0016 0014 0016 0041 0016 003F 0018 003F 0016 003F 001A 06C3 “;
writeStr.length = 360
**************************************************************
receive_IR_process finishd
**************************************************************
「登録」ボタンが押されました。
**************************************************************
store_FLASH started
**************************************************************
wrfile = /bt_4/bt_4_1.txt
writeStr= 0000 006D 0022 0000 015D 00A8 0018 0014 0018 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012
0018 003F 0018 003D 001A 003F 0016 0014 0018 003F 0016 0014 0018 0012 0018 003F 0018 0014 0016 003F 0018 0014
0016 003F 0018 003F 0016 0014 0018 0014 0016 0014 0016 0014 0018 0014 0016 003F 0018 0014 0016 0014 0016 0041
0016 003F 0018 003F 0016 003F 001A 06C3
**************************************************************
store_FLASH finished
**************************************************************
**************************************************************
store_FLASH started
**************************************************************
wrfile = /bt_4/num_reg.txt
writeStr= 1
**************************************************************
store_FLASH finished
**************************************************************
「取込」ボタンが押されました。
**************************************************************
receive_IR_process started
**************************************************************
Protocol=NEC Address=0x4BBA Command=0xF Raw-Data=0xF00F4BBA 32 bits LSB first
Send with: IrSender.sendNEC(0x4BBA, 0xF, <numberOfRepeats>);
Raw result in internal ticks (50 us) – with leading gap
rawData[68]:
-65535
+180,-89
+12,-10 +12,-33 +12,-10 +12,-33
+12,-32 +13,-32 +12,-11 +12,-32
+12,-33 +12,-33 +12,-10 +12,-33
+12,-10 +12,-10 +12,-33 +12,-10
+13,-32 +12,-33 +12,-32 +13,-32
+12,-11 +12,-10 +12,-11 +11,-11
+12,-10 +12,-11 +11,-11 +12,-11
+11,-33 +12,-33 +11,-33 +12,-33
+12
Sum: 1376
Raw result in microseconds – with leading gap
rawData[68]:
-3276750
+9000,-4450
+ 600,- 500 + 600,-1650 + 600,- 500 + 600,-1650
+ 600,-1600 + 650,-1600 + 600,- 550 + 600,-1600
+ 600,-1650 + 600,-1650 + 600,- 500 + 600,-1650
+ 600,- 500 + 600,- 500 + 600,-1650 + 600,- 500
+ 650,-1600 + 600,-1650 + 600,-1600 + 650,-1600
+ 600,- 550 + 600,- 500 + 600,- 550 + 550,- 550
+ 600,- 500 + 600,- 550 + 550,- 550 + 600,- 550
+ 550,-1650 + 600,-1650 + 550,-1650 + 600,-1650
+ 600
Sum: 68800
Result as internal 8bit ticks (50 us) array – compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[67] = {180,89, 12,10, 12,33, 12,10, 12,33, 12,32, 13,32, 12,11, 12,32, 12,33, 12,33, 12,10, 12,33, 12,10, 12,10, 12,33, 12,10, 13,32, 12,33, 12,32, 13,32, 12,11, 12,10, 12,11, 11,11, 12,10, 12,11, 11,11, 12,11, 11,33, 12,33, 11,33, 12,33, 12}; // Protocol=NEC Address=0x4BBA Command=0xF Raw-Data=0xF00F4BBA 32 bits LSB first
Result as microseconds array – compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[67] = {8980,4470, 580,520, 580,1670, 580,520, 580,1670, 580,1620, 630,1620, 580,570, 580,1620, 580,1670, 580,1670, 580,520, 580,1670, 580,520, 580,520, 580,1670, 580,520, 630,1620, 580,1670, 580,1620, 630,1620, 580,570, 580,520, 580,570, 530,570, 580,520, 580,570, 530,570, 580,570, 530,1670, 580,1670, 530,1670,
580,1670, 580}; // Protocol=NEC Address=0x4BBA Command=0xF Raw-Data=0xF00F4BBA 32 bits LSB first
uint16_t address = 0x4BBA;
uint16_t command = 0xF;
uint64_t rawData = 0xF00F4BBA;
Pronto Hex as string
char prontoData[] = “0000 006D 0022 0000 015B 00AA 0018 0012 0018 003F 0018 0012 0018 003F 0018 003D 001A 003D 0018 0014 0018 003D 0018 003F 0018 003F 0018 0012 0018 003F 0018 0012 0018 0012 0018 003F 0018 0012 001A 003D 0018 003F 0018 003D 001A 003D 0018 0014 0018 0012 0018 0014 0016 0014 0018 0012 0018 0014 0016 0014 0018 0014 0016 003F 0018 003F 0016 003F 0018 003F 0018 06C3 “;
writeStr.length = 360
**************************************************************
receive_IR_process finishd
**************************************************************
「登録」ボタンが押されました。
(以上)
コメント