# RF Test
#System introduction
In the process of product certification, it is usually necessary to evaluate the RF transceiver performance of the wireless module to determine whether it meets the certification specifications and international standards. Since the RF signal parameters and the receiving and transmitting timing cannot be kept unchanged during the normal communication of the module, the RF signal received and transmitted during the normal communication of the module is generally not directly tested during the authentication and test. The module must enter a specific RF transmission and reception mode (hereinafter referred to as ATE working mode), and send and receive specific test signals and messages through the mpTools software set module running on the PC for measurement by the test equipment.
The connection diagram of the whole test system is as follows:
A Windows PC running mpTool software is connected to the module running in ATE mode through the serial port, and the module is controlled by UART command to send and receive RF signals of various parameters. The test instrument can receive the signal of the module through the antenna, or directly connect with the antenna interface of the module through the RF cable, so as to comprehensively test and evaluate the RF performance of the module.
When the module starts, it will detect the level of the Boot signal and EasyLink pins. If both pins are low, the module will enter the ATE mode. The module receives the control command transmitted on the PC through UART0. Therefore, the signal lines required by the module are as follows:
● Boot: keep low level when the module is powered on
● EasyLink: keep low level when the module is powered on
● MICO_ UART0_ TXD: receiving signal for UART communication with PC
● MICO_ UART0_ RXD: sending signal for UART communication with PC
● VDD: power supply of modules
● GND: grounding signal line of module
For the positions of the above signal and power lines on different models of modules, please refer to the data manuals of the corresponding modules. For EMW3080, Pin19 (boot) and Pin23 (Elink) are grounded (pulled down), and Pin9 (UART0_TXD)&10 (UART0_RXD) are connected to the UART of the PC.
In the following example, we choose the EMW3080 as the test module. At the same time, in order to facilitate the power supply to the module and the setting of the working mode, we install the module on the MXKit development board. The MXKit Base backplane of the MXKit can convert UART signals into USB signals, so the PC is connected to the MXKit development board through the Micro USB cable. The EMW3080 module is welded to the core board MXKit Core-3080, and then plugged into the MXKit Base backplane.
#Preparation Before Test
#Connect PC and module
- Install the driver of the UART to USB chip: CP2105 on the MXKit Base backplane on the PC.📎cp2102驱动.zip。
- Connect PC and MXKit development board through Micro USB cable.
- Two virtual serial port devices can be seen on the device manager of Windows. Record the COM port number corresponding to Silicon Labs CP210x USB to UART Bridge: Enhanced COM Port. For example, in the following figure, the corresponding port number is COM4.
#Enter to ATE working mode
After the Boot signal and EasyLink signal of the module are grounded, the module will automatically enter the ATE working mode after the module is powered on again. The operation method on MXKit is:
1. Turn the 1# toggle switch of the dial switch on the MXKit Base board to ON.
2. Press and hold the ELINK button on the right, and then press the RESET button on the left. Release the module after resetting.
#Start mpTool and finish initialization
- Download mpTool software: 📎mptool-1v16.zip. After decompression, run UI_mptool.exe。
- In the Main tab, select the serial port number recorded in the step of "connecting PC and module" from the drop-down menu of select COM. In this example, it's COM4.
- Click Initialize button to complete initialization. If initialization fails, the View Window on the right side of the software will display the cause of the error. After success, other controls in the software will be turned on.
#mpTool introduction
The mpTool software is divided into four labels, namely Main, PSD, Efuse and Reg.
In the Main window, you can set RF transceiver parameters and modes, and start the transceiver test. Other windows are used for module production, and users do not need to operate. If the functions of these labels are used without authorization, it is likely to damage the calibration parameters of the module produced in the factory, and cause permanent damage to the module that cannot be repaired.
The functions of each control in the Main tab window are as follows:
Select COM: select the serial port number for communication between PC and module
Control: including various control functions
Initialize: initialize the serial port and the module to be tested.
Pwridx by Rate and Limit: When it is selected, the software reads the initial value of the parameter from the Efuse of the module, and limits the antenna transmission power to a certain extent, which is displayed in the TX Power Index and cannot be modified. If it is not selected, the user can adjust the value in the TX Power Index to increase or decrease the transmission power.
TX Power Tracking Start: start the temperature compensation function, usually not.
MAC Address, Wlan Mode: optional.
Testing Item: Select the test items, as follows:
- Packet TX: used to test RF transmission performance, such as power, EVM and frequency offset.
- Continuous TX: used to test transmission power or maximum power consumption of test modules in FCC/CE/CMCC/CTA certification.
- Single Tone TX: used to test frequency offset.
- Carrier Suppression TX: used for 802.11b only.
- Packet RX (All), Packet RX (Filtered): receiving test, which can be used to test the receiving sensitivity and bit error rate of the module.
Start/Stop: start and stop the test item selected in "Testing Item".
TX Setting and RX Setting: set RF parameters of receiving and sending.
- Ant TX and Ant RX: For this series of modules, fixed option A.
- Data Channel: Select the radio frequency band for RF transceiver.
- Data Rate: modulation mode and data transmission rate.
- TX Power Index: antenna transmission power (only A antenna can be set). The module cannot set the RF signal with a fixed output power, and it can only be adjusted based on the current transmission power. The transmission power will increase/decrease by 0.5dBm for each increase/decrease of 1 in the Power Index. The initial value of TX Power Index is saved in Efuse, and is calibrated by MXCHIP during module production. It conforms to the parameters in the data manual, ensures performance and meets the requirements of certification standards.
- Preamble: Set the preamble mode of the message, Long is optional_ GI and Short_ GI.
- Bandwidth: RF transceiver bandwidth, 20MHz or 40MHz.
- Xtal.cap: calibration value of crystal oscillator, which can be used to adjust RF frequency offset.
TX Packet Setup: set message sending parameters.
- Pattern: set the type of TX message.
- Count: number of package sent.
- Length: length of each package.
- Interval: not adjustable.
Packet counter: display the number of packets sent, received and received with errors
- Reset: Restore the quantity to 0
View Window: Software Log output window
#Test Demo
#Signaling mode sending test
#Read default factory parameter
- Chose Pwridx by Rate and Limit,read factory factory from Efuse.
- Choose TX test item: Packet TX.
- Choose RF channel.
- Choose modulation mode and data rate.
- Choose bandwidth.
- Start test.
#Customize sending parameters
- Do not choose Pwridx by Rate and Limit.
- Choose TX test item:Packet TX.
- Choose RF Channel.
- Choose modulation and data rate.
- Set transmit power. Under different modulation modes and rates, the transmission power settings are shown in the following table. Increase or decrease on this basis.
802.11b | 802.11g | 802.11n | |||
1M | 11M | 6M | 54M | MCS0 | MCS7 |
35 | 35 | 46 | 44 | 45 | 42 |
- Choose bandwidth.
- Choose parameter for frequency calibration.
- Start Test.
#Single Tone Sending Test
- Choose TX test item:Single Tone TX
- Choose transmission channel.
- Set power for transmission.
- Start test.
#Reception Test
- Choose RX test item:Packet Rx(All)
- Choose transmission power.
- Start test.
- Check number of packets received.
#Connection between module and RF test instrument
There are two methods for the RF test instrument to detect the RF signal sent by the module:
● Wireless reception with 2.4GHz antenna
● Receive directly after connecting the transmission wire with the antenna interface of the module. If the module uses PCB on-board antenna, disconnect the PCB antenna first. Follow the following test steps:
a. Remove the 0 ohm resistance between the chip and the antenna on the module.
<span class="ne-text"> </span><img width="245" alt="" src="/img/1582878943267-bf5df111-cbe2-46dd-89a1-1e1970d08d6f.png"></img>
<span class="ne-text">b. Weld the transmission wire to the antenna test point on the back of the module, and connect the other end of the transmission wire to the test instrument.</span>
<span class="ne-text"> </span><img width="427" alt="" src="/img/1582878392541-1cbc9ee0-0f69-4b81-92bb-4b6f7b310305.png"></img>
#Appendix 1: Wi Fi ATE Serial Port Instruction
mptool interacts with the module to be tested through serial port instruments.Developers can develop customized testing systems according to these instructions.
#Command List
#Start MP mode
After execute the command, Wi-Fi driver will stop tranmitting data, and enter to MP mode.
iwpriv mp_start
#Stop MP mode
After execute the command, Wi-Fi driver will stop message output started by other command. But the system can enter the normal Wi Fi connection mode only after it is restarted.
iwpriv mp_stop
#Set Tx rate
Set Tx message data transmission rate.
iwpriv mp_rate rate
rate: data transmission rate. 2 = 1M, 4 = 2M, 11 = 5.5M, …, 108 = 54M, 128 = MCS0, 129 = MCS1, …, 142 = MCS15
#Set operational channel
Set the working frequency band for sending and receiving messages.
iwpriv mp_channel channel
channel: frequency band for sending and receiving messages.
#Set operational bandwidth
Set the bandwidth for sending and receiving data packets and the Guard Interval for transmitting MCS messages. If no parameter is provided, the default setting is 20MHz bandwidth, and long GI is used for transmission.
iwpriv mp_bandwidth 40M=40m, shortGI=sgi
40m: set bandwidth,1=40M mode,0=20M mode.
sgi: set mode of GI,1=Short GI,0=long GI.
#Set Tx power
Set transmission power of path A and B. If no parameters are provided, the preset parameters in Flash are used.
iwpriv mp_txpower patha=x,pathb=y
x: transmission power of path A.
y: transmission power of path B.
#Set antenna for Tx
Set antenna used for transmission.
iwpriv mp_ant_tx ant
ant: antenna used for transmission. a=antenna A,b=antenna B,ab=antenna A and B。
#Set antenna for Rx
Set antenna used for reception.
iwpriv mp_ant_rx ant
ant: antenna used for reception. a=antenna A,b=antenna B,ab=antenna A and B.
#Start air Rx mode
The command is used for wireless reception test. Use the stard command to start package reception, the stop command to stop counting and display the statistics of correct and error messages. Use the phy command to display number of packets received by the RF physical layer,CRC errors, and failure alarms.
iwpriv mp_arx start/stop/phy
start: start rececption.
stop: stop counting and display statistics.
phy: display number of packets received by the RF physical layer,CRC errors, and failure alarms.
#Start continuous Tx mode
The command is used for continous sending test. Use the time command to set the sending time, and the count command to set the number of packets to be sent.
- If the time and the count are not set, the continuous sending mode will be started.
- If the background mode is not set, any character input can stop sending.
- If the cs mode is not set,the carrier suppression signal is tranmitted.
- Use the stone command to send single tone signal to test the frequency.
- If stone is set, the signal sent will not be a recognizable message.
- By default, hardware is used to send short duty cycle signals.
- If pkt is set,software controls the sending of packets.
iwpriv mp_ctx count=n,background,stop,pkt,cs,stone
t: set time of sending packets
n: set number of sending packets
background: set mode of backstage transmitting data
stop: stop backstage transmitting data
pkt: transmit tx packets
cs: transmit carrier suppression signal
stone: transmit single tone carrier suppression signal
#Query air Rx statistics
Used for wireless message counting. When transmitting data packets, use this command to obtain the number of transmitted messages. When receiving, this command can be used to obtain the statistics of correct and CRC error messages.
iwpriv mp_query
#Reset air Tx/Rx statistics
This command can recharge the message count. When sending, this command can reset the number of packets, and when receiving, it can reset the number of correct and CRC error messages.
iwpriv mp_reset_stats
#Command Usage Demo
#Continous Transmitting Test
iwpriv mp_start //enter MP mode iwpriv mp_channel 1 //set channel to 1 . 2, 3, 4~11 etc. iwpriv mp_bandwidth 40M=0,shortGI=0 //set 20M mode and long GI iwpriv mp_ant_tx a //select antenna A for operation iwpriv mp_txpower patha=44,pathb=44 //set path A and path B Tx power level iwpriv mp_rate 108 //set OFDM data rate to 54Mbps,e x: CCK 1M = 2, CCK 5.5M = 11, KK, OFDM54M = 108 N Mode: MCS0 = 128, MCS1 = 129…..etc. iwpriv mp_ctx background //start continuous Tx iwpriv mp_ctx stop //stop continuous Tx iwpriv mp_stop //exit MP mode
#Continuous message sending test
iwpriv mp_start //enter MP mode iwpriv mp_channel 1 //set channel to 1 . 2, 3, 4~11 etc. iwpriv mp_bandwidth 40M=0,shortGI=0 //set 20M mode and long GI iwpriv mp_ant_tx a //select antenna A for operation iwpriv mp_txpower patha=44,pathb=44 //set path A and path B Tx power level iwpriv mp_rate 108 //set OFDM data rate to 54Mbps, ex: CCK 1M = 2, CCK 5.5M = 11, KK, OFDM54M = 108 N Mode: MCS0 = 128, MCS1= 129….. etc. iwpriv mp_ctx background,pkt //start packet continuous Tx iwpriv mp_ctx stop //stop continuous Tx
#Carrier suppression test
iwpriv mp_start //enter MP mode iwpriv mp_channel 1 //set channel to 1 . 2, 3, 4~11 etc. iwpriv mp_bandwidth 40M=0,shortGI=0 //set 20M mode and long GI iwpriv mp_ant_tx a //select antenna A for operation iwpriv mp_txpower patha=44,pathb=44 //set path A and path B Tx power level iwpriv mp_rate 108 //set OFDM data rate to 54Mbps,ex: CCK 1M = 2, CCK 5.5M = 11, KK, OFDM54M = 108 N Mode: MCS0 = 128, MCS1 = 129…..etc. iwpriv mp_ctx background,cs //start sending carrier suppression signal iwpriv mp_ctx stop //stop continuous Tx iwpriv mp_stop
#Single Tone Signal Tranmition Test
iwpriv mp_start //enter MP mode iwpriv mp_channel 1 //set channel to 1 . 2, 3, 4~11 etc. iwpriv mp_bandwidth 40M=0,shortGI=0 //set 20M mode and long GI iwpriv mp_ant_tx a //select antenna A for operation iwpriv mp_txpower patha=44,pathb=44 //set path A and path B Tx power level iwpriv mp_rate 108 //set OFDM data rate to 54Mbps,ex: CCK 1M = 2, CCK 5.5M = 11, KK, OFDM54M = 108 N Mode: MCS0 = 128, MCS1 = 129…..etc. iwpriv mp_ctx background,stone //start sending single tone signal iwpriv mp_ctx stop //stop sending single tone signal iwpriv mp_stop //exit MP mode
#Reception Test
iwpriv mp_start //enter MP mode iwpriv mp_bandwidth 40M=1,shortGI=0 //set 40M mode and long GI iwpriv mp_channel 6 //set channel to 6 iwpriv mp_ant_rx ab //select all 2 antennas for operation iwpriv mp_arx start //start air Rx iwpriv mp_query //get the statistics iwpriv mp_arx stop //stop air Rx and show the statistics iwpriv mp_stop //exit MP mode
______________________________________________________________________________________________________________
END.