An Arduino library for easy graphing on host computer via serial communication
This removes an old duplicate call to initialize serial comms for backwards compatibility. Seemed to be causing issues on ESP32 boards
Related issues: https://github.com/devinaconley/arduino-plotter/issues/31 https://github.com/devinaconley/arduino-plotter/issues/34
Updated to follow newer Arduino 1.5+ library spec https://arduino.github.io/arduino-cli/library-specification/
This also removes need for the manager-compliant duplicate repo, which will be deleted.
Improvements for more efficient memory usage
h/t @Chritzel
Merged PR to fix compiler warnings, made graph.size private, fixed bug in SetColors for 6 vars, better timescale for quickstart
Added Begin() function to handle Plotter initialization (Serial.begin and storing millis()). This lets us avoid repeated call to default constructor with implicit copy to global plotter. The copy was showing undefined behaviour
Note: duplicate calls were left in default constructor for the sake of backward compatibility
Switch from using dtostrf to Serial.print with decimal specified. The function dtostrf is only available on AVR devices, so this should be better for usability across all boards.
Converted to flattened-JSON for serialization. While the full form is slightly slower, it enabled easy recognition of packet formats. So now, a full configuration packet is only sent at a 50-count interval, where the rest are data-only packets. Overall this change improved data transfer speeds by over 2x
Converted to a templated wrapper for storing references to plotted variables. This introduces support for all primitive data types. Added example to show this and did a general refactor of function and variable names
First official version.
Arduino Library features include multi-variable (up to 6) graphing against time, X vs Y graphing, dynamic addition and removal of graphs, and an easy no-argument plot command to update all graphs.
Listener application automatically configures plot layout, handles axis auto-scaling, and plots rolling data live as it is received from the Arduino.