Connecting Cheapstat to arduino over Serial Tx, Rx, Line



  • Hello,

    I have connected the Cheapstat to an arduino uno by soldering a wire to the TX line of the FT232. I want to output results over bluetooth eventually but first I want to understand how the Cheapstat is transferring data over the serial line. At the moment the data I'm receiving looks like sheet 2 the attached Excel file while when I use the Cheapstat Java interface with the normal usb cable the data looks like sheet 1. Can anyone recommend what code I need to write in Arduino (or another method) to convert the concatenated data in sheet 2 into useful results show in sheet 1?

    The Excel spreadsheet shows 4 different tests using SWV where I first used the usb&Java method of collecting data and then ran the same test for a second time but recorded the data from the Serial Monitor in Arduino IDE. Spreadsheet is here

    Thank you,

    FE



  • @FE

    The best documentation for the serial data sent by the cheapstat is probably the firmware source. You can download it from here http://web.chem.ucsb.edu/~kwp/cheapstat/

    I've also but a copy of the firmware in a repository on bitbucket which includes a makefile for building and uploading the fimrware on linux https://bitbucket.org/iorodeo/cheapstat_firmware/src

    Note, we are not the original authors of the cheapstat firmware, but I have some familiarity with it. In the cheapstat.c file each test has its own function. For example for the CV test the function is called "CV_test". The serial data is sent at the bottom of this function. As an example, in the "CV_test" function look at the code following the "//start output to USB" comment.


Log in to reply