Wearable network refers to a new type of personal area network (PAN) based on short-range wireless communication technology (Bluetooth and ZigBec technology, etc.) and wearable computer (wearcomp) technology, which is worn on the human body and has the ability to intelligently collect information about the human body and the surrounding environment. Wearable computers can provide core computing technology for wearable networks. Short-range wireless communication technologies such as Bluetooth and ZigBee with Ad Hoc performance are used as the underlying transmission means, combining their respective advantages to form a wireless, highly flexible, self-organizing, and even hidden micro PAN. Wearable networks have the characteristics of mobility, persistence, and interactivity.

  1 Wearable Network Architecture Based on Bluetooth and ZigBee

  Wearable networks are flexible and highly mobile, and have a variety of ways to access external networks. They can access the Internet at full speed via LAN and ADSL through Bluetooth gateways, Bluetooth set-top boxes, etc. When they move over a large area, they can use Bluetooth mobile phones as a means of access, making wearable networks highly mobile. The current architecture of wearable networks based on Bluetooth and ZigBee is shown in Figure 1. The devices in the system include host, Bluetooth devices, ZigBee devices, and Bluetooth/ZigBec gateways.

  1.1 Host part

  Wearable computers require the host to be light and small in size due to their wearability. The host chip uses the IAnux embedded operating system with an integrated Bluetooth protocol stack. Due to the bandwidth limitations of multimedia streams and GPRS backbone networks in head-mounted display systems, the host is required to have a high storage capacity and an internal 10GB hard disk. The main purpose of integrating a Bluetooth adapter in the host is to enable the host to communicate with other Bluetooth devices. If conditions permit, a GPS module can also be integrated into the host.

  1.2 Bluetooth devices

  The Bluetooth device in the wearable network is a miniaturized device with a built-in Bluetooth module. The collected data is transmitted between the host and the Bluetooth device (such as a Bluetooth mobile phone) through a Bluetooth link.

  The head-mounted display system integrates a micro Bluetooth module, a camera and a DSP chip. The camera collects the initial image and sends it to the DSP chip for pre-processing to remove the redundancy of the video and image signals. The video compression standard can use MPEG-4. The signal processed by the DSP can be directly sent to the display or host for further processing.

  Bluetooth headsets can transmit audio signals with other Bluetooth devices, control the host through voice commands, or transmit voice signals to a remote end through GPRS, CDMA and TD-SCDMA networks.

  1.3 ZigBee Devices

  ZigBee devices can be designed as watches and insoles, etc. It includes sensors, MD converters and ZigBee modules. The sensors collect external signals (heartbeat, blood pressure, pulse, temperature and humidity, etc.) and convert them into electrical signals, which are then converted by A/D converters and sent to the MCU. Finally, they are sent to the host through the ZigBee transceiver module and the A-gate. After being processed by the host, they are transmitted to other devices.

  1.4 Bluetooth/ZigBoe Gateway

  The Bluetooth/ZigBee gateway is mainly aimed at the mutual communication between Bluetooth and ZigBee products in wearable network wireless communications. Its protocol model is shown in Figure 2.

Wearable Network Architecture

Protocol Model

  2 Hardware Implementation of Wearable Networks Based on Bluetooth and ZigBee

  The architecture of wearable networks mainly includes the hardware platforms of ZigBee nodes and gateways. The following introduces the hardware implementation of these two platforms. [page]

  2.1 Hardware Implementation of ZigBoa Node

  As a sensor, the main function of ZigBee node is to collect data of interest to users and send the data to the Bluetooth/ZigBee gateway, and then to the remote control center or database via GPRS, CDMA or WI-FI. The hardware block diagram of ZigBee node is shown in Figure 3. It mainly consists of power module, microcontroller (MCU), memory, ZigBee transceiver and sensor.

