Using comma separated variables(CSV) to send data from picaxe to a spreedsheet

Hi,
Does anyone know how to use a Picaxe chip to send data ( ie Temp, Light level etc..) direct to a spreed-sheet for analysis ? I think that the serout command could be used but I'm not sure. I'm a school teacher in the UK ( technology /systems and control ) and am trying to introduce "do it yourself " data logging to science year 12 students , most of who do not have any electronics/ programming skills.
Any info would be much appreciated !!!

Thanks
Tony
 
Hi Tony,

I use a program that has been mentioned on this forum before, PLX-DAQ from Parallax Inc - http://classic.parallax.com/downloads/plx-daq.

I have used this program on many occasions, sending measured data to EXCEL using the serout command. You can also arrange for the PICAXE to send the formulae for adjacent cells where additional calculations need to be made.

Richard




Hi,
Does anyone know how to use a Picaxe chip to send data ( ie Temp, Light level etc..) direct to a spreed-sheet for analysis ? I think that the serout command could be used but I'm not sure. I'm a school teacher in the UK ( technology /systems and control ) and am trying to introduce "do it yourself " data logging to science year 12 students , most of who do not have any electronics/ programming skills.
Any info would be much appreciated !!!

Thanks
Tony
 

Skiwi

New Member
sertxd(#b2,",",#b3,", ",#b1,",",cf,lf)

this outputs the values of b2, b3 and b4 to the serial port and can be viewed on the programming editor by pressing F8 to open the terminal .
cr,lf is the line feed, put this at the end of the sertxd line so the data lines up in the appropriate columns.

To get the data to a file, connect the picaxe TX data line to a serial in port on a pc (pin3 on a DB9 serial cable and pin 1 common). Run a terminal program such as terraterm and set it to log the data.
when finished, stop the data log in the terminal program and save the file.
Open Excel.
Then open the saved file. you will need to select 'open all files' (dont double click on the data file in explorer and select a program to open with, this has different results)
Excel will ask you to select the delimiter, in my example it is the comma, for a CSV file Then you have a spreadsheet full of data!

A better alternative to the programming terminal port, use any output pin of the picaxe chip (actual output to use depends on the chip, check the manual2)
for example, to send to output a.5, serout a.5, N9600,(#b3,",", #b2,"," #b0,cr,lf)

You can change the delimiter to anything you want, spaces, other signs
You can also send fixed words or characters, e.g. "temp=",#b1, " light level=",#W4,


And Macrobeak, Makerplot looks brilliant for logging and displaying the data. But can you advise if it plots negative values? I cant figure it in their tutorials, which are also brilliant, apart from the aforementioned negative issue.

edit:26/04. I bought Makerplot. It does negative vales OK. Does everything I want well, and should answer the initial question in this thread. Best feature in my application, is that it saves a new plot at a pre-determined time or data setting, which other applications I have tried dont do. Try the trial. But you need to be patieint and keep restarting while learning, as it times out after 3 minutes.
 
Last edited:

MFB

Senior Member
My understanding is that MakerPlot is (unlike its predecessor, StampPlot Pro) not free, but there is a 30 day free trial version available. Nuts % Volt magazine has been running an excellent series of tutorials by Martin Hebel and John Gavik. Well worth reading in addition to all the on-line material and video guides.
 

mrburnette

Senior Member
Jamster has working HID mouse code, Non-HID-compliant-mouse so if the USB table can be changed to be a HID 1.1 keyboard, then very interesting things can be done.

The Excel formulas in this spreadsheet will parse a data-stream from a microcontroller. If you have HID keyboard, then the rest is just Excel.
HID with Excel

@Jamster, the keyboard HID descriptors implemented in PicBASIC are here: HID keyboard

Good luck,

Ray
 
Top