Introduction

Wireless body area networks (WBANs) involve specific monitoring applications such as health care, rehabilitation, and sports. All sensor nodes are located around the human body with wireless communications. They all require low energy consumption for wireless devices and high performance for data transmission [1]. Data have been measured for WBANs for both electrical signals such as electromyography (EMG), electrocardiography (ECG), etc. and vital signs, for example, temperature, blood pressure, heart rate, and so on [2].

The wireless communication for WBANs generally uses the standard MAC protocol [3,4,5] which is the carrier sense multiple access with collision avoidance (or CSMA/CA) protocol, to access the medium for data transmission. There are some protocols, such as the T-MAC [6] and the X-MAC [7, 8] which operate the CSMA/CA for WBANs. When the system demands enhanced network efficiency for data transmission, it utilizes the time-division multiple access (or TDMA) protocol to perfectly distribute the bandwidth. The network applies only the TDMA such as the low duty-cycle TDMA (LD-TDMA) [9] and the CF-MAC [10]. However, it has also been found that there are employing both the TDMA and the CSMA/CA techniques to extend the network capability, such as the hybrid context-aware MAC protocol (CA-MAC) [11], the all dynamic MAC (AD-MAC) protocol [12], and the Hybrid MAC (HyMAC) protocol [13]. Furthermore, there are others using FDMA-based or slotted protocols to access the transmission medium, for example, the cooperative MAC [14], the HUA-MAC [15], and the ECTP-MAC [16].

The T-MAC protocol [6] is studied in simulation in OMNeT++ and actually implemented in EYES devices at 868.35 MHz with four nodes. It modifies the active time in different cycles for each node to be used flexibly. When a node wants to transmit data, a message is broadcast to every node in the network to avoid a data collision. Whereas the X-MAC [7] is operated in nine sensor nodes with the Chipcon CC2420, 2.4 GHz. It has been developed using the principles of duty-cycled WSNs. A node wakes up to examine the channel for a short time using the operation of low power listening. This makes more efficient energy consumption because of selecting the optimal sleep and listening intervals. For the AD-MAC protocol [12], a communication manager is introduced to divide the sensor node priority into three levels. Here, the highest priority is level 0 and the lowest priority is level 2, where the contention window is used as a priority divider. Note that the AD-MAC is evaluated its performance through the OMNeT++ simulator, where the performances of time delay distribution, energy consumption, and packet loss rate are taken into consideration. Additionally, in the simulation, different transmitted packet rates are assigned to each node based on the data communication demand, diversely. Finally, in the HyMAC protocol [13], the star communication topology is configured for body sensor nodes deployed in the network (i.e., nine sensor nodes), and the personal station is also assigned to enforce and gather data reported by all body sensor nodes. Note that, in [13], to support the Internet of Things (IoT) system, the body sensor nodes can automatically access and analyze data in the network. Additionally, the HyMAC is designed and tested on the NS-3.26 simulator as the simulation study. For the work in [17], ECG data, as the sensing data in wireless networks, are divided into different priorities, including low, medium, and high priorities, respectively. Here, unnecessary data to be frequently detected, like heartbeat data, are assigned as a low frequency with the defined sampling rate and packet size.

In this work, the experimentation of WBAN communications in various scenarios is focused. The CSMA/CA is used as the standard and fundamental MAC protocol for wireless network communications. TelosB sensor nodes based on the IEEE 802.15.4 standard are applied for the real implementation [18]. The major contribution of our work is that the WBAN communication reliability in terms of the packet delivery ratio with respect to the packet inter-arrival time, the packet size, and the number of nodes in the network is studied, and such considered factors are varied dynamically. Furthermore, environmental factors, including human movement effects, indoor and outdoor environments, and transmitter and receiver positions deployed in the network, have also been considered in this evaluation. These are in line with the WBAN requirements for either patients in healthcare applications or athletes in physical fitness monitoring [19,20,21,22].

