7.3 RF Measurement Process with Python

Important: Install Microchip Python Libraries and dependencies for the corresponding Python version needed by the PHY Performance script TestATT_rf.py for RF validation.

Once boards are supplied and programmed with the PLC PHY Tester Hybrid Firmware, connect both DUT and reference boards to the PC by means of a USB/Serial Port cable (better if it includes any kind of ferrite chocke filter).

  1. Open and edit the TestATT_rf.config file.
  2. Configure the property name to form the name of the output files, and identify the results.
  3. Configure the paths setting:
  • rx: Data from Reference Tester to DUT. Helps to analyze DUT reception path.
  • tx: Data from DUT to Reference Tester. Helps to analyze DUT transmission path.
  • tx_rx: First evaluates TX path, then RX path.
  • rx_tx: First evaluates RX path, then TX path.
4. Configure the port_dut and port_reference that defines the connection to the DUT and the Reference Tester.
  • COMX:SPEED– Local Serial COM Port connection and speed baud rate (bps).
  • IP:PORT– TCP/IP connection. Physical connection to DUT and Reference Tester is always a Serial Port connection, but it can be accessed remotely through additional software like socat, COMbyTCP, SerialToI.
Configure the band_op_mode setting corresponding to the operating frequency band an mode:
  • SUN_[FSK|OFDM]_BAND_[863|866|870|915|915A|915B|915C|919|920|920B]_OP[M|T][1-12]

Configure the fec to test with or without convolution coding (by default off as specified on G3).

Configure the platform device under test. By default RF215.

Configure the attenuation plan for the test:
  • Configure the Attenuator Instrument attenuator_device_id using the Virtual instrument software architecture (VISA) address. If the setup does not include a digital attenuator instrument, just comment the line and the script will ask for manual attenuation setting during the test.
  • Configure the att_start, att_step and att_stop values.
  • Configure the att_int_fixed reducing the transmitted power in TX (0 to 31). Default 30 to reduce the air coupling.
  • Configure the att_ext_fixed present on the setup. Typically:
    • att_ext_fixed = 80 dB = 2 * 40 dB (Fixed Att on antenna connectors in both sides).
If needed, configure the message length, msg_len between:
  • max: Configures the maximum physical size for the frame.
  • fixed: Configures the value defined by msg_len_value.
  • random: Configures a random value between the minimum and maximum allowed.
If needed, configure the message content: msg_content:
  • random
  • fixed
Additionally, there are some configurations for file report sending and storing:
  • email_server: Email server for SMTP request.
  • email_notification: Email address for sending the reports (no SQL databases included).
  • repo_server: Windows shared folder where store reports and databases.
Run the TestATT_rf.py script according to customer-specific configuration.
C:\PHYperformance\python.exe TestATT_rf.py -c TestATT_rf.config
C:\Python37\lib\site-packages\visa.py
Physical RF DUT Testing Tool
AGILENT TECHNOLOGIES, J7211A, MY52201152, A.00.04
Physical RF Testing Tool
Completed: 0.000000 %
ATTENUATION: 0
Sent 010 of 010 (362) - Received 010 (-102 dBm)
FER = 0.000000 %
Completed: 4.761905 %
ATTENUATION: 1
Sent 010 of 010 (056) - Received 010 (-103 dBm)
FER = 0.000000 %
Completed: 9.523810 %
...
ATTENUATION: 19
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue0 (311) - Received 001 (-121 dBm)
FER = 90.000000 %
Completed: 95.238095 %
ATTENUATION: 20
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
FER = 100.000000 %
END of -> ATTENUATION: 20
FINISHED with completed: 100.000000 %
Completed: 0.000000 %
ATTENUATION: 0
Sent 010 of 010 (386) - Received 010 (-101 dBm)
FER = 0.000000 %
Completed: 4.761905 %
ATTENUATION: 1
Sent 010 of 010 (030) - Received 010 (-102 dBm)
FER = 0.000000 %
Completed: 9.523810 %
ATTENUATION: 2
Sent 010 of 010 (256) - Received 010 (-104 dBm)
FER = 0.000000 %
Completed: 14.285714 %
...
ATTENUATION: 18
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue0 (166) - Received 001 (-118 dBm)
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue

FER = 90.000000 %
Completed: 90.476190 %
ATTENUATION: 19
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue0 (205) - Received 001 (-120 dBm)
Empty Rx Queue
Empty Rx Queue0 (097) - Received 002 (-119 dBm)
Empty Rx Queue
Empty Rx Queue

FER = 80.000000 %
Completed: 95.238095 %
ATTENUATION: 20
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue
Empty Rx Queue

FER = 100.000000 %
END of -> ATTENUATION: 20
FINISHED with completed: 100.000000 %
Test finished, Duration:0:03:29
Sending e-mail report to username@domain.com
E-mail sent.

The results obtained can be compared with the results obtained with Microchip Evaluation Boards and checked with the transmission and reception characteristics of RF215 transceiver.

PHY Performance Validation Python script for RF outputs two files:
  • Sqlite Database: This file is the database that includes all the raw information of the test. It includes:
    • Configurations Table: Includes the DUT name, date, time and configuration file of the test.
    • Frames Table: Includes all the frames with their corresponding parameter values. It is possible to use a SQL database browser for accessing the full information stored by the tests.
  • Basic Excel Report: It includes the frame error rates in function of the Attenuation programmed and the RSSI received.
Figure 7-2. Typical FER vs RSSI on a RF setup