您的位置: 嵌入式在线 > 解决方案 > 消费电子 > Freescale三轴ZigBee传感参考设计

Freescale三轴ZigBee传感参考设计

2007-10-12      嵌入式在线      收藏 | 打印

        Freescale 公司XYZ三轴低g加速器MMA7360L具有可选择的g范围1.5g/6g, 广泛应用在消费类电子产品如膝上型电脑和MP3播放器的跌落保护,电子罗盘的倾斜补偿和手机翻滚检测

        手持游戏机和游戏控制器的运动检测,g老鼠的位置检测以及非平衡是的振动检测和监视器的震动检测等.MMA7360L参考设计ZSTAR ZigBee传感器设计是小型PCB(56mm x 27mm 或2.20 x 1.10),能为低成本低功耗的无线连接演示喝评估各种加速度应用.传感器板包括两个PCB 2.4GHz天线,CR2032锂离子电池座和三个按钮.而USB板同样有两个PCB 2.4GHz天线,一个按钮和USB “A”插头.本文介绍了MMA7360L ZSTAR的主要性能,以及两块板(传感器板和USB板)的主要电路图.

        Freescale MMA7360L (ZSTAR) Zigbee Sensing Triple Axis Reference Design
MMA7360L ZSTAR REFERENCE DESIGN
The goal of the ZSTAR design was to provide a small portable board with the capability to demonstrate and evaluate various accelerometer applications that accommodate the low-cost low-power wireless connection. One of the considerations for design was to use a small and versatile tool (board size is 56 mm x 27 mm or 2.20 x 1.10). The Sensor board includes two PCB 2.4 GHz antennas, CR2032 Lithium battery holder and the three pushbuttons. The USB stick board has the same two PCB 2.4 GHz antennas, one pushbutton and a USB type “A” plug.

       The MMA7360L ZSTAR demo board (RD3473MMA7360L) is a modification to the original MMA7260Q ZSTAR board described in AN3152 (RD3152MMA7260Q). This board has been updated with Freescale’s newer smaller 3x5x1 mm3 14-pin LGA analog output triple axis accelerometer. The MMA7360L accelerometer is very comparable to the MMA7260Q with a sensitivity of 800mV/g and a g range of 1.5g. There is a sleep mode for power cycling options. The MA7360L accelerometer has a lower current consumption at 400uA in normal mode and 3uA in sleep mode. The MMA7360L has a g-select range between 1.5g and 6g. For the demonstrations used in the ZSTAR board the 1.5g range is the most useful. The internal 32kohm resistor on the MMA7360L has been shunted out and an external 10kohm resistor has been added with a 320nF capacitor to complete a 50Hz low pass filter on the X, Y and Z outputs. The only changes made to the original ZSTAR hardware are on the Sensor Board. The USB board remains identical to the previous version as shown below.

                                                               图1.MMA7360L传感器板外形图

         Hardware Changes for the MMA7360L ZSTAR Sensor Board
         As shown in Figure 1, a push button and a populated 6-pin header has been added to the sensor board along with the MMA7360 14 pin LGA packaged accelerometer which replaces the 16-pin QFN package accelerometer. The 6-pin header has been added to this board to make it easier to update the firmware when changes occur. The connections between the MMA7360L accelerometer and the MC9SO8QG8 microcontroller are shown in Figure 2 of the Sensor Board Schematic. The new accelerometer has only 1 g-select pin (pin10) which is connected to PTB1 on the microcontroller. The g-select by default is in 1.5g mode, and therefore set to 0. The 0g detect internal logic pin (pin 9) on the MMA7360L is connected to PTB0 on the microcontroller. The self test pin (pin 13) on the MMA7360L is connected to a pushbutton so that the self test function can be activated when the push button is held down. The Z output should increase by 1g when the push button is pressed. The self test function validates the correct operation of the g-cell. 

         PC GUI Updates for the MMA7360L ZSTAR
         The Triax GUI PC-software for this demonstration has been updated using Visual Studio C# Express 2005 Edition along with a tool box from National Instruments to implement some of the graphing tools and gauges. Many of the algorithms have been improved along with some additional applications. These improved demonstrations are designed to allow visualization of key accelerometer applications in the consumer industry as well as the low-cost 2.4 GHz wireless solution based on the MC13191 transceiver. For information and detailed guidance on using the updated Triax Software please refer to the Triax Reloaded 1.0 User Manual. Details about the algorithms used in the software can be found in various application notes and also on the “about” screens in the software.

         FEATURED FREESCALE PRODUCTS
         The ZSTAR is a two-board design where a MMA7360L triple axis accelerometer is controlled by an 8-bit MCU MC9S08QG8 and connected via a wireless link to a computer. The USB stick connects via the computer’s USB slot. For the USB communication, a Full-Speed USB 2.0 8-bit microcontroller MCHC908JW32 is employed. The various Freescale products in this demonstration are detailed below.

         Triple Axis Accelerometer MMA7360L
         The ZSTAR board is a demonstration tool for the MMA7360L, a 3-Axis Low-g accelerometer. The MMA7360L has many unique features that make it an ideal solution for many consumer applications such as freefall protection for laptops and MP3 players, tilt detection for e-compass compensation and cell phone scrolling, motion detection for handheld games and game controllers, position sensing for g-mice, shock detection for warranty monitors, and vibration for out of balance detection.