The structure of this paper is organized as follows. Materials and methods, including the proposed wireless body area network system and experiments, are provided in “Methods” section. “Results and discussion” section presents results and discussion. Finally, the paper is concluded in “Conclusions” section.

Methods

Proposed wireless body area network system

Wireless device and network architecture

WBANs support several real-time health monitoring applications. The IEEE 802.15.6 standard for WBANs aims to provide a standard for low power consumption, short range communication, and reliable wireless communication within areas of the human body. The typical data rate for the WBAN standard is in the range of 10 kbps to 10 Mbps [22, 23]. In particular, the ECG signal of WBAN applications requires a data rate of 6 kbps at a frequency of 500 Hz [23]. Whereas the real-world implementation uses the IEEE 802.15.4 standard to study the characteristics of WBANs. This standard also aims to provide low-data rate wireless personal area networks (WPANs) with low power requirements. The effective data rate for this network is in the range of 80–250 kbps. The standard has the ability to operate the CSMA/CA access modes. These techniques have been studied on the actual hardware of WSNs.

In our proposed system, data from sensor nodes are sent to a base station. Then, the base station forwards the data to the computer via a serial port for collection. Here, sensor nodes are attached to the human body, while the base station connects to the laptop via serial communication using the 115,200 bps baud rate. All of them are implemented on TelosB wireless sensor motes running the TinyOS v2.1.2 operating system [18]. The processor uses the MCU TI MSP430F1611, 10 Kb of RAM and the RF module with the CC2420 (i.e., frequency band 2.4–2.485 GHz based on the IEEE 802.15.4 standard). As shown in Fig. 1, the experiment has been conducted to study the network performance for WBAN communications from many sensor nodes. A single-hop network has been built by placing three TelosB motes around the TelosB base station. The base station broadcasts the Command message to start the node’s transmission altogether in the network only for the first time. This message has also been used for setting up an important parameter. As the base station receives the data message once the experiment starts. The transmission power has been set at the maximum level of 0 dB to ensure every packet is able to be received by the base station. Whereas the received sensitivity of the TelosB mote is approximately ± 0.01%.

Fig. 1
figure 1

WBAN architecture

As mentioned above, in this work, TelosB motes were used in the implemented WBAN, where the RF module with the CC2420 from Texas Instruments was employed. The CC2420 was designed for low-cost, low-power wireless applications. It required low current consumption in each communication mode. Note that in WBAN applications, the sensor node is attached to the human body to monitor physiological signals. Thus, energy saving to prolong network lifetime is required.

Compared with other RF transceivers, the CC2420 requires low current consumption; 17.4 mA for the Tx mode (at 0 dBm) and 18.8 mA for the Rx mode. It requires only 8.5 mA for the TX mode at − 25 dBm, and 0.426 mA in the idle mode. For this reason, many existing works also used the CC2420 to develop WBAN systems. Another reason is that in the TelosB node, the CSMA/CA protocol to access the medium for data transmission has been available for study, modification, and development.

Packet structure and communication sequence

In this paper, packet structure has been designed into two types of packets which are called command_msg_t and report_msg_t. The radio message used TinyOS’s standard, 9-byte data for the command packet and 8-byte data for the data packet as demonstrated in Fig. 2. The first packet is a message that is sent from the base station to all sensor nodes in the network to initiate and control the data transmission. The parameters in the packet for sending consist of Nodestart, Numberpacket, Interarrivaltime, and Payloadsize for 1, 4, 2, and 2 bytes, respectively. These parameters are the data payload for the command packet, as seen in Fig. 2a. Whereas the second packet is the message which is sent from the node to the base station and then forwarded to the computer via serial port. This message consists of 4 bytes of payload1 and 4 bytes of payload2 for the data packet, as illustrated in Fig. 2b.

Fig. 2
figure 2

The packet format for the proposed system

