PropScope with Linux?
kane
Posts: 11
Hi,
I recently bought a PropScope from Parallax, it is a nice device
and works well on my WinXP laptop.
I've got a little Ubuntu netbook that I would like to use to take
some simple measurements, I do not need a fancy GUI just a way to
stream values from CH 1/2.
Has anyone used Linux to talk to the PropScope? I've taken
a quick look at the document:
PropScope Protocol
V0.8 February 2010
Hanno Sander
and have some technical questions.
For example, how do I download the firmware to
the device from Linux? The protocol doc says:
On launch, the UI uses the Propellent library
available from Parallax to detect and reset a
Propeller whose USB name is “PropScope”.
(It uses "-*,+PropScope" as a Serial Search
Rule). Once reset, it loads “propscope.binary”
from the propscope/firmware directory to
the Propeller RAM and runs it.
Is the source to the Propellent library available?
Thanks,
Pat Kane
---
I recently bought a PropScope from Parallax, it is a nice device
and works well on my WinXP laptop.
I've got a little Ubuntu netbook that I would like to use to take
some simple measurements, I do not need a fancy GUI just a way to
stream values from CH 1/2.
Has anyone used Linux to talk to the PropScope? I've taken
a quick look at the document:
PropScope Protocol
V0.8 February 2010
Hanno Sander
and have some technical questions.
For example, how do I download the firmware to
the device from Linux? The protocol doc says:
On launch, the UI uses the Propellent library
available from Parallax to detect and reset a
Propeller whose USB name is “PropScope”.
(It uses "-*,+PropScope" as a Serial Search
Rule). Once reset, it loads “propscope.binary”
from the propscope/firmware directory to
the Propeller RAM and runs it.
Is the source to the Propellent library available?
Thanks,
Pat Kane
---
Comments
Glad you like the PropScope. I doubt Parallax's Propellent will be ported to anything- critical parts are written in x86 assembly.
However, you don't actually need to load the firmware each time- you can load it, or any other Propeller image to EEPROM once using a windows tool like ViewPort. Once programmed, you can talk to PropScope using the serial port of your OS. Reading the Ch1 and Ch2 measurements isn't too hard- easiest way is to write your own firmware. To do it right you would take advantage of the calibration data written into EEPROM and allow setting of the prescaler and ac/dc coupling. Then, write that data out over serial.
Hanno
need to be reloaded after I unplug the device.
> you can talk to PropScope using the serial port of your OS
I assume you mean a USB serial port such as /dev/ttyUSB0.
When I send commands and read CH1/CH2 values do I need to use the
Three Bit Protocol (3BP)?
The one described here: http://propeller.wikispaces.com/Download+Protocol
Thanks for the help,
Pat
---
To get the probe attached to Ubuntu Linux I did the following:
/sbin/modprobe -q ftdi_sio product=0x0080 vendor=0x13e2
then there was /dev/ttyUSB0 device that I could access.
The excellent tool "bst.linux" was able to find
the PropScope, so I did some reverse-engineering by
running "strace" on the running "bst" program and
watched commands it sent; then wrote a C program
that sends that same messages.
I've got Linux program, with source, that can detect the PropScope!
Version 2 of my test program tries to talk to the
PropScope firmware by sending commands that are
documented in the "PropScope Protocol V0.8".
The following 8 byte "Send data" protocol message
0x00 0x00 0x00 0x04 0x00 0x00 0x00 0xff
was sent, but I get no response from the PropScope.
I did more reverse-engineering tonight by using the
SnoopyPro USB sniffer while PropScope was running on
my WinXP laptop. After loading the firmware, I can
see the Win software issue the same 8 byte command
that I tried above. The PS then starts to send samples
in 4K byte packets.
What am I missing?
In the trace I can see what looks like two message that are
not documented in the V0.8 version of the spec:
0x00 0x00 0x00 0x03 0x00 0x00 0x00 0xff
0x00 0x00 0x00 0x07 0x00 0x00 0x00 0xff
they are issued near the time that I push the stop button.
Is there a newer version of the spec?
Pat
---
Use the Source Luke!
Pat
---