esp32s2 uart interrupt example

Posts: 7
Joined: Wed Aug 26, 2020 4:58 pm

esp32s2 uart interrupt example

Postby ankayca » Mon Aug 31, 2020 11:06 am

Hi this is my first post so sorry for mistakes.

I want to use uart interrupt with esp32s2 but there are no clear code in this site.

I achieved to step in ISR function.
Problem is that I can get rx_fifo_len but I can not get any data
ISR function :

Code: Select all

static void IRAM_ATTR uart_intr_handle(void *arg)
uint16_t len,t=0;
len = UART1.status.rxfifo_cnt;

ESP_EARLY_LOGI("hallo bro","this is is : %s",buff[t]);
//sprintf(buff,"this is it!%d",t);
//uart_write_bytes(EX_UART_NUM, (const char*) buff, 40);



esp32 work with

Code: Select all

but esp32s2 has ahb_fifo instead of fifo so I used

Code: Select all

and still I can not read data. What is wrong with me/this ?
I stuck with this 1 week and I want to use interrupt instead of freeRTOS(like examles of esp-idf ) thanks for your help!!!!

Note: I want to step in İSR byte by byte so I think there are some config about it . How can I config for step in byte by byte ?

Who is online

Users browsing this forum: No registered users and 4 guests