The node operation when the CC2420 communication chip is enabled in all test cases is shown in Fig. 3. It is started by the command message to enable the CC2420 Chipcon and the node waits for the signal from the base station. Then the node takes the variable values (Interarrivaltime and Payloadsize) that are sent from command_msg_t to store in variables which are created by the node. After the nodes receive the command packet, they setup the system based on the obtained variables and begin to transmit the data simultaneously. When the node starts to add data, the data packet, which consists of a counter in payload1, is collected for every cycle from packet transmission and also a timestamp from the local time in a payload2 variable. Whenever the channel is available, the node will generate a report_msg_t with the created values for payload1 and payload2 and then send it to the base station for evaluation and analysis of network performance.

Fig. 3
figure 3

Flowchart of WBAN communications

In the system, the transmission efficiency has been studied when the network changes the communication parameters. The important parameters include the packet size, the packet inter-arrival time, and the number of nodes in a system. This experiment also tests the communication performance when changing test environments, such as all the systems being placed indoors and outdoors, the base station’s position inside or outside of the room to study the wireless communication when patients move in an area of a hospital.

Experiments

To evaluate the proposed WBAN system in terms of dynamic capabilities, a set of experiments with several WBAN scenarios is performed. The effects of packet inter-arrival times, packet sizes, the number of nodes, human movements, indoor and outdoor environments, and transmitter and receiver positions are considered. Details of all test cases, parameter setups, and performance metrics are described below.

Test cases and parameter setups

There are five different test cases to be evaluated. These cases are able to present all possible WBAN communications in a place. All related parameters set for the experiments are also illustrated in Table 1.

Table 1 Parameters set for each test case

Test case #1: one transmitter node and one receiver node (i.e., the base station) are attached to the human body; a man with a body width of 26 cm, a shoulder size of 52 cm, a height of 169 cm, and a weight of 110 kg. During the test, the man stands in the room (i.e., the indoor environment), as demonstrated in Fig. 4. The transmitter node (i.e., node 1) continuously sends data to the receiver node, where the packet sizes are varied from 10 to 36 bytes, and the packet inter-arrival times are varied from 5 to 20 ms. Note that each test is repeated 10 times for data collection and performance evaluation. For this test case, the effects of the packet sizes and the packet inter-arrival times on the WBAN communication reliability will be investigated.

Fig. 4
figure 4

Test case #1

Test case #2: more sensor nodes are added to the network; one to three nodes for data transmission, as shown in Fig. 5. This scenario refers to the case where more sensor nodes are applied in the WBAN to collect and report different sensory data to the base station, like ECG, EMG, heart rate, blood pressure, etc. During the test, the man stands in the room, and all transmitters send 1000 packets as the data to the base station at the same time, with the packet size of 16 bytes (i.e., the middle value of the test case #1). However, like in the test case #1, the packet inter-arrival times are also varied from 5 to 20 ms to study the effects of the packet inter-arrival times and the number of nodes on the WBAN communication reliability.

Fig. 5
figure 5

Test case #2, changing the number of nodes from 1 to 3; a one transmitter node, b two transmitter nodes, and c three transmitter nodes

Test case #3: three transmitter nodes are used for data transmission, and all transmitters send their data to the base station at the same time, with a 16 bytes packet size and the packet inter-arrival times of 5 ms, 10 ms, and 18 ms (the middle values of the test case #2), respectively. Note that the base station is placed on the table. In this case, there are two subcases depend on the surrounding environment: (a) the man stands in the room, and (b) the man stands on the ground (i.e., the outdoor environment), as demonstrated in Fig. 6. For this purpose, the effects of the packet inter-arrival times, the number of nodes, and indoor and outdoor environments on the WBAN communication reliability will be investigated.

Fig. 6
figure 6

Test case #3, changing the environments; a the man stands in the room, b the man stands on the ground outside the building, and c room, building, and outdoor environments

Test case #4: three transmitter nodes are used for data transmission, and all transmitters send their data to the base station at the same time, with a 16 bytes packet size and packet inter-arrival times of 5 ms, 10 ms, and 18 ms, respectively. In this case, there are two subcases: a) the man walks in a straight line in the room with a walking distance of 5 m, and (b) the man walks in a straight line in the outdoor environment with the same walking distance, as shown in Fig. 7. For this purpose, the effects of the packet inter-arrival times, the number of nodes, indoor and outdoor environments, and human movements on the WBAN communication reliability will be investigated.

