## 1 Introduction  
The main objective of deployment of sensors in Wireless Sensor Networks (WSNs) is to monitor the environmental conditions such as pressure, temperature, sound, etc. The physical layer and medium access control of IEEE 802.15.4-enabled [1] WSN is suitable for the low-power wireless networks. The Internet of Things (IoT), where ZigBee devices play a major role, is getting popular in smart homes and smart city applications. The existing IEEE 802.15.4 MAC scheme has been modified to meet the critical requirements of IoT applications and both the slotted and unslotted medium access control schemes for the short-range communication devices with low duty cycle have been defined in the newly-modified IEEE 802.15.4e [2] standard. The superframe structure follows the slotted MAC of the IEEE 802.15.4e and is suitable for different applications in the Internet of Things (IoT). ZigBee technology is suitable for home and industrial automation, remote control applications and provides connectivity to different sensor devices, which can provide long battery life. On the other hand, WiFi technology gives connectivity to the IoT devices more conveniently. In different applications of IoT, such as smart home, healthcare, smart industry, smart city and smart community, both WiFi and ZigBee devices are used and operated in the 2.4-GHz ISM band, which may cause interference. The conventional MAC protocols are useless in managing the disparate transmit-power levels, asynchronous time slots and incompatible PHY layers of such heterogeneous networks and needs to be improved to cope with the existing technological demands. The star topology is preferable for IoT applications, where the coverage vicinity is small and low latency is needed. The coordinator in the star topology controls the communication by sending packets and beacons for the synchronization among devices. All devices are allowed to communicate with the PAN coordinator only after successfully association with the coordinator. However, the communications are affected due to collisions or interference with respect to the packet arrival rate of the devices. Mostly, the network collision occurs due to simultaneous channel assessment or the hidden terminal problem. Besides, interference occurs due to the presence of both WiFi and ZigBee devices when their channels overlap. The novelty of the CSMA/CA mechanism is to avoid the collision during the ongoing transmission of another device in the network, which is not hidden. However, ZigBee's Rx/Tx switching duration is 192 \(\upmu\)s, and the DIFS (Distributed Inter-Frame Space) of WiFi is only 50 \(\upmu\)s. Hence, in between ZigBee's Rx/Tx switching duration, a WiFi transmitter can easily preempt the channel access. The coexistence of these wireless devices in a network increases the interferences, collisions, delay and energy consumptions. Moreover, ZigBee packet losses and retransmissions lead to lower reliability and faster draining of the ZigBee battery. Therefore, these issues are significant in the smart home network, where both WiFi and ZigBee devices coexist. Sensor devices in WSNs follow the IEEE 802.15.4e MAC scheme during the Contention Access Period (CAP), performing slotted CSMA/CA to access the channel to reduce the collisions. The sensor devices have buffer constraints, and the data packet is dropped when the buffer is full. Hence, the devices having more data in the buffer should get priority to access the channel so that the packet drop rate can be minimized. However, the IEEE 802.15.4e CSMA/CA mechanism provides equal priority to all devices and does not consider the buffer limitation of the devices, which might lead to buffer overflow. The collision rate in WSNs increases with respect to the number of contending devices due to the limited backoff window size. During the Contention-Free Period (CFP), sensors transmit data directly to the coordinator.