Which MicroPython libraries should I use for ECG with ESP32?

Hello everyone, I'm trying to make ECG using esp32 with micropython, I need help to find the libraries to use in code.
18 Replies
wafa_ath
wafa_ath4w ago
Hi, you can use the machine library for hardware interaction and time for delays.and you can save and plot the data by matplotlib, do you have something specific you want to do!?
Razali Abdelrahmen
Only those txo librairies?, also, Can I use AI to analyse data ?, I mean I want to make GUI with tkinter and add button analyze which takes the data and makes analysis of the patient .
wafa_ath
wafa_ath4w ago
Those are basic libraries, For AI analysis use Python on your computer. Save the ECG data from the ESP32 and transfer it to your computer. Because micropython is not that strong for ai tasks
Razali Abdelrahmen
Ok thank you so much, If I find problems can I ask you again ?,sorry it's my first project.
wafa_ath
wafa_ath4w ago
Absolutely, you can ask in any time, you are very welcome
Razali Abdelrahmen
Hi again, I wanna plot a list of data that contains the values of ECG, thony of micropython doesn't know the library matplotlib.pyplot, what should I do ?, can I plot it in spyder ? If yes how I can do it ?, thank you
Dtynin
Dtynin4w ago
@Razali Abdelrahmen I don't think thonny support standard Python libraries like matplotlib.
Dtynin
Dtynin4w ago
using Spyder would be better for plotting your ECG data.. and Yes you can use Spyder
melta101
melta1014w ago
how are you going to showcase the plot?
melta101
melta1014w ago
On your device or somewhere else? OLED, LCD, etc.. Cant imagine matplotlib to run on those...
Dtynin
Dtynin4w ago
@Razali Abdelrahmen you can import the library matplotlib.pyplot as plt then use plt.plot(data)...hope this helps??
melta101
melta1014w ago
I have a doubt, How does matplotLib get to know which display is used, As we are not passing any display object info to Matplotlib
Razali Abdelrahmen
I wanna plot the graph of an ECG on pc
Razali Abdelrahmen
This message is printed : no module named matplotlib
Razali Abdelrahmen
But my data is on thony, how can I plot it in spyder ?
Want results from more Discord servers?
Add your server