1/15/2018

Serial Port Data Logger Circuit

20
Serial Port Data Logger Circuit 7,6/10 8972reviews

I’m working on a simple data logger application called ComPlotter that opens a serial port and reads an incoming plain text data stream, plotting one or more signals in realtime in a scrolling window. The incoming data is assumed to be in plain text with the same number of integers (currently assumed to be three) on each line, separated by spaces. The incoming text is printed in a log window and the data values from each line are parsed and plotted in the graph area. ComPlotter is still very much a work in progress, but it’s starting to come together and I have a reasonable looking screenshot, so I thought I’d post a little bit about it.

Serial Port Data Logger CircuitSerial Port Data

Here’s the screenshot of the application as it currently looks. Chris Hendrickson Project Management For Construction Pdf here. The signals displayed in the plot in this screenshot are from a simple accelerometer circuit that I had connected to my PC. The three signals visible in the plot are the x, y and z axes of the accelerometer. ComPlotter tries serial port numbers in descending order, starting with COM30. The idea of this is that a USB-to-serial adapter may be assigned a different COM port number each time it is plugged into the PC, but it is likely to have the highest numbered port each time. In my experience, this is a pretty reliable way of accessing the type of USB-to-serial adapter that I usually use to connect my dsPIC microcontroller circuits to my PC. ComPlotter is written in Python using the wxPython GUI toolkit.

Temperature Data Logger. This is a special memory space on the Circuit Playground that remains. The stored values can be sent over the serial port in one of.

Here’s the complete source code (all 130 lines of it). Hi Walter, Thanks for your comment. When I’m writing Python programs, I don’t use an IDE (integrated development environment) at all – I just write the code in a plain text editor ( is my favourite one for Windows – it’s free and really fast and powerful) and then run it in a console window. You can use any text editor though – even Windows Notepad will be fine.

As you’re probably aware, Python is an interpreted language rather than a compiled language, so you don’t need to install a compiler. However, to run the example above, you need to have the Python interpreter installed (download that from ). You also need to install wxPython (free to download from ) which is what I use to make graphical user interfaces in Python. Finally, because the above example accesses the serial port, you need to install the PyWin32 Python for Windows extensions (free to download from ).