Download presentation
Presentation is loading. Please wait.
Published byRolf Lang Modified over 9 years ago
1
Lab 4 ZigBee & 802.15.4 with PICDEM Z Boards 55:088 Spring 2006
2
Everyone has heard of 802.11… IEEE 802.11 features: Ethernet matching speed, Long range(30-90m) Complexity to handle seamless roaming Message forwarding Data throughput of 2-11Mbit/s
3
…what about 802.15? Specializes in Wireless PAN (Personal Area Network) standards Specializes in Wireless PAN (Personal Area Network) standards 802.15.1 – a.k.a. Bluetooth(1 Mbps) 802.15.1 – a.k.a. Bluetooth(1 Mbps) 802.15.2 - Deals with coexistence of Wireless LAN (802.11) and Wireless PAN 802.15.2 - Deals with coexistence of Wireless LAN (802.11) and Wireless PAN 802.15.3 - High-rate WPAN standards (Wireless USB) 802.15.3 - High-rate WPAN standards (Wireless USB) 802.15.4 – a.k.a ZigBee 802.15.4 – a.k.a ZigBee
4
What is ZigBee about? ZigBee can be found in embedded applications requiring low data rates and low power consumption ZigBee can be found in embedded applications requiring low data rates and low power consumption Fortunately, it is (relatively) low complexity as well Fortunately, it is (relatively) low complexity as well Applications include: Applications include: Embedded sensors Embedded sensors Medical devices Medical devices Smoke and intruder alarms Smoke and intruder alarms Home automation Home automation
5
How does ZigBee form networks? Basic Type: Star Networks Basic Type: Star Networks
6
How does ZigBee form networks? More Complex: Cluster Network More Complex: Cluster Network
7
How does ZigBee form networks? Very Complex: Mesh Networks Very Complex: Mesh Networks
8
What does this have to do with 55:088? Lab 4 will be using 802.15.4 radios to create a wireless serial link between two nodes Lab 4 will be using 802.15.4 radios to create a wireless serial link between two nodes Each group will be provided with the pair of wireless radios on development boards from Microchip Each group will be provided with the pair of wireless radios on development boards from Microchip These kits are NOT to be removed from the lab These kits are NOT to be removed from the lab
9
PICDEM Z Boards
10
CC2420 Radio IC 2.4 GHz RF Transceiver 2.4 GHz RF Transceiver Connect to microcontrollers via SPI Connect to microcontrollers via SPI Comes on a daughter board with the PICDEM Z kit Comes on a daughter board with the PICDEM Z kit 250 kbps data rate 250 kbps data rate 2.1V – 3.6V 2.1V – 3.6V 19.7 mA (RX) 19.7 mA (RX) 17.4 mA (TX) 17.4 mA (TX)
11
18LF4620
12
18LF4620 Microcontroller found with the PICDEM Z kits Microcontroller found with the PICDEM Z kits Overall, very similar to the 18F452 Overall, very similar to the 18F452 Use the MPLAB and C18 compiler to write code for the PIC Use the MPLAB and C18 compiler to write code for the PIC
13
Lab 4 Overview A text-input GUI on a computer will connect via RS-232 to one of the PICDEM Z boards (we’ll call this the Base Station) A text-input GUI on a computer will connect via RS-232 to one of the PICDEM Z boards (we’ll call this the Base Station) The other PICDEM Z board will be connected to a Liquid Crystal Display (LCD) that will display the text messages from the base station (we’ll call this the Remote Station) The other PICDEM Z board will be connected to a Liquid Crystal Display (LCD) that will display the text messages from the base station (we’ll call this the Remote Station)
14
Lab 4 Overview The remote station will have a couple of “switches” which will either indicate an “on” or “off” state The remote station will have a couple of “switches” which will either indicate an “on” or “off” state The switch states need to be sent back to the base station and displayed on the base station GUI The switch states need to be sent back to the base station and displayed on the base station GUI
15
PICDEM Z with LCD
16
GUI Layout on Base Station Use whatever language you wish to create the GUI… Use whatever language you wish to create the GUI…
17
Tools that you will use… Microchip has developed code that makes interfacing with the 802.15.4 radios vastly easier Microchip has developed code that makes interfacing with the 802.15.4 radios vastly easier This is called the “stack” This is called the “stack”
18
Tools that you will use… In order to utilize the stack: In order to utilize the stack: MPLAB v 7.31 MPLAB v 7.31 C18 Compiler C18 Compiler Microchip ZigBee stack v 3.3 Microchip ZigBee stack v 3.3 Look at example files: Look at example files: C:\MpZBee\Source\HCLight\ C:\MpZBee\Source\HCLight\ C:\MpZBee\Source\HCRouter\ C:\MpZBee\Source\HCRouter\ C:\MpZBee\Source\HCSwitchC\ C:\MpZBee\Source\HCSwitchC\ Do NOT alter files in the Stack directory as this could cause the computer (or worse, the TA) to explode Do NOT alter files in the Stack directory as this could cause the computer (or worse, the TA) to explode “Look, but don’t touch” “Look, but don’t touch”
19
Zigbee.def This file should be one of the first files you create This file should be one of the first files you create It selects many key parameters that will define how a particular node will operate: It selects many key parameters that will define how a particular node will operate: Specify Coordinator, Router, or End Device Specify Coordinator, Router, or End Device Frequencies to operate on Frequencies to operate on Power mode Power mode Node address Node address As well as many others… As well as many others…
20
Callback functions In the application code that you will be writing/modifying there are a few required functions In the application code that you will be writing/modifying there are a few required functions These callback functions are named because the stack calls back to the application to gather more data These callback functions are named because the stack calls back to the application to gather more data Definitions and examples can be found in AN965 and documentation on the current version of the stack Definitions and examples can be found in AN965 and documentation on the current version of the stack
21
Callback function example In a coordinator node, we may wish to determine weather it is okay to accept another node trying to associate with the network… In a coordinator node, we may wish to determine weather it is okay to accept another node trying to associate with the network… BOOL AppOkayToAcceptThisNode(LONG_ADDR *longAddr) BOOL AppOkayToAcceptThisNode(LONG_ADDR *longAddr){ if (first three bytes of its MAC address match the coordinator) return TRUE; else return FALSE; }
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.