1 / 18

Data Collection U sing Z igbee Network

Data Collection U sing Z igbee Network. Timothy Melton Moscow, ID. Introduction. Problem: I wanted a way to monitor analog inputs to microcontrollers using a zigbee wireless network with a central gathering point

mikaia
Download Presentation

Data Collection U sing Z igbee Network

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Data Collection Using Zigbee Network Timothy Melton Moscow, ID

  2. Introduction • Problem: I wanted a way to monitor analog inputs to microcontrollers using a zigbeewireless network with a central gathering point • Solution: Using three xbee brand transceivers and two pic32 microcontrollers I was able to setup a short range network for data monitoring and collection

  3. Hardware • 3 Xbee 1mW w/Chip Antenna zigbeetranceivers • 1 XBee Explorer USB • 1 Personal computer w/serial terminal • 2 pic32mx4 microcontroller experimenter boards

  4. Xbee Transceiver • RF Data Rate: 250 kbps • Indor/Urban Range:100 ft (30 m) • Transmit Power: 1 mW (+0 dBm) • Frequency Band: 2.4 GHz • Interfaces: I2C, SPI, UART • Uses Zigbee communication standard • IEEE 802.15.4

  5. PIC32MX4 • Max Speed MHz: 80 • Program Memory Size (KB): 512 • RAM (KB): 32 • A/D channels 16 • RTCC Yes • UART 2

  6. Microcontroller layout Transmitter 2 (z2) Transmitter 1 (z1)

  7. Collection layout Collection Unit

  8. Implementation

  9. Implementation

  10. Implementation

  11. Configuration • Microprocessor recievers • Set as endpoint device on network • Harcoded to send to router • UART to transceiver • 9600 BAUD • No flow control, 8-bit, no-parity, 1 stop bit • UART receive interrupt • Collector • Set as router • Broadcast messages • Transceiver to serial • Matching serial configuration in terminal

  12. Method • Microcontroller units • Addressed z1 and z2 • Read ADC measurements every second • Attach time to the measurments • Use fprintf statement to write to a buffer • Record past three readings • Wait for go signal from collector • Broadcast last three readings • Collector • Broadcasts go command with specific address • Recieves data from zigbee through uart into terminal • Displays readings in terminal

  13. Method Continued • Since the microcontroller has a realtime clock and calendar getting the time was a matter of initalizing the time and then polling and storing it to a variable for the printf function • A polling timer was setup to check whether the one second ADC sample delay was met • To put the packet together for sending: fprintf(uartbuff, “z1:: %d:%d - r1:%5.3f r2:%5.3f r3:%5.3f\r\n” hour, min, adc1, adc2, adc3); “z1:: 14:22 – r1:01.334 r2:02.454 r3:05.287” • packet is generated each time the adc is read • Uartbuff3 = uartbuff2; uartbuff2 = uartbuff; • then assign to uartbuff each time through to keep track of last three readings.

  14. Method Continued • The Collector will send out command: zx go where x is the microcontroller address • A UART receive interrupt is generated in both receivers • Receivers parse which receiver is getting the go signal • Appropriate receiver sends three buffers to collector

  15. Problems • Configuring XBEE transceivers • Firmware flashing issues • Only certain available firmwares were able to be flashed • Working firmware limited network setup • Only able to implement router and endpoint configuration • Support for newer firmware hidden

  16. Areas for Improvement • Buying better xbeetrancievers • Newer models • Support more features (xbee pro, encryption, mesh networks) • More expensive models • Support longer ranges and have more antennae options • Collector time logging • Takes the burden off of the micro for keeping track of time • Prevents transmitting data from interfering with time information • Would keep track of when received instead of when gathered • Writing a program to collect data • Enables better storage options • Terminal outputs to screen • Enables parsing of data for better usage/readability

  17. Conclusion • Zigbee provides many options for setting up wireless networks • UART communication is an effective means to interface with transceivers • PIC32MX4 is very capable of receiving analog inputs and packetizing the data to be transferred over Zigbee.

  18. Questions

More Related