您的位置:首页 > 其它

Zigbee 学习计划——第5天——无线传输质量检测

2012-11-26 17:19 197 查看
    周日在家做实验,测试了无线传输质量检测这一块。实测发现10米距离就会有丢包现象发生,而且RSSI会变成-80左右。不知道为什么会这样,难道是跟LAYOUT或是天线有关?或是说由于信号受墙壁影响?(发送在一间房,接收在客厅)

PER Test Receiver configuration: 

Perform the following steps to configure the receiver node: 

1.  Reset the board by cycling power. 

2.  Press Button 1 to enter the application menu. 

3.  Select a channel between 11 and 26. Navigate the menu by pressing joystick left or right, and 

confirm the selection by pressing Button 1. Note the channel, since it will also be used for the 

Transmitter node.  

4.  Select operating mode ‘Receiver’ and confirm with Button 1.  

5.  The Receiver node is now ready for operation, displaying ‘Receiver Ready’. 

 
PER Test Transmitter configuration 

Perform the following steps to configure the transmitter node: 

1.  Reset the board by cycling power. 

2.  Press Button 1 to enter the application menu. 

3.  Select the same channel as for the Receiver node. Navigate the menu by pressing joystick left 

or right, and confirm the selection by pressing Button 1.  

4.  Select operating mode ‘Transmitter’ and confirm with Button 1.  

5.  Select TX output power by navigating the joystick. Confirm with Button 1. 

6.  Select the number of packets, either 1000, 10K, 100K or 1M. Press Button 1 to confirm. 

7.  Select packet rate; 100, 50, 20 or 10 packet per second. Press Button 1 to confirm.  

8.  Push the joystick down to start a PER test. The number of packets specified by burst size will 

be sent to the Receiver node. Packet Error Rate, RSSI, and number of packets received are 

displayed on the Receiver’s LCD panel.  

9.  The PER test can be stopped by pressing joystick down again. 

Calculation of PER and RSSI 

In order to obtain the statistics during the PER test, the receiver maintains the following variables. The 

variable rxStats is of type perRxStats_t as defined in per_test.h. 

 
rxStats.expectedSeqNum  The  expected  sequence  number  for  the  next  packet  that  should 

arrive.  This  is  equivalent  to  the  number  of  received  packets+lost 

packets +1. 

 
rxStats.rssiSum    This is the sum of the RSSI level of the
last 32 packets.  [/u]

 
rxStats.rcvdPkts    The number of correctly received packets as part of the PER test. 

 
rxStats.lostPkts    The number of packets that have been lost. 

 

Lost packets are detected through a jump in the sequence number. If the received packet has a higher 

sequence number than rxStats.expectedSeqNum the packets in between are calculated as lost. This 

implies that a series of lost packets will not be detected until a subsequent packet has been received 

correctly. Packets with errors are considered as lost.  

 

The PER value per thousand packets is calculated by the formula: 
PER = 1000* rxStats.lostPkts/ (rxStats. lostPkts+ rxStats. rcvdPkts) 

(for rxStats. rcvdPkts>=1) 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: