ESP-sparkbot复刻踩坑日记

历经半个月终于复刻成功了

程序来源example · ESP-Friends/esp_sparkbot - 码云 - 开源中国

首先是屏幕显示的问题,烧录程序发现屏幕不显示只有背光板亮,只有烧录human_face_recognition_no_wakenet例程时会显示一个白色背景乐鑫的logo但是再烧录factory_demo_v1例程时还是显示乐鑫logo只不过白色背景变成了黑色而且还有一些彩色小点点,经过查询资料发现可能是spi的通信模式不同于是试着修改了一下spi_mode将2模式改为1模式屏幕就能正常显示了。

文件路径是factory_demo_v1/components/esp_sparkbot_bsp/esp_sparkbot_bsp.c

 const esp_lcd_panel_io_spi_config_t io_config = {
        .dc_gpio_num = BSP_LCD_DC,
        .cs_gpio_num = BSP_LCD_SPI_CS,
        .pclk_hz = BSP_LCD_PIXEL_CLOCK_HZ,
        .lcd_cmd_bits = LCD_CMD_BITS,
        .lcd_param_bits = LCD_PARAM_BITS,
        .spi_mode = 0,
        .trans_queue_depth = 10,
    };

还有就是不知道是不是网络的问题访问天气网站返回403没有返回天气信息我更换了一下网址可以正常使用了。

文件路径是factory_demo_v1/main/app/app_weather.c

#define WEATHER_SERVER      "devapi.qweather.com"
#define WEB_URL_NOW         "https://" WEATHER_SERVER "/v7/weather/now?" _OPTION_MULTI "&" _KEY_
#define WEB_URL_AIR         "https://" WEATHER_SERVER "/v7/air/now?"     _OPTION_ "&" _KEY_

将devapi.qweather.com更换问自己的API Host在和风天气控制台的设置里面可以看到。

还有一个错误未解决就是姿态传感器BMI270物料清单导出直接在嘉立创商城购买的器件应该没有问题,感觉大概率是焊接的问题,只要开启姿态传感器的程序初始化程序运行就会报错索性直接把它注释掉了

    ESP_ERROR_CHECK(esp_netif_init());
    ESP_ERROR_CHECK(esp_event_loop_create_default());
    app_animation_start();
    //app_imu_init();
    bsp_touch_button_create(button_handler);
Error [-3] : Device not found error. It occurs when the device chip id is incorrectly read
E (1488) bmi270: bmi270_sensor_create(5203): bmi270_init failed
I (1492) BMI2: bmi2_coines_deinit
Error [-1] : Null pointer error. It occurs when the user tries to assign value (not address) to a pointer, which has been initialized to NULL.
Error [-1] : Null pointer error. It occurs when the user tries to assign value (not address) to a pointer, which has been initialized to NULL.
Error [-1] : Null pointer error. It occurs when the user tries to assign value (not address) to a pointer, which has been initialized to NULL.
Error [-1] : Null pointer error. It occurs when the user tries to assign value (not address) to a pointer, which has been initialized to NULL. 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值