Features such as low power, low current, and sleep mode with a quick turn-on time allow the battery life to be extended in end applications. The 3-axis sensing in a small LGA package requires only 3 mm x 5 mm board space, with a profile of 1 mm, allowing for easy integration into many small handheld electronics.
There are several other derivatives of MMA7360L: MMA7340L 3g/12g, MMA7330L 4g/16g.

         All members of this sensor family are footprint (LGA package) compatible, which simplifies the evaluation and design of the target application.

        Microcontroller MC9S08QG8
         The MC9S08QG8 is a highly integrated member of Freescale’s 8-bit family of microcontrollers based on the high-performance, low-power consumption HCS08 core. Integrating features normally found in larger, more expensive components, the MC9S08QG8 MCU includes a background debugging system and on-chip in-circuit emulation (ICE) with real-time bus capture, providing single-wire debugging and emulation interface. It also features a programmable 16-bit timer/pulse-width modulation (PWM) module (TPM) that is one of the most flexible and cost-effective of its kind.

         The compact, tightly integrated MC9S08QG8 delivers a versatile combination and wealth of Freescale peripherals and the advanced features of the HCS08 core, including extended battery life with maximum performance down to 1.8 V, industry-leading Flash and innovative development support. The MC9S08QG8 is an excellent solution for power and size-sensitive applications, such as wireless communications and handheld devices, small appliances, Simple Media Access Controller (SMAC)-based applications and toys.

         MC13191 2.4 GHz ISM Band Low Power Transceiver
         The MC13191 is a short range, low power, 2.4 GHz Industrial, Scientific, and Medical (ISM) band transceiver. The MC13191 contains a complete packet data modem which is compliant with the IEEE® 802.15.4 Standard PHY (Physical) layer. This allows the development of proprietary point-to-point and star networks based on the 802.15.4 packet structure and modulation format. For full 802.15.4 compliance, the MC13192 and Freescales 802.15.4 MAC software are required.
         When combined with an appropriate microcontroller (MCU), the MC13191 provides a cost-effective solution for short-range data links and networks. Interfacing the MCU is accomplished by using a four wire serial peripheral interface (SPI) connection and an interrupt request output which allows for the use of a variety of processors. The software and processor can be scaled to fit applications ranging from simple point-to-point to star networks.

         MC13192/MC13193 2.4 GHz Low Power Transceiver for the IEEE® 802.15.4 Standard
