Describes the construction of a wireless sensor network through ECG acquisition nodes and 6LoWPAN border routers to realize the communication between the wireless sensor network (WSN) and the IPV6 network; the Trickle algorithm mechanism in the RPL network protocol leads to the selection of sub-optimal links, which affects The reliability and stability of the network routing proposed an optimization scheme. Carried out simulation test and optimized network performance index analysis. The test results and analysis show that the 6LoWPAN wireless sensor network can not only complete the connection between WSN and the external IPv6 network to carry data transmission and reception, but also has a high impact on improving network performance after the Trickle algorithm is optimized.