Fig. 7
figure 7

Test case #4, a moving person; a the man walks in a straight line in the room, and b the man walks in a straight line in the outdoor environment

Test case #5: three transmitter nodes are used for data transmission, and all transmitters send their data to the base station at the same time, with a 16 bytes packet size and packet inter-arrival times of 10 ms (i.e., the middle value of test cases #3 and #4). In this case, there are three subcases, as shown in Fig. 8. The man walks in the building (i.e., at the Department of Electrical Engineering, Faculty of Engineering, Prince of Songkla University, Thailand), where the transmitters and the base station (placed in the room) in the first subcase are at the same level from the ground (i.e., 1-m height), while in the second and the third subcases, the base station is at the altitudes of 1-m high and 2.5-m height from the ground outside the room, respectively. Note that the walking pattern of the man is also shown in Fig. 9. Thus, for this purpose, the effects of the number of nodes, building environments, human movements, and transmitter and receiver positions on the WBAN communication reliability are taken into consideration.

Fig. 8
figure 8

Test case #5, changing the receiver’s positions; a the man walks in the building, b the base station is at the altitude of 1-m height from the ground, c the base station is at the altitude of 1-m height from the ground outside the room, and d the base station is at the altitude of 2.5-m height from the ground outside the room

Fig. 9
figure 9

The walking direction for the test case #5

Performance metrics

The packet delivery ratio (PDR) is selected and used as the performance metric for the evaluation of WBAN communication reliability. The PDR is the ratio of the number of received packets at the base station to the number of transmitted packets from the transmitter, as shown in Eq. (1). This metric is chosen because it can indicate the success rate of data transmission performed by all network nodes. This is in line with WBAN requirements, since the sensor nodes for measuring human physiological signals have several data transmission needs. In this work, the 95% confidence interval (i.e., 95% CI) is also given for the average result.

$$Packet\ Delivery\ Ratio\ (PDR)=\frac{Number\ of\ received\ packets}{Number\ of\ transmitted\ packets} \times 100\%$$
(1)

Results and discussion

The experimental results and discussion are presented in this section. For the test case #1, as shown in Fig. 10, the results indicated by the PDR show that changing packet sizes and packet inter-arrival times significantly affects the WBAN communication reliability. It can be observed that, as packet sizes increase, the PDR then decreases. Whereas, increasing of packet inter-arrival times, the PDR increases. At 10 bytes of the packet size and 5 ms of the packet inter-arrival time, the PDR is 50.31%. When the packet size is configured to 36 bytes, the PDR decreases by almost 10% (i.e., 41.08%). Thus, increasing the packet sizes causes the PDR decrease. At the same point, compared with the cases of 10 bytes of the packet size and 13 ms of the packet inter-arrival time, the PDR result increases to 99.03%. Consequently, increasing the packet inter-arrival times to 15, 18, and 20 ms, the PDRs are then 100%, 99.84%, and 99.99%, respectively. The results in this case can be explained that, in communications with larger packet sizes and shorter packet inter-arrival times (i.e., a high flow rate), both the transmitter and receiver have to process a large amount of data in a short period of time. Since the receiver cannot appropriately process and handle such a congested situation, it results in failure of transmission and packet loss.

Fig. 10
figure 10

The PDR for the test case #1; varying the packet size and the packet inter-arrival time

By these experimental results, it has been shown that, for one transmitter and one receiver communication, the packet inter-arrival time bigger than 13 ms will not influence the PDR results, where the communication reliability can achieve 100%, approximately.

