Plotting serial data with Matlab. Unlimited channel.
You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
Matlab-plotter
Plotting serial data with Matlab. Unlimited channel.
Usage instruction:
Find out what Serial port your device is connected to. In Matlab, in Matlab 2017, use "seriallist" function, in older verison, use "instrfind".
Change the serial string in code to whatever the port happens to be. e.g. "COM32".
In the microcontroller's code, intitate handshake protocal. (example will be given in Arduino and PSOC). Note, different micro-controllers have different quirks, you have to work it out yourself. e.g. PSOC will ignore the first character of the string.
Give the channel names in you MC codes.
Find out what integer length your MC use, change it in the Matlab code accordingly. The variable name is size_int _. It's in bytes. It's pretty obvious, you can't miss it.
Code the MC to transmit in Little-endian.
Initial the MC before running the Matlab code. Use a dead loop to halt the MC before it start.
Start the Matlab code, and you can see beautiful graphs updating infront of your eyes.
After you terminate the matlab code, remember to run the necessary clean up section of code to save the data to the file in .dat file, which named after the channel name.
Profit.
Resource requirement: I tested the software with i5 7600k and no graphics card. When plotting 3 channel at display data size of 1000, it use approximately 3% of the cpu, 700Mb of RAM.
Cite As
Chen Duona (2026). vanGoghDaVinci/Matlab-plotter (https://github.com/vanGoghDaVinci/Matlab-plotter), GitHub. Retrieved .
General Information
- Version 1.0.0.0 (9.77 KB)
-
View License on GitHub
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux
Versions that use the GitHub default branch cannot be downloaded
| Version | Published | Release Notes | Action |
|---|---|---|---|
| 1.0.0.0 |
