Go Down

Topic: Interfacing an Esplora to an Xbee (Read 23675 times) previous topic - next topic

TheKitty

I connected an Xbee to my Esplora via the new expansion header.

See details on http://21stdigitalhome.blogspot.com/2012/12/arduino-esplora-interfaced-to-xbee-radio.html.

I used a small modification to the EsploraRemote example to use Serial1 (the hardware serial) rather than the USB Serial port.  Rather simple if you have the new expansion pinout documented at http://21stdigitalhome.blogspot.com/2012/12/esplora-expansion-header-pinouts.html

Hopefully this will provide you all with some ideas on making the Esplora your next wireless controller.

Acererak

Stick a battery on it, have it communicate with an Uno with a motor controller and you got yourself an RC car. Good job.

TheKitty


Stick a battery on it, have it communicate with an Uno with a motor controller and you got yourself an RC car. Good job.


Yes, the next step in this project would be a LiPo batter backpack.  Nothing baked into the Esplora so I'll have to roll one myself. 

I'm thinking the Adafruit LiPo unit http://adafruit.com/products/259 or http://adafruit.com/products/280 but they probably will not output 5 volts.

Also, which connection to use to output the juice - I was thinking of hijacking one of the TinkerKit connectors to push in 5 volts.

Anyone have good thoughts?

Acererak

I was thinking of trying this http://www.liquidware.com/shop/show/MBP/Lithium+Backpack

TheKitty

I couldn't wait to make it fully wireless, so I strapped on a cell phone emergency battery.  I also updated the code to output ASCII characters when the buttons are pressed and joystick moved (similar to example EsploraKart but to the XBee radio rather than to the Esplora Keyboard interface).

Details, Youtube vid, code at http://21stdigitalhome.blogspot.com/2013/01/arduino-esplora-as-fully-wireless.html

This is a very intriguing idea. I wonder if it might be possible to connect the Seeed Studio XBee Shield (http://www.seeedstudio.com/depot/xbee%C2%AE-shield-p-419.html), through the ISCP headers instead of the TFT expansion headers?  If at all possible, this would be a major bonus as this shield, like the Esplora itself, is widely distributed (in the U.S at least) at Radio Shack retail outlets. 
The shield has a small footprint and is meant to attach to a standard controller with a full ISCP Header and a single row header but fits nicely on the Esplora using only the ISCP- (See Attached Photo-https://picasaweb.google.com/lh/photo/sB5WVVc86AXqcR_F13Qwz9MTjNZETYmyPJy0liipFm0?feat=directlink
The only major downside is the same problem that affects any product produced by Seeed Studio...  The extreme lack of documentation!  The product wiki page- http://www.seeedstudio.com/wiki/index.php?title=XBee%C2%AE_Shield still officially applies to version 1.1 even though the current version is 1.2, and while differences between them appear to be minimal, the documentation is confusing in any case...
  I've never used the ISCP headers, or SPI Communications at all for that matter before, and from what I've been able to gather, the Leonardo has an altogether different pinout of these headers anyway. 
  So is this a possibility?  It would make your suggestion significantly easier to deploy for a great many people!

TheKitty

#6
Jan 02, 2013, 03:41 am Last Edit: Jan 02, 2013, 03:51 am by TheKitty Reason: 1
The ICSP uses SPI (MISO, MOSI, SCK) and these are also connected to the Esplora 10 pin expansion header.  XBees and similar radios communicate over TTL serial (RX, TX).  You are right that the Seeed documentation is rather poor.  

I did use the SoftwareSerial library to connect to the XBee (in addition to the Serial1 hardware connection) and it works as expected.  So one could repurpose two of the pins in the ICSP header to do TTL serial communications, yes.  The Seeed code uses pins 11 and 12 and NewSoftSerial and that should work... But you most likely could not also do display on the new expansion header as this uses these SPI pins in their intended configuration.

A better option could be to use D3 and D11 exposed on the two orange TinkerKit connectors with SoftSerial.  These would not interfere with the display or SPI functionality.  There is not a pre-made board for this though.

Keep up working on possibilities.

TheKitty

I used the Esplora/XBee/Battery controller today to send the joystick and button commands to another XBee on an Uno with an Adafruit motor shield to move a robotic head.

Details at http://21stdigitalhome.blogspot.com/2013/01/wireless-arduino-esplora-controls.html

ArduinoNewbie246

Alright, so ive been working on a school capstone project. i chose to design and build a quadcopter that would be able to hopefully lift a small camcorder. I decided to use an Esplora as the controller and constructed a decent powersource to make it portable. as for the quadcopter itself, i chose to use a general Arduino Uno rev3. i am using a wireless sd shield along with an ADAFRUIT motorshield v2. the RF communication is to be handled by two XBEE 900 pro rf modules wire antenna. my problem is that i have completed the programming for both microcontrolling, while it verifies correctly and uploads no problem, however, communication will not progress beyond that point. the esplora functions on a serial monitor basis. i dont beleive the code is completely wrong, nor do i doubt the issue is hardware related. the esplora will not connect or communicate with the xbee, the uno part works fine if i use the terminal on the xctu software  with the xbee.

TheKitty

Ok, you have an xbee powered by 3.3 volts.  What pins on Esplora do you have the TX and RX connected?  Remember TX on one goes to RX of the other.  You can use SoftwareSerial to use any two pins, again cross connect.

ArduinoNewbie246

Alright, so i used Digital pin 0 and digital pin 1,  pins 7 and 8 respectively, rx tx respectively, i am using a usb explorer for the xbee and am running the tx(pin 8) to the DIn pin on the explorer, and RX(oin7 ) to Dout on the explorer.i am powering through the 5v pin on the exploer since it has a built in regulator. http://t0.gstatic.com/images?q=tbn:ANd9GcQVkgrG6JyH68fYdo1bG5SaTD4yiND3Nxv764CguynQpLzoNJh_-g:www.karlssonrobotics.com/cart/prodimages/11373-03.jpg

ArduinoNewbie246

i didnt use Software Serial to code the esplora, but instead used Serial1 would this be ok? or would u recommend SoftwareSerial, or possible NewSoftSerial?

ArduinoNewbie246

I got the remote to work just fine. it sends the correct signals to the Uno and thus controls the motor speeds correctly

ArduinoNewbie246

the remote transmits signals fine, but as i  increase the slider, the motors on the copter start to tap out and sputter, could it just be ho i have the battery hooked up? i think as the pwm increases, the gnd and vcc pins on the board cannot handle it, maybe i should run a separate ground straight to the battery instead of shortcutting it through the board.

Go Up