Forum

Welcome Guest 

Show/Hide Header

Welcome Guest, posting in this forum requires registration.





Pages: [1]
Author Topic: Wireless XRF
TeamTeamUS-
A
Newbie
Posts: 22
Permalink
Post Wireless XRF
on: February 22, 2013, 10:44
Quote

Moving this comment thread to the forum: http://www.polargraph.co.uk/2012/10/driving-polargraphsd-wirelessly/#comments.

I've got my wireless bits and am now troubleshooting. Here's what I've got:

* PolargraphSD
* Polargraph Controller (PGC) 1.2.5 (running from source in Processing 1.5.1)
* Polargraph Server (PGS) 1.4.1
* XRF inserted in PolargraphSD shield XBee socket
* SRF USB dongle inserted in laptop USB socket
* OS X 10.7.4

I've confirmed that the SRF and XRF are compatible and can communicate at both 9600 and 57600 baud using this sketch http://www.openmicros.org/index.php/entry/getting-my-pc-to-send-and-recieve-llap-with-processing. I can see the LED flicker as the data is received on the XRF.

Both the SRF and XRF have factory defaults, which enables pass-through serial communication: http://openmicros.org/index.php/articles/88-ciseco-product-documentation/260-srf-configuration

However when I start or restart the PolargraphSD, this gibberish, or a variation thereof, displays in the Processing console (hex data in ASCII?):

incoming: ÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃ
incoming: §5%’w5%d§∫Äî-¡Ñ°t%?O‡pGÊ ÇÃÃÃÃÃÃ
incoming: §5%’w5%d§∫Äî-¡Ñ°t%?O‡pGÊ ÇÃÃÃÃÃÃÃÃÃÃ

Consequently, since the PGC expects ASCII commands like "READY" and "SYNC", the PGC and PGS never complete their handshake, and the Polargraph cannot be controlled wirelessly. This happens with the baudrate set to either 9600 or 57600 via the config file.

Sandy, when you were running your Polargraph wirelessly you mentioned you had to run it at 9600 baud. How did you do that? Was it simply changing the value in the PGC default config? Did you have to change the baudrate on the PGS too?

Thanks for any assistance. Really want to get this working...

Go!

=ml=

sandy
Administrator
Posts: 1317
Permalink
sandy
Post Re: Wireless XRF
on: February 22, 2013, 15:43
Quote

Hey yes it was a bit of a fandangle to get it working. I think some of my confusion was cleared up when I realised that there are two different speeds at work - the speed of the radio communication, and the speed of the serial communication at either end. They can all be different. I used a pair of XRFs, they communicated with each other at 57600 baud. The good-XRF also outputted it's electronic serial comms at 57600 because I asked it to (default was 9600). I put this one on the polarshield.

The bad-XRF could have it's serial speed changed to 57600 to speak to the polargraph controller (via a xbee adapter USB thingy), but it wouldn't remember it past a reset, returning to 9600 after a power cycle. Hence the feature to change the speed in the controller.

I used the XCM app (http://www.openmicros.org/index.php/articles/84-xrf-basics/105-xcm-software-config-for-the-xrf) to change the speed, I guess you are too. There's a serial monitor in that software that lets you see the raw comms, you could try fiddling with the baud speeds and see if any of them improve your messages. Or the Arduino serial monitor maybe. I get the gibberish when I've got a mismatched baud rate.

sn

airzone
Beginner
Posts: 33
Permalink
Post Re: Wireless XRF
on: February 22, 2013, 22:06
Quote

Same thing happened with my bluetooth mod - the comms rate between the module and arduino was mismatched. I had to change the BT module's baud rate to 57600 (using AT commands in my case).

TeamTeamUS-
A
Newbie
Posts: 22
Permalink
Post Re: Wireless XRF
on: February 26, 2013, 05:23
Quote

Sandy, airzone, thanks for the info. 🙂

I ordered the XBBO http://shop.ciseco.co.uk/xbbo-break-out-board-for-xbee-shaped-modules/ thinking I could use it to change the XRF configuration if needed. Turns out I can't without a bunch of fiddling, so I ordered a proper adapter: http://www.ebay.com/itm/XBee-BTBee-Bluetooth-Bee-USB-Adapter-XBee-Explorer-Arduino-E102-/251130105512

Sandy, what's the best way to remove the XBee area in the case? I started to score the lines on top and realized that there weren't similar lines on the case side.

I may just mod the STL and print out a new case part. If I do, I'll send you the STL file so you can add it to the repo.

Go!

=ml=

sandy
Administrator
Posts: 1317
Permalink
sandy
Post Re: Wireless XRF
on: February 26, 2013, 09:23
Quote

Aye it needs to be an FTDI type of serial-to-usb board - like the xbee explorer. To remove the xbee section, I think I last used some snips, then finished it off with a knife. because the panel is shaped to fit an XBee rather than an XRF.

Pages: [1]
Mingle Forum by cartpauj
Version: 1.0.34 ; Page loaded in: 0.02 seconds.