The MC13192 and MC13193 are short range, low power, 2.4 GHz Industrial, Scientific, and Medical (ISM) band transceivers. The MC13192/MC13193 contains a complete 802.15.4 physical layer (PHY) modem designed for the IEEE® 802.15.4 wireless standard which supports peer-to-peer, star, and mesh networking.
         The MC13192 includes the 802.15.4 PHY/MAC for use with the HCS08 Family of MCUs. The MC13193 also includes the 802.15.4 PHY/MAC plus the ZigBee™ Protocol Stack for use with the HCS08 Family of MCUs. With the exception of the addition of the ZigBee™ Protocol Stack, the MC13193 functionality is the same as the MC13192.

         When combined with an appropriate microcontroller (MCU), the MC13192/MC13193 provides a cost-effective solution for short-range data links and networks. Interfacing the MCU is accomplished by using a four wire serial peripheral interface (SPI) connection and an interrupt request output which allows for the use of a variety of processors. The software and processor can be scaled to fit applications ranging from simple point-to-point systems, through complete ZigBee™ networking.

         Microcontroller MCHC908JW32
         The MCHC908JW32 is a member of the low-cost, high-performance M68HC08 Family of 8-bit microcontroller units (MCUs). All MCUs in the family use the enhanced M68HC08 central processor unit (CPU08) and are available with a variety of modules, memory sizes and types, and package types.

         FIRMWARE

         This reference design contains two pieces of firmware. The first one is on the Sensor board MCU (MC9S08QG8). Its job is to collect sensor data from the MMA7360L accelerometer, create a data packet and send it over the SMAC (Simple Media Access Controller) driver using the MC13191 RF Transceiver. 
         The sensor data is measured over three channels of the Analog-to-Digital converter, while another GPIO pin controls the sleep mode of the MMA7360L accelerometer to conserve power.

         Serial Peripheral Interface (SPI) is used for communication with the MC13191.

         The overall application is powered from the coin-sized CR2032 Lithium battery that is located on the bottom side of the board. The overall average current consumption is below 1 mA with 20 data transmissions per second rate. This allows approximately 10 days of continuous operation at this real-time data rate.
         The simple ZSTAR RF protocol also transfers the calibration data. These data are stored in non-volatile Flash memory and are transferred on request.

         The second piece of firmware is contained within the USB stick board and its job is to create a “bridge” between the RF link and the USB connection. The sensor and keyboard data are received from the Sensor board and stored in the USB stick RAM memory. Another independent process is the USB protocol communication. Several options are possible. USB specifications define several ways of transferring data between the USB peripheral and the PC (called “profiles” or classes). In this demo two classes are demonstrated:
         The Microsoft™ Windows 2000/XP operating system contains by default a driver support for these classes which makes this solution simple for demonstration purposes.

         If the serial communication (virtual serial port) is demonstrated, the accelerometric data is available through the simple serial protocol compatible with the STAR demo. Thus most of the RD3473MMA7360L is usable also for data visualization.
         Alternatively, if the HID class is demonstrated, the ZSTAR demo behaves as a mouse. By tilting the sensor board, the mouse cursor movement can be controlled.

         SUMMARY
         Multi-axis sensing using an XYZ-axis low g acceleration sensor, MMA7360L with selectable g-ranges of 1.5g/6g, is combined with the versatile MC9S08QG8 8-bit microcontroller. The 2.4 GHz wireless communication is enabled by RFCMOS technology. The MC13191 is a member of the pin-to-pin compatible series of Freescales transceivers, including the MC13192 which supports the IEEE 802.15.4 protocol and the MC13193 which supports full ZigBee™ compliant applications. Please refer to AN3152 for the complete details of the original design of the ZSTAR RD3152MMA7260Q.

                                                                  图2. MMA7360L传感器板电路


                                                                                 图3. USB板电路图

        详情请见:

        http://mcuol.com/download/upfile/AN3473.pdf

本文来源:Freescale 公司    作者:

隐藏原文↑


查看原文↓

验证码:  看不清?换一张

 

快乐大本营
工程师之星
高福东
擅长嵌入式开发及单片机应用开发
  • 王波涛  熟悉单片机及其接口技术
  • 朱伟平  熟悉51单片机系统LCD驱动程序编写及调试。
热门招聘
论坛热贴