Issue: If main loop rate is < 1000 milliseconds, values received over the socket connection are split across multiple lines in the plot.
If you have a fast main loop where each iteration takes less than a second, due to the TCP socket polling in filter_plotter.py, it ends up appending multiple values together into a single string before sending it over to plotserialdata.py, which results in multiple different lines on the plot (legend) instead of a single line with different values.
If you slow down the main loop rate to be >= 1000 ms, it's fine.
It seems to be tied to the hardcoded interval=1000 for the animation function.
ani = animation.FuncAnimation(fig, animate, interval=1000)
FYI, my current fix is to use 100 for the animation interval.
@lemonkey Thank you for sharing your investigation and the finding. I think your finding will be a good FAQ for future. I'll close this issue and put your finding in the Wiki.