Page 1 of 1

WiFi Lora 32 board and ESP-IDF

Posted: Mon Sep 25, 2017 9:48 am
by Alnitak
Has anyone got the Heltec WiFi Lora 32 board working with ESP-IDF?

Mine appears to successfully flash, but when I run "make monitor" I get output like this:

Code: Select all

ets Jun  8 2016 00:22:57

rst:0x1 (POWERON_RESET),boot:0x17 (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:1
load:0x3fff0010,len:4
load:0x3fff0014,len:7692
load:0x40078000,len:0
load:0x40078000,len:13564
entry 0x40079318
W (23) rtc_clk: Possibly invalid CONFIG_ESP32_XTAL_FREQ setting (40MHz). Detected 26 MHz.
?n???$n?
        c?lB?p~?o?$???b??????b$b???B???lc?
                                          ?{r??p??o??????oN?p?n??Br?N?lol?n????$n?
No matter what baud rate I set for the monitor I get garbage appearing.

Thanks.

Re: WiFi Lora 32 board and ESP-IDF

Posted: Mon Sep 25, 2017 10:13 am
by ESP_Sprite

Code: Select all

rtc_clk: Possibly invalid CONFIG_ESP32_XTAL_FREQ setting (40MHz). Detected 26 MHz.
is on point; your board probably has a 26MH crystal but your project is configured for a 40MHz one. Run make menuconfig and go to components -> esp32-specifc -> main xtal frequency to change this.

Re: WiFi Lora 32 board and ESP-IDF

Posted: Mon Sep 25, 2017 3:32 pm
by Alnitak
Thanks - that was it. I'd found the flash speed setting for 26 MHz, but not the main crystal setting!

Re: WiFi Lora 32 board and ESP-IDF

Posted: Sun Dec 10, 2017 6:38 pm
by yo2lts
Yes! Work! Thanks! This is the problems! Lora working 26Mhz

Re: WiFi Lora 32 board and ESP-IDF

Posted: Wed Jan 03, 2018 10:49 am
by Valerii
Hello, I have just started with ESP32 and tried to run esp-idf gatt-server example on Heltek board. I configured everthing as described in idf tutorials, successfully built in eclipse and flashed to device. The monitor shows:

Code: Select all

...
I (613) GATTS_DEMO: REGISTER_APP_EVT, status 0, app_id 0
I (623) GATTS_DEMO: CREATE_SERVICE_EVT, status 0,  service_handle 40
I (623) GATTS_DEMO: SERVICE_START_EVT, status 0, service_handle 40
I (633) GATTS_DEMO: ADD_CHAR_EVT, status 0,  attr_handle 42, service_handle 40
I (633) GATTS_DEMO: the gatts demo char length = 3
I (633) GATTS_DEMO: prf_char[0] =11
I (633) GATTS_DEMO: prf_char[1] =22
I (633) GATTS_DEMO: prf_char[2] =33
I (643) GATTS_DEMO: ADD_DESCR_EVT, status 0, attr_handle 43, service_handle 40
I (643) GATTS_DEMO: REGISTER_APP_EVT, status 0, app_id 1
I (643) GATTS_DEMO: CREATE_SERVICE_EVT, status 0,  service_handle 44
E (653) BT: osi_mem_dbg_record invalid !!
I (653) GATTS_DEMO: SERVICE_START_EVT, status 0, service_handle 44
I (653) GATTS_DEMO: ADD_CHAR_EVT, status 0,  attr_handle 46, service_handle 44
I (663) GATTS_DEMO: ADD_DESCR_EVT, status 0, attr_handle 47, service_handle 44
And thats all, no BLE scanned by nRF Connect. I checked "esp_ble_gap_ "functions return values and they are all 0. But It seems that bluetooth hardware does not work. Please help.

Re: WiFi Lora 32 board and ESP-IDF

Posted: Fri Jan 05, 2018 4:23 am
by mbutura
Could you specify what branch you are on? I could test with the Heltec board I have.

Re: WiFi Lora 32 board and ESP-IDF

Posted: Fri Jan 05, 2018 4:42 am
by chegewara
Valerii wrote:Hello, I have just started with ESP32 and tried to run esp-idf gatt-server example on Heltek board. I configured everthing as described in idf tutorials, successfully built in eclipse and flashed to device. The monitor shows:

Code: Select all

...
I (613) GATTS_DEMO: REGISTER_APP_EVT, status 0, app_id 0
I (623) GATTS_DEMO: CREATE_SERVICE_EVT, status 0,  service_handle 40
I (623) GATTS_DEMO: SERVICE_START_EVT, status 0, service_handle 40
I (633) GATTS_DEMO: ADD_CHAR_EVT, status 0,  attr_handle 42, service_handle 40
I (633) GATTS_DEMO: the gatts demo char length = 3
I (633) GATTS_DEMO: prf_char[0] =11
I (633) GATTS_DEMO: prf_char[1] =22
I (633) GATTS_DEMO: prf_char[2] =33
I (643) GATTS_DEMO: ADD_DESCR_EVT, status 0, attr_handle 43, service_handle 40
I (643) GATTS_DEMO: REGISTER_APP_EVT, status 0, app_id 1
I (643) GATTS_DEMO: CREATE_SERVICE_EVT, status 0,  service_handle 44
E (653) BT: osi_mem_dbg_record invalid !!
I (653) GATTS_DEMO: SERVICE_START_EVT, status 0, service_handle 44
I (653) GATTS_DEMO: ADD_CHAR_EVT, status 0,  attr_handle 46, service_handle 44
I (663) GATTS_DEMO: ADD_DESCR_EVT, status 0, attr_handle 47, service_handle 44
And thats all, no BLE scanned by nRF Connect. I checked "esp_ble_gap_ "functions return values and they are all 0. But It seems that bluetooth hardware does not work. Please help.
Could you run make menuconfig and change Component config->Log output to debug or verbose?

Re: WiFi Lora 32 board and ESP-IDF

Posted: Thu Jan 18, 2018 5:01 pm
by Valerii
Thank you for advice,
I think the problem was in wrong setup so I took clean sdkconfig file and configured serial port and it started to work.

Re: WiFi Lora 32 board and ESP-IDF

Posted: Tue Feb 19, 2019 10:57 pm
by fasani
Did someone manage to compile this for the Heltec boards ?

Even having changed this setting in menuconf:

CONFIG_ESP32_XTAL_FREQ_40=
CONFIG_ESP32_XTAL_FREQ_26=y
CONFIG_ESP32_XTAL_FREQ_AUTO=
CONFIG_ESP32_XTAL_FREQ=26

I still see the same error in the console log:
[0;33mW (64) rtc_clk_init: Possibly invalid CONFIG_ESP32_XTAL_FREQ setting (40MHz). Detected 26 MHz.