=== N310 configuration and access === ==== Description ==== This tutorial shows how to configure and access the N310 SDR from an experiment server. The N310 is used as a network based USRP which has a 1Gb control interface and a 10Gb data interface. Both interfaces need to be configure properly for control and data streaming. Product information for the N310 is [https://www.ettus.com/all-products/usrp-n310/ here]. ==== Network configuration ==== From a COSMOS console, load a baseline sdr image onto an experiment server - for this example ''srv1-lg1.sb1.cosmos-lab.org'' is used. {{{#!shell-session console:~$ omf load -i baseline-uhd.ndz -t srv1-lg1.sb1.cosmos-lab.org console:~$ omf tell -a on -t srv1-lg1.sb1.cosmos-lab.org }}} After the experiment server (srv1-lg1) is up, ssh into it and list the all interfaces. {{{#!shell-session $ ifconfig -a eno1: flags=4163 mtu 1500 inet6 fe80::1e34:daff:fe42:c3c prefixlen 64 scopeid 0x20 ether 1c:34:da:42:0c:3c txqueuelen 1000 (Ethernet) RX packets 137 bytes 18069 (18.0 KB) RX errors 0 dropped 119 overruns 0 frame 0 TX packets 22 bytes 4234 (4.2 KB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 eno2: flags=4163 mtu 1500 inet6 fe80::1e34:daff:fe42:c3d prefixlen 64 scopeid 0x20 ether 1c:34:da:42:0c:3d txqueuelen 1000 (Ethernet) RX packets 170 bytes 20064 (20.0 KB) RX errors 0 dropped 120 overruns 0 frame 0 TX packets 20 bytes 4070 (4.0 KB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 enp134s0: flags=4163 mtu 1500 inet 10.37.1.1 netmask 255.255.0.0 broadcast 10.37.255.255 inet6 fe80::6a05:caff:fe1e:e4ec prefixlen 64 scopeid 0x20 ether 68:05:ca:1e:e4:ec txqueuelen 1000 (Ethernet) RX packets 169 bytes 30675 (30.6 KB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 140 bytes 18939 (18.9 KB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 device interrupt 86 memory 0xd3880000-d38a0000 lo: flags=73 mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10 loop txqueuelen 1000 (Local Loopback) RX packets 298 bytes 24341 (24.3 KB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 298 bytes 24341 (24.3 KB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 }}} The interfaces should be configured as shown in the table. The control interface should come up automatically however the data interface needs to be configured. || Interface name || Speed || Address || Description || || eno1 || 10G || 10.39.1.1 || Data interface for sample streaming || || enp134s0 || 1G || 10.37.1.1 || Control interface used for command streaming|| Configure ''eno1'' so it can talk to the N310's data interface and set the network tcp buffers as well. {{{#!shell-session $ ip addr add 10.39.1.1/16 dev DATA1 $ ip link set DATA1 mtu 8000 $ sysctl -w net.core.wmem_max=62500000 $ sysctl -w net.core.rmem_max=62500000 }}} Run ''uhd_find_devices'' to detect the available N310s. This enumerates all the SDRs that were detected. {{{#!shell-session $ uhd_find_devices --args="type=n3xx" [INFO] [UHD] linux; GNU C++ version 7.5.0; Boost_106501; UHD_3.15.0.HEAD-0-gaea0e2de -------------------------------------------------- -- UHD Device 0 -------------------------------------------------- Device Address: serial: 3176DF5 addr: 10.39.2.1 claimed: False mgmt_addr: 10.37.2.1 product: n310 type: n3xx -------------------------------------------------- -- UHD Device 1 -------------------------------------------------- Device Address: serial: 3196937 claimed: False mgmt_addr: 10.37.3.1 product: n310 reachable: No type: n3xx }}} Access UHD Device 0 by using the ''uhd_usrp_probe'' command with ''mgmt_addr'' and ''addr'' to list the device properties of this N310. The ip address must match correctly to the corresponding interface. || args || address || interface type || || mgmt_addr || 10.37.2.1 || control || || addr || 10.39.2.1 || data || {{{#!shell-session $ uhd_usrp_probe --args="mgmt_addr=10.37.2.1,addr=10.39.2.1" [INFO] [UHD] linux; GNU C++ version 7.5.0; Boost_106501; UHD_3.15.0.HEAD-0-gaea0e2de [INFO] [MPMD] Initializing 1 device(s) in parallel with args: mgmt_addr=10.37.2.1,type=n3xx,product=n310,serial=3176DF5,claimed=False,addr=10.39.2.1 [INFO] [MPM.PeriphManager] init() called with device args `product=n310,mgmt_addr=10.37.2.1,time_source=internal,clock_source=internal'. [INFO] [0/Replay_0] Initializing block control (NOC ID: 0x4E91A00000000004) [INFO] [0/Radio_0] Initializing block control (NOC ID: 0x12AD100000011312) [INFO] [0/Radio_1] Initializing block control (NOC ID: 0x12AD100000011312) [INFO] [0/DDC_0] Initializing block control (NOC ID: 0xDDC0000000000000) [INFO] [0/DDC_1] Initializing block control (NOC ID: 0xDDC0000000000000) [INFO] [0/DUC_0] Initializing block control (NOC ID: 0xD0C0000000000002) [INFO] [0/DUC_1] Initializing block control (NOC ID: 0xD0C0000000000002) [INFO] [0/FIFO_0] Initializing block control (NOC ID: 0xF1F0000000000000) [INFO] [0/FIFO_1] Initializing block control (NOC ID: 0xF1F0000000000000) [INFO] [0/FIFO_2] Initializing block control (NOC ID: 0xF1F0000000000000) [INFO] [0/FIFO_3] Initializing block control (NOC ID: 0xF1F0000000000000) _____________________________________________________ / | Device: N300-Series Device | _____________________________________________________ | / | | Mboard: ni-n3xx-3176DF5 | | eeprom_version: 2 | | mpm_version: 3.15.0.0-gaea0e2de | | pid: 16962 | | product: n310 | | rev: 6 | | rpc_connection: remote | | serial: 3176DF5 | | type: n3xx | | MPM Version: 1.2 | | FPGA Version: 5.3 | | FPGA git hash: fde2a94.clean | | RFNoC capable: Yes | | | | Time sources: internal, external, gpsdo, sfp0 | | Clock sources: external, internal, gpsdo | | Sensors: gps_time, gps_sky, gps_tpv, gps_gpgga, fan, ref_locked, temp, gps_locked | | _____________________________________________________ | | / | | | RX Dboard: A | | | _____________________________________________________ | | | / | | | | RX Frontend: 0 | | | | Name: Magnesium | | | | Antennas: TX/RX, RX2, CAL, LOCAL | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 75.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | RX Frontend: 1 | | | | Name: Magnesium | | | | Antennas: TX/RX, RX2, CAL, LOCAL | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 75.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | RX Codec: A | | | | Name: AD9371 Dual ADC | | | | Gain Elements: None | | _____________________________________________________ | | / | | | RX Dboard: B | | | _____________________________________________________ | | | / | | | | RX Frontend: 0 | | | | Name: Magnesium | | | | Antennas: TX/RX, RX2, CAL, LOCAL | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 75.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | RX Frontend: 1 | | | | Name: Magnesium | | | | Antennas: TX/RX, RX2, CAL, LOCAL | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 75.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | RX Codec: B | | | | Name: AD9371 Dual ADC | | | | Gain Elements: None | | _____________________________________________________ | | / | | | TX Dboard: A | | | _____________________________________________________ | | | / | | | | TX Frontend: 0 | | | | Name: Magnesium | | | | Antennas: TX/RX | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 65.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | TX Frontend: 1 | | | | Name: Magnesium | | | | Antennas: TX/RX | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 65.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | TX Codec: A | | | | Name: AD9371 Dual DAC | | | | Gain Elements: None | | _____________________________________________________ | | / | | | TX Dboard: B | | | _____________________________________________________ | | | / | | | | TX Frontend: 0 | | | | Name: Magnesium | | | | Antennas: TX/RX | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 65.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | TX Frontend: 1 | | | | Name: Magnesium | | | | Antennas: TX/RX | | | | Sensors: lo_locked, ad9371_lo_locked, lowband_lo_locked | | | | Freq range: 1.000 to 6000.000 MHz | | | | Gain range all: 0.0 to 65.0 step 0.5 dB | | | | Gain range rfic: 0.0 to 0.0 step 0.0 dB | | | | Gain range dsa: 0.0 to 0.0 step 0.0 dB | | | | Gain range amp: 0.0 to 0.0 step 0.0 dB | | | | Bandwidth range: 20000000.0 to 100000000.0 step 0.0 Hz | | | | Connection Type: IQ | | | | Uses LO offset: No | | | _____________________________________________________ | | | / | | | | TX Codec: B | | | | Name: AD9371 Dual DAC | | | | Gain Elements: None | | _____________________________________________________ | | / | | | RFNoC blocks on this device: | | | | | | * Replay_0 | | | * Radio_0 | | | * Radio_1 | | | * DDC_0 | | | * DDC_1 | | | * DUC_0 | | | * DUC_1 | | | * FIFO_0 | | | * FIFO_1 | | | * FIFO_2 | | | * FIFO_3 }}} ==== Trouble shooting ==== The FPGA bit file will need to be updated if FPGA version mismatch is generated in the output text of the uhd command above. Follow the steps below to update the FPGA image - this will download and install the FPGA image that is matched with the UHD version being used. Complete details on updating the FPGA is found [https://kb.ettus.com/USRP_N300/N310/N320/N321_Getting_Started_Guide#Updating_the_FPGA_Image here]. {{{#!shell-session node:~$ sudo uhd_images_downloader node:~$ uhd_image_loader --args "type=n3xx,addr=10.37.2.1,fpga=HG" }}} After the image loader completes, power-cycle the N310 from the console and detect the N310 again. {{{#!shell-session console:~$ omf tell -a offh -t sdr1-s1-lg1.sb1.cosmos-lab.org console:~$ omf tell -a on -t sdr1-s1-lg1.sb1.cosmos-lab.org }}}