The PDR results for the test case #2 are provided in Fig. 11. The results indicate that increasing the number of nodes and the packet inter-arrival time can significantly affect the PDR. Here, increasing of the number of nodes, the PDR then decreases, while increasing of packet inter-arrival times, the PDR increases. At 5 ms of the packet inter-arrival time and 16 bytes of the packet size, the PDRs are 47.76%, 43.41%, and 38.69% for one, two, and three transmitter nodes, respectively. The results here illustrated that, in communications with more transmitter nodes and small packet inter-arrival times or a high flow rate, one receiver cannot process data, resulting in collisions of data transmission and packet loss.

Fig. 11
figure 11

The PDR for the test case #2; varying number of nodes and the packet inter-arrival time

The experimental results in Fig. 11 also demonstrate that the PDR of more than 80% corresponds to 13 ms of the packet inter-arrival time or higher. As seen in the graph, at 13 ms of the packet inter-arrival time, the PDR results for one transmitter to three transmitter nodes are 99.53%, 93.13%, and 86.41%, respectively. At 15 ms of the packet inter-arrival time, the PDRs then equal to 99.45%, 97.89%, and 92.76%, respectively. At 18 ms of the packet inter-arrival time, the PDRs are 99.92%, 98.81%, and 95.26%, respectively. Finally, at 20 ms of the packet inter-arrival time, the PDRs reach 99.95%, 99.11%, and 96.94%, respectively.

The PDR results for the test case #3 (i.e., the man stands in the room and on the ground outside the building) and the test case # 4 (i.e., the man walks in a straight line in the room and outside the building, with a walking distance of 5 m), when three transmitter nodes are used and the packet-inter-arrival time is varied, are illustrated in Figs. 12 and 13, respectively. The experimental results here indicate that the PDR results are not different for the cases of the man standing and walking in the indoor and outdoor environments with a short walking distance (5 m). For example, at 10 ms of the packet inter-arrival time, the PDRs are 64.45% (standing in the indoor), 64.57% (walking in the indoor), 64.30% (standing in the outdoor), and 63.64% (walking in the outdoor), respectively. Note that only the packet inter-arrival time factor significantly influences the PDR results, as demonstrated by the previous results of the test cases #1 and #2.

Fig. 12
figure 12

The PDR for the test cases #3 and #4 for three transmitter nodes; varying the packet inter-arrival times

Fig. 13
figure 13

The PDR for each transmitter node for the test cases #3 and #4. a The packet inter-arrival time of 5 ms. b The packet inter-arrival time of 10 ms. c The packet inter-arrival time of 18 ms

The PDR results for each transmitter node when varying the packet inter-arrival times for the test cases #3 and #4 are also illustrated in Fig. 13a–c. These results represent the PDR variation, and the results indicate that the PDRs of all nodes are not much different. For example, at 10 ms of the packet inter-arrival time as in Fig. 13b, the PDRs of the node 1 are 62.51% (standing in the indoor), 65.48% (walking in the indoor), 65.63% (standing in the outdoor), and 64.78% (walking in the outdoor), respectively. Compared with the cases of node 2 and node 3, they are (63.30%, 64.11%, 63.48%, and 64.03%) and (67.32%, 64.10%, 63.72%, and 62.03%), respectively. Since all nodes in this work use the CSMA/CA protocol as the standard MAC protocol for channel access, all nodes then have the same priority for data transmission and PDR balance.

Note that based on the results in Fig. 13c, the results indicate that when three transmitter nodes with a 16 byte packet size are used for the case of the man who stands and walks a short distance in the room and outside the building, using the packet inter-arrival time of 18 ms can help to achieve the PDR of more than 85%.

In the test case #5, the PDR results (averaged from three nodes) when the base station is at an altitude of 1-m height from the ground in the room, at the altitude of 1-m height from the ground outside the room, and at the altitude of 2.5-m height from the ground outside the room are compared and illustrated in Fig. 14. Here, the average PDRs are 30.12%, 39.62%, and 37.14%, respectively. The results here suggest that, to appropriately apply the WBAN for the case of the man walking in the big building as shown in Figs. 8 and 9, the base station node should be placed outside the room, since higher PDR results can be obtained. However, in our test scenario, the PDRs from the cases of the base station placed outside the room is at an altitude of 1-m height and 2.5-m above ground level are not much different.

