原本iic例程适用gpio2和14作为iic引脚,我用来读mpu6050是可以读的,然后切换了其他引脚也可以但是唯独gpio4和5不行,一直在打印乱码和重启,下面是打印的内容
I (336) gpio: GPIO[4]| InputEn: 0| OutputEn: 1| OpenDrain: 1| Pullup: 0| Pulldown: 0| Intr:0
I (340) gpio: GPIO[5]| InputEn: 0| OutputEn: 1| OpenDrain: 1| Pullup: 0| Pulldown: 0| Intr:0
ESP_ERROR_CHECK failed: esp_err_t 0xffffffff (ESP_FAIL) at 0x402116f4
0x402116f4: _esp_error_check_failed at /home/lmnb66/esp/ESP8266_RTOS_SDK/components/freertos/port/esp8266/panic.c:206
file: "user_main.c" line 204
func: i2c_example_master_mpu6050_init
expression: i2c_example_master_mpu6050_write(i2c_num, PWR_MGMT_1, &cmd_data, 1)
abort() was called at PC 0x402116f7 on core 0
0x402116f7: _esp_error_check_failed at /home/lmnb66/esp/ESP8266_RTOS_SDK/components/freertos/port/esp8266/panic.c:207
Guru Meditation Error: Core 0 panic'ed (StoreProhibited). Exception was unhandled.
Core 0 register dump:
PC : 0x402137fa PS : 0x00000030 A0 : 0x402137f8 A1 : 0x3ffeb920
0x402137fa: abort at /home/lmnb66/esp/ESP8266_RTOS_SDK/components/newlib/src/syscall.c:69 (discriminator 1)
0x402137f8: abort at /home/lmnb66/esp/ESP8266_RTOS_SDK/components/newlib/src/syscall.c:69 (discriminator 1)
A2 : 0x00000000 A3 : 0xffffffdb A4 : 0x00000001 A5 : 0x00000001
A6 : 0x00000000 A7 : 0x40228e30 A8 : 0x3ffeb900 A9 : 0x00000004
A10 : 0x00000000 A11 : 0x00000020 A12 : 0x00000000 A13 : 0x00000000
A14 : 0x00000000 A15 : 0x00000000 SAR : 0x0000001e EXCCAUSE: 0x0000001d
Backtrace: 0x402137fa:0x3ffeb920 0x402116fa:0x3ffeb930 0x40213514:0x3ffeb940 0x40213648:0x3ffeb960
0x402137fa: abort at /home/lmnb66/esp/ESP8266_RTOS_SDK/components/newlib/src/syscall.c:69 (discriminator 1)
0x402116fa: _esp_error_check_failed at ??:?
0x40213514: i2c_example_master_mpu6050_init at /home/lmnb66/esp/esp8266/i2c/main/user_main.c:205 (discriminator 2)
0x40213648: i2c_task_example at /home/lmnb66/esp/esp8266/i2c/main/user_main.c:227
esp8266 rtos sdk iic引脚问题
Re: esp8266 rtos sdk iic引脚问题
从你的crash来看,我比较怀疑 IO4 和 IO5 你有用到其他外设上面
Who is online
Users browsing this forum: No registered users and 169 guests