MaXBee PCB, rev. 1

| No Comments
Version 1 of Ray's XBee board; provides:
  1. socket for XBee series 1
  2. power circuitry for a 3.7V LiPo
  3. charging circuitry for a 3.7 LiPo (charges with USB)
  4. 3.3v-5v voltage level shifting to allow more adaptable control
  5. 10-pin "futurlec" style connector for compatibility with off-board boards
As the video shows, timing performance is pretty good.... Version 2 of this board is already in the works; requests welcome!

Maxbee mxj object Update v0.2

| 2 Comments
Quick little code release:

This is an updated version of the xbee api mxj object. This object has the ability to send AT commands to a remote xbee. It also outputs the response from the remote xbee. I have also included the most recent version of the max patch that I am using to test this setup.

Enjoy!
Maxbeev0.2.zip
Maxbee-v0.2.maxpat

----
Dependencies:

Adventures with Xbee-API v0.9, eclipse, and max

| No Comments
The goal of today was to use the xbee-api to send remote commands to an xbee through max.

Xbee-Api download site:

I used this page to get going with the xbee-api in eclipse:

Then I set up the xbees in the exact way that the xbee-api website instructed.

At first I was getting strange errors and I then found out that my txrx jar and dll were meant for a 32 bit os. So I downloaded the necessary 64 bit libraries here:

I was then able to turn on an led wired to the remote xbee by running the RemoteAtExample.java included in the api.

I then put this code into a max mxj object and was able to flash the light remotely from.

To get this to work in max I did the following:
- In the root max directory I placed the 32 bit rxtxSerial.dll
- In \Max 5.0\Cycling '74\java\lib I placed log4j.jar, xbee-api-0.9.jar, and the 32 bit RXTXcomm.jar

Maxbee.java - Source
Maxbee.class - Put this in your Max class path
RemoteBlink.maxpat - Remote blinking example patch

XBee Status Update

| No Comments
Proof of concept state, but things are looking up.


Below are patches for two way communication with x-bees from Cycling '74's Max.
You must have your local (usb/API-coordinator) and remote (wireless/AT-router/endpoint) Series 2.5 Xbees configured with these profiles.  

max files: download
profiles:  download

Notes:
-xbee.js takes in two arguments. The remote xbee's 8 byte address and the 2 byte network address. 
-This whole setup only works if you have 4 analog pins active, and nothings else
-Note that if you turn digital pins on/off, this messages with the analog readings; this will be fixed in the next version!

Secret+Critical Knolwedge:
-When trying to configure a coordinator connected with USB, the remote xbee's can not send too much data (set sampling rates to very low or 0)
-After remote-configuration of a router xbee, you must quit/restart X-CTU before configuring a USB-connected-coordinator xbee

Fun with accelerometers.

| No Comments
Today I worked more on my max patch for dealing with the xbee. So far I have the ability to change the function of different xbee pins by calling a method in a little piece of javascript. I will post this max patch next week after I clean it up a bit.

I also worked some with the accelerometer today. I am working on a max patch that takes the accelerometer readings from the xbee and makes a nice little visual display tilt sensing.

Remote API commands are working perfectly!

and now for range testing...

Sending commands using XBEE API

| 1 Comment
Today was the first time that I successfully sent a command to an xbee using the xbee API protocol.

The xbee is hard wired to my computer using a sparkfun xbee explorer. It is running the XBP24-B ZNET 2.5 ROUTER/END DEVICE API version 1247 firmware.

Using a max patch I sent the following converted the following hex message into decimal values and sent it through serial. 
    0x7E 0x00 0x05 0x08 0x4D 0x44 0x30 0x05 0x31

0x7E = start delimiter 
0x0005 = length
0x08 = AT Command API frame type
0x4D = Frame ID (set to non-zero value) (any value)
0x4430 = AT Command ('D0')
0x05 = value to set command to (pin HIGH output)
0x31 = Checksum

To calculate the checksum: Not including frame delimiters and length, add all bytes keeping only the lowest 8 bits of the result and subtract the result from 0xFF.


This command turns the digital output of pin D0 to HIGH.

This command turns output of pin D0 to LOW:
   0x7E 0x00 0x05 0x08 0x4D 0x44 0x30 0x04 0x32


Xbee Max test patch v.1

| No Comments

Xbee references update

| No Comments
Robert Faludi of ITP/SVA in NYC has done some good work with the xbees. Notable links:


Regarding changing remote module's parameters with AT commands [from the XBee Pro Znet 2.5 manual, pp. 60]:

"Remote AT Command Request

API Identifier Value: 0x17 Allows for module parameter registers on a remote device to be queried or set"

Wireless reading of analog inputs is a success!!

| No Comments
Today we had the xbee transmitting the output from 4 analog signals. 
The following picture shows the I/O settings for the xbee that we are using to transmit the analog data to our computer. It is loaded with XBP24-B ZNET 2.5 ROUTER/END DEVICE AT version 1247 firmware.
xctu.jpg

The receiving Xbee is loaded with XBP24-B ZNET 2.5 ROUTER/END DEVICE API version 1247 firmware.



Troubles With Analog

| No Comments
I stumbled across this webpage that has an example of transmitting analog data with xbees: http://www.kobakant.at/DIY/?p=247

Despite the poor documentation of this experiment, I tried to recreate it. 
Recreation was unsuccessful...

Something good that came out of this experiment is that I found an Xbee API for Processing which could come in handy later. http://www.faludi.com/code/xbee-api-library-for-processing/

A lot of instructions that I came across today asked me to press the reset button on the xbee. Because we have no reset buttons on the xbee, I have found two alternatives. 
  1. Short ground(pin 10) and reset(pin 5)
  2. Or unplug the xbee from the explorer, select a command to execute, and then plug the xbee back into the explorer.

In every analog test that I have run I have used the following photo-resistor circuit.

In the example at the top of this post, they ask you to change a value with the command ATIT. This returns ERROR when entered on the current firmware that is running on the "sender" xbee. I will pursue these analog tests using a different xbee firmware that may have more promising Analog features.

Recent Comments

  • kamp0145: Nicholas, Firstly, you are correct to have ignored the log4j read more
  • n.marechal@lcc.arts.ac.uk: Hi, The Maxbee MXJ works on a Mac too ! read more
  • Ali Momeni: Congratulations Ray, this is an important step! would you please: read more
  • amattern: I have posted in this forum. Hopefully we'll hear something read more

Recent Assets

  • xctu.jpg

Find recent content on the main index or look in the archives to find all content.