Joe123456
Newbie
Hello everyone,
Thank you in advance for your time!
I am using MCP3008 (10 bit ADC)+MPU6050 connected to an ESP32 to send some sensors data over Bluetooth. I used FreeRtos (to which I am really new) to speed up the process and collect more data over time.
I attached parts of my code. (Task1 and Task 2 have the same content so I didn't put it.)
My goal is to get the maximum amount and same number of data points over time.
Any help or Info would be appreciated.
Thanks a lot!
Thank you in advance for your time!
I am using MCP3008 (10 bit ADC)+MPU6050 connected to an ESP32 to send some sensors data over Bluetooth. I used FreeRtos (to which I am really new) to speed up the process and collect more data over time.
I attached parts of my code. (Task1 and Task 2 have the same content so I didn't put it.)
- For some reason the amount of data sent by each task is not always the same over a defined time. Some times the difference is huge. For example for Task1 I get 200 data points/sec for each ADC channel and in task2 700 for each channel.
- I tried different task priorities / changed the stack size but it got worse
- Sometimes two tasks output overlap
Any help or Info would be appreciated.
Thanks a lot!