Fig. 14
figure 14

The PDR for the test case #5

The PDR results versus time index (by plotting every 1000 ms) are also provided in Fig. 15. These results demonstrate that the PDRs can vary from 0 to 80%, approximately. Here, the PDR decreases drastically when the man walks through the corner or there is no line of sight (LoS) communications between the transmitter nodes and the receiver node, as indicated by the walking direction in Fig. 9.

Fig. 15
figure 15

The PDR versus time index for the test case #5. a The base station is at an altitude of 1 m above the ground in the room. b The base station is at an altitude of 1 m above the ground outside the room. c The base station is at an altitude of 2.5 m above the ground outside the room

By our experimental results obtained from the test cases #1 to #5, how packet inter-arrival times, packet sizes, the number of nodes, human movements, indoor and outdoor environments, and transmitter and receiver positions affect the WBAN communication reliability can be evaluated. Our findings are summarized here.

  • In the test case #1: increasing the packet sizes, the PDR then decreases, while increasing the packet inter-arrival times, the PDR increases. For one transmitter and one receiver communication, when the packet size is 10 bytes (i.e., the minimum packet size to be tested) and the packet inter-arrival time is greater than 13 ms, the PDR reaches 100%, approximately.

  • In the test case #2: increasing the number of nodes (one to three transmitter nodes), the PDR then decreases. However, at three transmitter nodes (i.e., maximum number of transmitters), increasing the packet inter-arrival times from 13 to 20 ms, the PDR results are greater than 86%, approximately (i.e., 86.41 to 96.94%).

  • In the test cases #3 and #4: the PDR results are not different for the cases of the man standing and walking in the indoor and outdoor environments with a short walking distance (5 m). Also, since all nodes in this work use the CSMA/CA protocol for medium access, all nodes then have the same priority for data transmission and PDR balance. Additionally, the results indicate that when three transmitter nodes with a 16-byte packet size are used for the cases of the man standing and walking a short distance in the room and outside the building, using 18 ms of the packet inter-arrival time or the sampling rate of approximately 55 samples/second can help to achieve the PDR higher than 86%, approximately.

  • Finally, in the test case #5, to appropriately apply the WBAN for the case of the man walking in the big building, the base station should be placed outside the room, since higher PDR results can be achieved. The PDR more decreases when the man walks through the corner or there is no LoS communication. Also, the PDR results from the cases of the base station is at the altitudes of 1-m height and 2.5-m height from the ground level and placed outside the room are not much different.

Comparisons of experimental settings and results between this work and WBAN systems from the literature are also summarized in Table 2. By our research methodology and experiments, researchers and users can consider the optimal point for WBAN setting and configuration to achieve the communication reliability requirement.

Table 2 Comparisons of experimental settings and results between this work and WBAN systems from the literature

In future work, an appropriate WBAN communication protocol in the MAC layer will be designed and developed to achieve network efficiency from both a simulation and an experimentation point of view, where the effects of the packet inter-arrival times, the packet sizes, and the number of nodes will be taken into consideration. More performance metrics related to WBAN communication reliability will be employed for evaluation. Additionally, a proposed solution that focuses on network performance as well as energy efficiency will be implemented. Finally, radio propagation models with path loss coefficients measured in WBAN environments will be considered.

Conclusions

This paper studied the standard multiple access mode and validated it experimentally based on TinyOS TelosB wireless nodes. This scheme has been implemented on real hardware with respect to WBAN characteristics. The experimental results demonstrate the effects of the packet inter-arrival times, the packet sizes, the number of nodes in the network, human movements, indoor and outdoor environments, and transmitter and receiver positions on the WBAN communication reliability in terms of the packet delivery ratio. The success rate obtains over 90% when setting up the appropriate limiting factors for data transmission. Our approach can help to setup the fundamental parameters in the CSMA/CA for WBANs applications without requiring a new developed protocol and enhance higher throughput for data communication by avoiding retransmission and data collisions in the network.