Zigbee
From charlesreid1
Background
My Zigbee Configuration
Here is a picture of the configuration I'm using for my Zigbee: the radio chip itself is attached to a breakout board, which has a mini usb plug on it. I've got two Zigbees and two breakout boards.
I'm currently working through how to control the Zigbee directly from the computer via the mini usb cable.
How Zigbee Works
From this page: https://learn.sparkfun.com/tutorials/xbee-shield-hookup-guide
They explained it pretty clearly. What makes Zigbee such a popular format is that it is simple. There is no extensive coding that needs to be done, no IDE, no microcontroller instructions. It is a serial interface. This means you can think of it like a wireless serial terminal.
That means this page, on using the screen command in Linux to communicate with serial devices, is gonna come in handy: www.cyberciti.biz/faq/unix-linux-apple-osx-bsd-screen-set-baud-rate/
On your computer, when you plug in a Zigbee device (e.g., with a mini USB cable like the one pictured above), it will be added as a device in /dev/*. Using that device file, you can interact with the serial device using the screen command.
Getting Zigbee Working
Here's the rundown of the steps:
- find the device
- figure out how to connect to the device
- determine parameters necessary
- ...
- profit?
Find the device
To find the device file that shows up when I plug the Zigbee mini USB into the Mac, I'm looking for a device file that's added to /dev/* when I plug in the Zigbee. Here's how I did that:
Before I plug in the Zigbee, I list all the devices in /dev. Then, I plug in the Zigbee. Then I list all the devices in /dev/ again. I compare the two lists, and I have my Zigbee.
Bingo: I can see two new devices corresponding to the Zigbee,
/dev/cu.usbserial-A601FA3K /dev/tty.usbserial-A601FA3K
Finding Baud Rate
From the SparkFun XBee Shield Hookup Guide, it looks like the connection rate to the zigbee is 9600 baud. https://learn.sparkfun.com/tutorials/xbee-shield-hookup-guide
We need to make a 9600 baud serial connection from the Mac to the Zigbee.
Connecting to the device
Connecting using screen
I used the instructions on this page to connect at 9600 baud to the Zigbee using the screen program: http://www.cyberciti.biz/faq/unix-linux-apple-osx-bsd-screen-set-baud-rate/
I ran:
$ screen /dev/tty.usbserial-A601FA3K 9600,cs8
and I got a "/dev/tty.usbserial' for R/W: resource busy" error message. What that means is, there's already a connection between screen and the zigbee. Use lsof to look for the current session that has a connection with the Zigbee:
$ lsof | grep usbserial screen 837 charles 5u CHR 17,8 0t3 645 /dev/tty.usbserial-A601FA3K
Then you can attach to that session using:
$ screen -x 837
This works like any ordinary session of screen: to detach, run Control+A D to detach, Control+A K to kill, screen -ls to list running sessions, etc.
Projects
HackRF and Zigbee
Main page: HackRF/Zigbee
As of June 2016, I am working on a project to transmit information with a Zigbee, receive the signal with a HackRF, and demodulate the signal with Gnuradio.
References
tutorial on arduino + zigbee: http://cs.smith.edu/dftwiki/index.php/Tutorial:_Arduino_and_XBee_Communication
more on the 802.15 protocol used by zigbee, and how to set up a demodulator in gnuradio: http://wiesel.ece.utah.edu/media/documents/pdf/2010/03/25/thomas_project_report.pdf
download X-CTU, the software used to control and interact with the Zigbee devices: http://www.digi.com/products/xbee-rf-solutions/xctu-software/xctu#productsupport-utilities
Flags
| radio all things radio.
Ham Radio: Notes on General class license: General · Mnemonics/General Class License Digital modes: Radio/Digital Modes
Ham Radio Hardware (Radios): Kenwood TS 440S: Radio/Kenwood/TS440S Kenwood TS 570S: Radio/Kenwood/TS570S Yaesu VX-6: Radio/Yaesu/VX-6 Digital Modes on Raspberry Pi: RaspberryPi/Digital Modes Digital Modes on Arduino: Arduino/Digital Modes DVB-T USB SDR Dongle: DVB-T USB SDR
Ham Radio Software: Software defined radio: SDR Comprehensive list of ham software: Andys Ham Radio Linux Direwolf (soundcard TNC/APRS modem): Direwolf Echolink (internet repeater system): Echolink Qsstv (Slow scan television): Qsstv Fldigi (fast light digital modes): Fldigi Xastir (APRS/AX25/TNC): Xastir RadioHead (packet library for microcontrollers): RadioHead
Category:Radio · Category:Kenwood · Category:Yaesu Flags · Template:RadioFlag · e |