espressif / esp-rainmaker

ESP RainMaker Agent for firmware development
Apache License 2.0
431 stars 145 forks source link

Please help! i want to add ir signal receiver....with rainmaker... (MEGH-4320) #239

Closed nravin5 closed 1 year ago

nravin5 commented 1 year ago

We want to provide IR remote control along with rainmaker.... can any one tell how to add this eg. ir_nec_transceiver

when I try to add i got boot loop.....

thanks in advance.

serial log 👎

ELF file SHA25 cd5820,len:0x16d8 load:0x403cc710,len:0x96c load:0x403ce710,len:0x2e94 entry 0x403cc710 I (35) boot: ESP-IDF v5.0 2nd stage bootloader I (35) boot: compile time 19:38:31 I (35) boot: chip revision: v0.3 I (37) boot.esp32c3: SPI Speed : 80MHz I (42) boot.esp32c3: SPI Mode : DIO I (46) boot.esp32c3: SPI Flash Size : 4MB I (51) boot: Enabling RNG early entropy source... I (532mI (60) boot: ## Label Usage Type ST Offset Length I (67) boot: 0 sec_cert unknown 3f 06 0000d000 00003000 I (75) boot: 1 nvs WiFi data 01 02 00010000 00006000 I (82) boot: 2 otadata OTA data 01 00 00016000 00002000 I (90) boot: 3 phy_init RF data 01 01 00018000 00001000 I (97) boot: 4 ota_0 OTA app 00 10 00020000 00190000 I (105) boot: 5 ota_1 OTA app 00 11 001b0000 00190000 I (112) boot: 6 fctry WiFi data 01 02 00340000 00006000 I (120) boot: End of partition table I (124) esp_image: segment 0: paddr=00020020 vaddr=3c110020 size=46c48h (289864) map I (176) esp_image: segment 1: paddr=00066c70 vaddr=3fc960[0;32mI (179) esp_image: segment 2: paddr=0006a2c4 vaddr=40380000 size=05d54h ( 23892) load I (186) esp_image: segment 3: paddr=00070020 vaddr=42000020 size=109a54h (1088084) map I (354) esp_image: segment 4: paddr=00179a7c vaddr=40385d54 size=10160h ( 65888) load I (366) esp_image: segment 5: paddr=00189be4 vaddr=50000010 size=00010h ( 16) load I (373) boot: Loaded ap[0m I (373) boot: Disabling RNG early entropy source... I (386) cpu_start: Pro cpu up. I (395) cpu_start: Pro cpu start user code I (395) cpu_start: cpu freq: 160000000 Hz I (395) cpu_start: Application information: I (398) cpu_start: P19:38:03 I (414) cpu_start: ELF file SHA256: 4b89514a2db020bd... I (420) cpu_start: ESP-IDF: v5.0 I (424) heap_init: Initializing. RAM available f0000020 len 00001FE0 (7 KiB): RTCRAM I (451) spi_flash: detected chip: generic I (456) spi_flash: flash io: dio W (460) rmt(legacy): legacy driver is deprecated, please migrate to driver/rmt_tx.h and/or driver/rmt_rx.h I (470) coexist: coexist rom version 9387209 I (475) cpu_start: Starting scheduler. I (480) esp_rmaker_console: Initialising UART on port 0 I (480) uart: queue free spaces: 8 I (490) esp_rmaker_commands: Registering command: up-time I (490) esp_rmaker_commands: Registering command: mem-dump I (500) esp_rmaker_commands: Registering command: task-dump I (500) esp_rmaker_commands: Registering command: cpu-dump I (510) esp_rmaker_commands: Registering command: sock-dump I (520) esp_rmaker_commands: Registering command: heap-trace I (520) esp_rmaker_commands: Registering command: reset-to-factory I (530) esp_rmaker_commands: Registering command: add-user I (540) esp_rmaker_commands: Registering command: get-node-id I (540) esp_rmaker_commands: Registering command: wifi-prov I (550) esp_rmaker_commands: Registering command: local-time I (550) esp_rmaker_commands: Registering command: tz-set I (560) esp_rmaker_commands: Registering command: cmd I (570) gpio: GPIO[9]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:3 I (580) gpio: GPIO[19]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 I (590) pp: pp rom version: 9387209 I (590) net80211: net80211 rom version: 9387209 I (600) wifi:wifi driver task: 3fcac290, prio:23, stack:6656, core=0 I (600) system_api: Base MAC address is not set I (610) system_api: read default base MAC address from EFUSE I (620) wifi:wifi firmware version: 0d470ef I (620) wifi:wifi certifica: 32 I (650) wifi:Init static tx FG buffer num: 2 I (650) wifi:Init static rx buffer size: 1600 I (650) wifi:Init static rx buffer num: 10 I (660) wifi:Init dynamic rx buffer num: 32 0m I (660) wifi_init: tcpip mbox: 32 I (670) wifi_init: udp mbox: 6 I (670) wifi_init: tcp mbox: 6 I (680) wifi_init: tcp tx win: 5744 I (680) wifi_init: tcp rx win: 5744 I (680) wifi_init: tcp mss: 1440 I (690) wifi_init: WiFi IRAM OP enabled I (690) wifi_init: WiFi RX IRAM OP enabled I (700) esp_rmakerwork;32mI (710) esp_mqtt_glue: AWS PPI: ?Platform=APN3|A0|RM|EX00|RMDev|1x0|34B472E72F14 I (710) esp_mqtt_glue: Initialising MQTT I (720) esp_rmaker_mqtt_budget: MQTT Budgeting initialised. Default: 100, Max: 1024, Revive count: 1, Revive period: 5 I (730) app_main: RainMaker Initialised. I (730) esp_rmaker_node: Node ID ----- 34B472E72F14 I (740) esp_rmaker_ota_using_topics: OTA enabled with Topics I (740) esp_rmaker_ota: OTA state = 2 I (750) esp_rmaker_time I (750) esp_rmaker_time: Initializing SNTP. Using the SNTP server: pool.ntp.org I (760) app_insights: Enable CONFIG_ESP_INSIGHTS_ENABLED to get Insights. I (770) esp_rmaker_core: Starting RainMaker Work Queue task I (780) esp_rmaker_work_queue: RainMaker Work Queue task started. W (780) BTDM_INIT: esp_bt_mem_release not implem0) wifi_prov_scheme_ble: BT memory released I (790) app_wifi: Already provisioned, starting Wi-Fi STA W (800) BTDM_INIT: esp_bt_mem_release not implemented, return OK I (810) wifi_prov_scheme_ble: BTDM memory released I (810) esp_rmaker_local: Event 6 I (820) phy_init: phy_version 912,d001756,Jun 2 2022,16:28:07 I (850) wifi:mode : sta (34:b4:72:e7:2f:14) I (850) wifi:enable tsf I (860) wifi:new:<11,2>, old:<1,0>, ap:<255,255>, sta:<11,2>, prof:1 I (860) wifi:state: init -> auth (b0) I (860) wifi:state: auth -> assoc (0) I (870) wifi:state: assoc -> run (10) I (88:94:93:2e:b9:e3 I (880) wifi:security: WPA2-PSK, phy: bgn, rssi: -47 I (880) wifi:pm start, type: 1

I (880) wifi:set rx beacon pti, rx_bcn_pti: 14, bcn_timeout: 14, mt_pti: 25000, mt_time: 10000 I (980) wifi:BcnInt:102400, DTIM:1 W (6510) wifi:idx:0 (ifx:0, 24:94:93:2e:b9:e3), tid:0, ssn:4, winSize:64 I (7090) app_wifi: Connected with IP Address:192.168.1.6 I (7090) esp_netif_handlers: sta ip: 192.168.1.6, mask: 255.255.255.0, gw: 192.168.1.1 I (7090) esp_rmaker_local: Starting ESP Local control with HTTP Transport and security version: 1 E (7100) rmt(legacy): rmt_set_gpio( (7110) esp_https_server: Starting server I (7110) esp_https_server: Server listening on port 8080 I (7120) esp_rmaker_local: esp_local_e: Connecting to a1p72mufdu6064-ats.iot.us-east-1.amazonaws.com I (7140) esp_rmaker_core: Waiting for MQTT connection E (7150) rmt(legacy): rmt_config(673): set gpio foCHECK failed: esp_err_t 0x102 (ESP_ERR_INVALID_ARG) at 0x42008d30 0x42008d30: IRrecvInit at C:/Espressif/frameworks/esp-idf-v5.0/esp-rainmaker/examples/switch/main/IRRemote.c:37 (discriminator 1)

file: "/IDF/esp-rainmaker/examples/switch/main/IRRemote.c" line 37 func: IRrecvInit expression: rmt_config(&config)

abort() was called at PC 0x4038c59d on core 0 0x4038c59d: _esp_error_check_failed at C:/Espressif/frameworks/esp-idf-v5.0/components/esp_system/esp_err.c:47

Core 0 register dump: MEPC : 0x40380922 RA : 0x4038c5a8 SP : 0x3fca3630 GP : 0x3fc96800 0x40380922: panic_abort at C:/Espressif/frameworks/esp-idf-v5.0/components/esp_system/panic.c:412

0x4038c5a8: __ubsan_include at C:/Espressif/frameworks/esp-idf-v5.0/components/esp_system/ubsan.c:313

TP : 0x3fc5d414 T0 : 0x37363534 T1 : 0x7271706f T2 : 0x33323130 S0/FP : 0x00000004 S1 : 0x3fca3694 A0 : 0x3fca365c A1 A6 : 0x7a797877 A7 : 0x76757473 S2 : 0x3fcb3a2c S3 : 0x3fcb397c S4 : 0x00000000 S5 : 0x00000000 S6 : 0x00000000 S7 : 0x00000000 S8 :56463 T6 : 0x62613938 MSTATUS : 0x00001881 MTVEC : 0x40380001 MCAUSE : 0x00000007 MTVAL : 0x00000000 0x40380001: _vector_table at ??:?

MHARTID : 0x00000000

Stack memory:000001 0x3c1318c8 0x3fc98b58 3fca3650: 0x3fca3694 0x3fc98b74 0x3fca3690 0x726f6261 0x20292874 0x20736177 0x6c6c6163 0x61206465 3fca3670: 0x43502074 0x34783020 0x63383330 0x20643935 0x63206e6x64393563 0x3fcb3900 0x3fcb3a2c 0x3fcb3904 0x3fc9ffc0 0x4038c5a0 0x4038c5a0: esp_system_abort at C:/Espressif/frameworks/esp-idf-v5.0/components/esp_system/esp_system.c:134

3fca36b0: 0x00000000 0x3fcb3904 0x3fc9ffc0 0x42008d34 0x01cb3a2c 0x00000001 0x00000007 0x00000002 0x42008d34: IRrecvInit at C:/Espressif/frameworks/esp-idf-v5.0/esp-rainmaker/examples/switch/main/IRRemote.c:38 (discriminator 1)

3fca36d0: 0x42020264 0x42025334 0x01643e80 0x00000001 0x420255b0 0x00000000 0x00000000 0x00000000 0x42020264: mdns_service_add_for_host at C:/Espressif/frameworks/esp-idf-v5.0/esp-rainmaker/examples/switch/managed_components/espressif__mdns/mdns.c:5584

0x42025334: set_config_service at C:/Espressif/frameworks/esp-idf-v5.0/components/wifi_provisioning/src/scheme_ble.c:119

0x420255b0: wifi_prov_scheme_ble_event_cb_free_btdm at C:/Espressif/frameworks/esp-idf-v5.0/components/wifi_provisioning/src/scheme_ble.c:196

3fca36f0: 0x3fcb3a2c 0x3fcb3904 0x3fc9ffc0 0x42008c22 0x3fca4dd0 0x00000000 0x3fca3734 00000000 0x3fca0bb4 0x00000000 0x00000000 0x00000000 0x00000000 0x42109652 0x42008c22: app_main at C:/Espressif/frameworks/esp-idf-v5.0/esp-rainmaker/examples/switch/main/app_main.c:257

0x42109652: main_task at C:/Espressif/frameworks/esp-idf-v5.0/components/freertos/FreeRTOS-Kernel/portable/port_common.c:132 (discriminator 2)

3fca3730: 0x00000000 0x00001388 0x00000001 0x00000000 0x00000000 0x00000000 0x00000000 0x4038ffa4 0x4038ffa4: prvTaskExitError at C:/Espressif/frameworks/esp-idf-v5.0/components/freertos/FreeRTOS-Kernel/portable/riscv/port.c:139

3fca3750: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 3fca3770: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0x00000154 0x3fca3540 0x0000000c 0x3fc99da8 0x3fc99da8 3fca3790: 0x3fca3780 0x3fc99da0 0x00000018 0x3fca9804 0x3fca9804 0x3fca3780 0x00000000 0x00000001 3fca37b0: 0x3fca277c 0x6e69616d 0xadae3b0x00000000 0x3fca0ea0 0x3fca0f08 0x3fca0f70 0x00000000 3fca37f0: 0x00000000 0x00000001 0x00000000 0x00000000 0x00000000 0x420f30e8 0x00000000 0x00000000 0x420f30e8: _cleanup_r at ??:?

3fca3810: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 3fca3830: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 3fca3850: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 3fca3870: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 3fca3890: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 3fca38b0: 0x00000000 0x00000000 0x00000000 0x00000000 000000000 3fca38d0: 0x3f000000 0x00000600 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 3fca38f0: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 3fca3930: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa55 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 3fca3970: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 3fca3990: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5 0xa5a5a5a5 3fca39d0: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 3fca39f0: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5aa5a5 0xa5a5a5a5 3fca3a10: 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5

ELF file SHA256: 4b89514a2db020bd

Rebooting... ESP-ROM:esp32c3-api1-20210207 Build:Feb 7 2021 rst:0x3 (RTC_SW_SYS_RST),boot:0xc (SPI_FAST_FLASH_BOOT) Saved PC:0x403806ce 0x403806ce: esp_restart_noos_dig at C:/Espressif/frameworks/esp-idf-v5.0/components/esp_system/esp_system.c:46 (discriminator 1)

shahpiyushv commented 1 year ago

@nravin5 , it is hard to comment without any details about the code modifications you did to integrate the idf example into RainMaker, but since RainMaker uses the same RMT driver for the WS2812 RGB LED, it is worth trying to disable it using idf.py menuconfig -> Component config -> WS2812 RGB LED -> Enable RGB LED (de-select)