ZigBee is a low data rate wireless personal area networks (LR-WPAN) which is used for a short distance communication system. Therefore, it is a promising technology due to its low cost, low power consumption, and long battery life  . The application areas of ZigBee are home automation, smart energy, military purposes, internet of things (IoT), and health monitoring. Its application areas in IoT are growing up and getting attention. Zigbee is deployed to IEEE 802.15.4 standard which defines the physical layer and MAC layer. Three kinds of frequency bands that Zigbee can be operated at which are 868 MHz band used in America, 915 MHz band used in Europe, and 2.4 GHz unlicensed spectrum which is used anywhere around the world   . The physical and medium access control layers are defined by IEEE 802.15.4 standard whereas the network and application layers are defined by Zigbee alliance. So, ZigBee deals with the both IEEE 802.15.4 layers 1 and 2  . ZigBee is reliable and robust making all communicating devices controlled by a single unit (coordinator) and make each device connect with each other directly or indirectly   . There are two types of modulation under the original IEEE 808.15.4/Zigbee standard. The first one is the OQPSK (Offset Quadrature Phase Shift Keying) which is employed in 2.4 GHz band. The other type is the BPSK (Binary Phase Shift Keying) which is employed in both 868/915 MHz bands. Zigbee 2.49-GHz has higher data rate and number of channels than Zigbee 868/915-MHz. However, Zigbee 868/915-MHz shows superiority of the cost and signal penetration. The original IEEE 808.15.4/Zigbee specifications use DSSS (Direct Sequence Spread Spectrum) as spreading spectrum technique to send the baseband signal at lower data rate than the channel data rate to make some improvements in the receiver side by making every bit spread as 15 chips   . This Research concentrates only on BPSK as a modulation technique for ZigBee.
Kalman Filter is named after Rudolf Kalman in 1960 and it is a linear quadrature estimation used in system tracking, control, and communication systems. The Kalman Filter is used to predict and update the states of the filter; therefore, with a prior knowledge of the state dynamics behavior, Kalman can estimate the next state of the filter and correct the estimate  .
The Costas PLL, which is a modified version of Phase Locked Loop (PLL), is a useful technique in both analog and digital communications systems. It can be used as a demodulator for BPSK to recover the transmitted data from the BPSK modulated signal  . Therefore, it tracks the undesired phase deviation of the carrier caused by a noisy channel in order to bring this deviation to or close to zero  . Some studies such as in  uses Kalman Filter as Phase Locked Loop (PLL) to track the phase changes in Global Positioning System (GPS) carrier phase to minimize the phase error which has a negative impact on determining the attitude error. The findings of this study illustrated that Kalman Filter tracks correctly the GPS carrier phase in the presence and absence of the multipath interference. Also, previous studies have shown that Kalman Filtering is applied to track the phase changes in the modulated signals and its performance was phenomenal. Ali and Zohdy  proposed an Interactive Kalman Filtering to track the phase of the modulated signal in Bluetooth systems with DQPSK and GFSK modulation in the presence of Gaussian noise. Their results showed a significant improvement in the signals compared to the unfiltered signals. However, a number of questions regarding  remain to be addressed.
The authors in   fill the literature gap in  by tracking the phase of GFSK modulated signals with taking into a consideration frequency hopping, 802.11 interference, and Non-Gaussian Impulsive noise. In addition to that, they investigated the impact of varying process and measurement noise into the performance of Kalman Filter; therefore, Kalman Filter performs well with respect to the interference and Non-Gaussian noise. The paper in  proposed a new GFSK demodulation in Bluetooth receivers by using Kalman Filter to track the instantaneous change in the phase estimate to decode the transmitted data. Their proposed receiver outperforms the conventional differential demodulator and showed improvement in the bit error rate (BER).
The objective of this paper is to track BPSK modulated signal phase by discrete Kalman Filter in ZigBee receivers in the presence of Additive White Gaussian Noise (AWGN) channel. This paper has been organized as follows. Introduction is described in the Section 1. Section 2 describes the BPSK. Section 3 presents the AWGN channel. Section 4 illustrates the discrete Kalman Filter estimator. Section 5 shows the simulation and results. Section 6 presents the conclusion of our work.
2. BPSK Signal Representation
ZigBee operated in the frequency band 868/950 MHz employs Binary Phase Shift Keying (BPSK) modulation technique for pulse shaping. For frequency range 868/950 MHz, ZigBee data rate is 20 Kb/sec and DSSS is its spreading method. ZigBee baseband chip is described by the raised cosine pulse shape with a roll-off factor = 1. Therefore, the cosine pulse shape g(t) is described by  :
The following shows the derivation of BPSK modulated signal starting from the phase-shift keying (PSK) modulation with M signal waveforms having an equal energy   :
is the signal pulse shape;
is the carrier frequency.
In BPSK there are two possible phases; so, and .
By substituting the values of M and m in (2) and (1) respectively:
, for binary 1;
, for binary 0.
Finally, BPSK can be represented with the two different possible phases as  :
for binary 1;
for binary 0.
In general, BPSK signal is represented by  :
is the phase change of BPSK signal;
is the bit duration;
is the amplitude of the carrier.
Obviously, the BPSK modulated signal has no Quadrature component, it has only In-phase component.
3. AWGN Channel Model
Figure 1 shows the Additive White Gaussian Noise (AWGN) model which is used to generate a white Gaussian noise to the BPSK transmitted signal and it is described mathematically by the following  :
where represents the received signal from BPSK modulated signal plus which is a waveform containing the white Gaussian noise. The white Gaussian has a zero mean and spectral density of  .
4. Discrete Kalman Filter Estimator
In this paper, Kalman Filter is used to track the phase changes in the BPSK modulated signal in Equation (3) and the following derivation is given by  :
The system in (4) is continuous and it should be discretized which was done in  by taking the first order approximation as follows:
Figure 1. Additive White Gaussian Noise (AWGN) Channel.
k is a time step;
∆t is the sampling time.
The discrete state space transition model for estimating the phase change of the BPSK signal is defined as   :
x(k) represents the state vector of BPSK modulated signal at time step k;
F represents the state transition matrix;
y(k) BPSK signal’s phase at time step k;
H observation matrix;
v(k) measurement noise vector at time step k;
w(k) process noise vector at time step k.
The process and measurement noise have zero mean and they both are uncorrelated as done in  and their covariances R(k) & Q(k) are given by:
Kalman Filter Algorithm
The Kalman Filter is used to predict and update the states of the filter; therefore, it can predict which phase change has occurred. It starts with some initial estimate and some initial update error covariance matrix . After that, Kalman gain G is applied to correct the prediction. The error terms proposed in  are then applied to update the estimate of the phase with and without deviation. This process (prediction and update) is applied at each time step k reclusively  .
The following describes the computation process which was done in  as follows:
1) Making some initializations for &
2) Computing Kalman gain G with respect to a priori process covariance :
3) Calculating a posteriori covariance which expresses the update covariance of the process in terms of a priori covariance and Kalman gain G:
4) Calculating the Predicted Process Covariance:
Note: will be a previous estimate for next time step k.
5) By taking the measurement , we can define the current estimate as:
where the previous estimate can be defined as:
6) Updating the estimate of the phase is done by choosing the minimum error value between the two error equations as follows:
5. Simulation and Results
ZigBee transmission model has been designed by MATLAB for the simulation in order to show the performance of Kalman filter in tracking the phase of BPSK modulated signal in ZigBee receivers under AWGN channel. Figure 2 below shows the ZigBee transmission model with the integrated Kalman Filter  . ZigBee operated in the frequency band 868/950 MHz employs Binary Phase Shift Keying (BPSK) modulation technique. The BPSK differentially encodes the binary data. Each bit is spread to a 15-chip sequence (DSSS). Then, the chip sequences are BPSK modulated and passed to a normal raised cosine filter for pulse shaping; then, it is sent through AWGN channel. Kalman Filter is used to quickly track the phase of the BPSK transmitted signal.
Figure 3 illustartes that Kalman Filter has correctly tracked the phase chagnes in the ZigBee receiver in the precense of AWGN channel compared to the noisy trasnmitted phase (unfiltered).
Figure 4 shows the performance of the intergraed Kalman Filter. The performance of tracking is measured by Mean Square Error (MSE) with respect to Signal to Noise Ratio (SNR). Kalman has shown to work best for the ZigBee in terms of phase tracking due to its minimum MSE.
Figure 2. ZigBee Transmission Model with Integrated Kalman Filter.
Figure 3. Kalman filter phase tracking.
Figure 4. Mean Square Error (MSE) with respect to SNR.
We successfully implemented a discrete Kalman Filter to track the phase changes in the BPSK in ZigBee communication systems in the presence of AWGN channel. The ZigBee transmission model was designed based on IEEE 802.15.4 standard. Kalman showed superiority of the tracking with respect to different SNR values. The findings of our study were attractive to extend the work to make a decision on the bit received and apply Kalman to different modulations schemes.
 Gorantla, K. and Mani, V.V. (2015) Simulink Model for Zigbee Transceiver Using OQPSK Modulation under Fading Channels. 2015 International Conference on Communications and Signal Processing (ICCSP), Melmaruvathur, 2-4 April 2015, 1-3.
 Wang, C.-C., Huang, C.-C., Huang, J.-M., Chang, C.-Y. and Li, C.-P. (n.d.) ZigBee 868/915-MHz Modulator/Demodulator for Wireless Personal Area Network.
 Frenzel, L. (2018) What’s the Difference between IEEE 802.15.4 and ZigBee Wireless?
 About Us (2018)
 Shamla, B. and Devi, K.G. (2012) Design and Implementation of Costas Loop for BPSK Demodulator. 2012 Annual IEEE India Conference (INDICON), Kochi, 7-9 December 2012, 33.
 Ali, M.N. and Zohdy, M.A. (2012) Interactive Kalman Filtering for Differential and Gaussian Frequency Shift Keying Modulation with Application in Bluetooth. Journal of Signal and Information Processing, 3, 63-76.
 Nsour, A., Abdallah, A. and Zohdy, M. (2013) An Investigation into Using Kalman Filtering for Phase Estimation in Bluetooth Receivers for Gaussian and Non-Gaussian Noise. IEEE International Conference on Electro-Information Technology, EIT 2013, Rapid City, 9-11 May 2013, 1-5.
 Nsour, A., Abdallah, A. and Zohdy, M. (2014) Non-Coherent Detection of GFSK Using Extended Kalman Filtering for Non-Gaussian Noise. 2014 Wireless Telecommunications Symposium, Washington DC, 9-11 April 2014, 1-6.
 Rhudy, M.B., Salguero, R.A. and Holappa, K. (2017) A Kalman Filtering Tutorial for Undergraduate Students. International Journal of Computer Science & Engineering Survey, 8, 1-18.