ZigBee node hardware block diagram

  The MCU in the system uses the 8-bit MC9SOSGB60 of the HC(S)08 series of Freescale. The MC9S08GB60 has rich on-chip storage functions and has 64KB of storage space (of which Flash occupies 60KB and RAM occupies 4KB). At an operating frequency of 40MHz, its power consumption is less than 1mW. In addition, the microcontroller has a variety of power-saving modes to choose from. In addition to having rich on-chip storage functions and a variety of power-saving modes, the MC9S08GB60 microcontroller also has 8 lObit A/D converters, multiple I/O data lines, 2 serial communication interfaces (SCI), and a four-wire serial peripheral interface (SPI). These features make it easy to program software, and its interface can also be used as an interface with sensors.

  The communication module of the entire ZigBee node is implemented by the ZigBee transceiver. The ZigBee transceiver uses Freescale's MCl3192. This transceiver works in the 2.4GHz ISM public channel. The features of MCl3192 are as follows:

    (1) It has 16 channels;
    (2) The typical transmission power is 0dBm, and the maximum transmission power reaches 3.6dBm;
    (3) It uses DSSS spread spectrum communication technology, with a maximum rate of 250Kbps;
    (4) When the packet error rate is 1%, its receiving sensitivity reaches -92dBm (typical value);
    (5) There are 7 general input and output ports (GP10).
    The entire ZigBee node is powered by AAA batteries.

 2.2 Hardware Implementation of Bluetooth/ZigBoe Gateway

 

  Gateway plays a very important role in wearable network. Bluetooth, ZigBee gateway hardware is mainly composed of ZigBee module, Bluetooth module and central processing unit.

  The central processing unit of the gateway mainly completes the conversion work between Bluetooth and ZigBee protocols. When host data is sent from a ZigBee device to a Bluetooth adapter, the Bluetooth/ZigBee gateway needs to perform the following processing in sequence: remove the ZigBee packet at the physical layer from the data received from the ZigBee device; remove the ZigBee packet at the MAC layer; add the Bluetooth packet with the L2CAP header; add the Bluetooth packet with the physical layer header. When data is sent from a Bluetooth device to a ZigBee device, the process is similar.

  The main device of the central processing unit is Freescale's MC68HC-908KL8 microprocessor. This microprocessor has 16 flexible addressing modes and efficient instruction sets; it supports online reprogramming, which can meet the needs of low-cost programming changes and on-site software upgrades; the programming speed is extremely fast, and 64B encoding is completed within 2ms. The extremely fast programming speed reduces the product programming cost: up to 26 bidirectional I/O ports, and the high-current I/O ports can directly drive LEDs and other circuits, thereby eliminating external drive devices and reducing system costs. The ZigBee module also uses Freescale's MCl3192.

  The Bluetooth module mainly implements the protocols below the Bluetooth HCI layer and provides an air interface that complies with the Bluetooth specification. In this design, the Blue-Core2-Flash RF PnG (8M) Bluetooth single-chip solution is used, which integrates the RF and baseband chips. Its UART (can be two-wire: RXD, TXD; four-wire: RXD, TXD, RTS, CTS; eight-wire: full RS232 mode) connects the data port for data transmission.

  3 Wearable network software architecture based on Bluetooth and ZigBee technology

  In the designed wearable network, the software part is mainly concentrated on the gateway and ZigBee nodes. The main function of the gateway is to manage and process the data transmitted by the ZigBee nodes. It mainly deals with two problems: packet processing and address processing.

  (1) Packet processing is to send the message from the application of one network device to another network device. The protocol conversion function unit (i.e., management layer) in the gateway needs to disassemble and encapsulate the message. The gateway disassembles and assembles the packet data received from the transmitting device, removes the data header and tail, extracts the useful data information from the packet, and then encapsulates the useful information into the packet format required by the receiving device protocol, and sends the data to the receiving device according to the destination address and interface. The conversion process between Bluetooth and ZigBee packet formats is: the gateway receives the ZigBee/Bluetooth packet from the ZigBee/Bluetooth device through the radio frequency unit, disassembles and assembles it, removes the packet header and packet tail, extracts the data net load, and then encapsulates it according to the Bluetooth/ZigBee packet format, adds the packet header and packet tail, and sends it to the Bluetooth/ZigBee device through the radio frequency.

  (2) Address processing. Each Bluetooth device or ZigBee device that establishes a connection with the gateway will be bound to a port in the gateway (through dynamic or static allocation). In this way, the Bluetooth device or ZigBee device can be uniquely identified by the gateway's address and port number. When a Bluetooth device exchanges information with a ZigBee device, the gateway is responsible for the conversion between the Bluetooth communication protocol and the ZigBee protocol, so that the Bluetooth device and the ZigBee device can exchange data transparently. Address mapping can use two methods: static or dynamic mapping. Static mapping is to create a table that associates a logical address with a physical address, and the table is stored on each device. Whenever the physical address changes, the table must be updated, which is cumbersome. Dynamic mapping is when a device knows one of the logical address or physical address, it can use a protocol to find the other address. Two protocols for dynamic mapping are usually used to resolve addresses.

  Considering the characteristics of wearable network, the embedded Linux operating system is adopted, and users can easily develop their own applications based on it.

  The software on the ZigBee node is mainly developed using C language, and its function is to receive data from the sensor unit and send the data to the Bluetooth/Zig Bee gateway.

  At present, the structural design of the wearable network and the selection of wireless transmission technology have been completed, and the design and programming of the Bluetooth/ZigBee gateway are in progress. The next step will be to integrate wireless terminals in the wearable network and analyze and improve the performance of the wearable network under various sports conditions.