Abstract:For the problem that WSN needs a suitable application layer communication protocol, this paper analyzes two kinds of mainstream WSN application layer communication protocols MQTT-SN and CoAP and gives the corresponding improvement schemes. By analyzing the design concept and working mechanism of these two application layer communication protocol, this paper shows the protocol performance and the differences among applicable scenarios. Using the CoAP advantages, we further improve the MQTT-SN scheme to make it is suitable for the P2P communication and the blockwise data transmission.