UWB Sniffer HTTP Interface
Packet Analyzer For 802.15.4a UWB Technology
UWB Sniffer can be configured click by click through a web interface and data are typically visualized in Wireshark, but in many applications it might be useful to configure, capture and analyse the data programmatically.
GET Sniffer Status
Send HTTP GET request in following format: http://UWB_SNIFFER_IP/index.shtml
UWB Sniffer should answer HTTP 200 OK. Within HTML page following line of code is interesting:
var values = splitSSIarray('< !--#pindex-->
STOPPED|Error|Info|0.1|00:1a:b6:02:a3:98|10.10.10.2|2|1|0|0|0|0|0|0|0|0|0|0|0|0')
;
Highlighted parameters are displayed on the sniffer’s homepage. They are splitted with “|” separator so their extraction is straightforward.
Param | Value | Format |
State | RUNNING/STOPPED/INJECTING/ERROR | String |
Error message | Text (in normal state no text) | String |
Info message | Text (usually information about recent action) | String |
Version of Firmware | X.X | Decimal Notation |
Sniffer MAC address | XX:XX:XX:XX:XX:XX | Hex Notation |
Sniffer IP address | XXX.XXX.XXX.XXX | Decimal Notation |
Channel Number | X | Decimal Notation |
(Non) Standard Frame Delimiter | 0 = Standard, 1 = Non-Standard | Decimal Notation |
CRC Filter (On/Off) | 1/0 | Decimal Notation |
Data rate | 0 = 110kbps, 1 = 850kbps, 2 = 6.8Mbps | Decimal Notation |
Number of good CRC received frames | 0 – 4096 | Decimal Notation |
Number of bad CRC (CRC error) received frames | 0 – 4096 | Decimal Notation |
Number of received header errors | 0 – 4096 | Decimal Notation |
Number of received frame sync loss events | 0 – 4096 | Decimal Notation |
Number of address filter errors | 0 – 4096 | Decimal Notation |
Number of receiver over-runs | 0 – 4096 | Decimal Notation |
SFD timeouts | 0 – 4096 | Decimal Notation |
Preamble timeouts | 0 – 4096 | Decimal Notation |
RX frame wait timeouts | 0 – 4096 | Decimal Notation |
Number of transmitted frames | 0 – 4096 | Decimal Notation |
SET UWB Sniffer State
Send HTTP GET request in following format: http://UWB_SNIFFER_IP/status.cgi?p=1&run=1
It works in set state. You can set state RUNNING or STOPPED by second parameter.
UWB Sniffer should answer HTTP 200 OK and return page based on first parameter.
Param | Value | Format |
Returned page | 1 = Home page, 2 = Settings page, 4 = Injection page | Decimal Notation |
State | 0 = Stop any action,1 = Run Sniffing | Decimal Notation |
UWB Sniffer Settings
GET UWB Sniffer Settings
Send HTTP GET request in following format: http://UWB_SNIFFER_IP/sett.shtml
Sniffer should answer HTTP 200 OK. Within HTML page following line of code is interesting:
var values = splitSSIarray('< !--#psett-->STOPPED|||2|0|3|2|3|0|1|0|0|0|0|10.10.10.3|255.255.255.0|10.10.10.1|10.10.10.255|17754');
Param | Value | Format |
State | RUNNING/STOPPED/INJECTING/ERROR | String |
Error message | Text (in normal state no text) | String |
Info message | Text (usually information about recent action) | String |
Channel | 1/2/3/4/5/7 | Decimal Notation |
PRF (Pulse repetition frequency) | 0 = 16MHz, 1 = 64MHz | Decimal Notation |
Preamble length | 0 = 4096 symb, 1 = 2048 symb, 2 = 1536 symb, 3 = 1024 symb, 4 = 512 symb, 5 = 256 symb, 6 = 128 symb, 7 = 64 symb |
Decimal Notation |
Data rate | 0 = 110kbps, 1 = 850kbps, 2 = 6.8Mbps | Decimal Notation |
Preamble code | Values from 1 to 12 and 17 to 20 | Decimal Notation |
PAC size | 0 = 8 symb, 1 = 16 symb, 2 = 32 symb, 3 = 64 symb | Decimal Notation |
(Non) Standard Frame Delimiter | 0 = Standard, 1 = Non-Standard | Decimal Notation |
LQI/CRC mode | 0 = LQI mode, 1 = CRC mode | Decimal Notation |
CRC Filter | 0 = OFF, 1 = ON | Decimal Notation |
DHCP | 0 = Static IP, other values are not allowed | Decimal Notation |
Sniffer’s IP address | xxx.xxx.xxx.xxx | Decimal Notation |
Sniffer’s Netmask | xxx.xxx.xxx.xxx | Decimal Notation |
Gateway | xxx.xxx.xxx.xxx | Decimal Notation |
Host IP address | xxx.xxx.xxx.xxx | Decimal Notation |
Host UDP port | 0-65535 | Decimal Notation |
SET Sniffer Radio Settings
Send HTTP GET request in following format (all parameters are required):
http://UWB_SNIFFER_IP/settings.cgi?chan=2&prf=0&pream=3&rate=0&code=3&pac=2&nssfd=1&crcmode=0&crcf=0
Param | Value | Format |
chan | 1/2/3/4/5/7 | Decimal Notation |
prf | 0 = 16MHz, 1 = 64MHz | Decimal Notation |
pream | 0 = 4096 symb, 1 = 2048 symb, 2 = 1536 symb, 3 = 1024 symb, 4 = 512 symb, 5 = 256 symb, 6 = 128 symb, 7 = 64 symb | Decimal Notation |
rate | 0 = 110kbps, 1 = 850kbps, 2 = 6.8Mbps | Decimal Notation |
code | Values from 1 to 12 and 17 to 20 | Decimal Notation |
pac | 0 = 8 symb, 1 = 16 symb, 2 = 32 symb, 3 = 64 symb | Decimal Notation |
nssfd | 0 = Standard, 1 = Non-Standard | Decimal Notation |
crcmode | 0 = LQI mode, 1 = CRC mode | Decimal Notation |
crcf | 0 = OFF, 1 = ON | Decimal Notation |
1) In case of Success
Sniffer should answer HTTP 200 OK. Html page contains http://UWB_SNIFFER_IP/sett.shtml .
2) In case of Error
Sniffer should answer HTTP 200 OK. Html page contains: “Wrong parameters!” string.
SET UWB Sniffer Network (IPv4) Settings
Send HTTP GET request in following format (all parameters are required):
http://UWB_SNIFFER_IP/ipset.cgi?ipmode=0&ipaddr=10.10.10.3&nmask=255.255.255.0&gw=10.10.10.1
WARNING: Following parameters are stored in nonvolatile FLASH memory. Number of write cycles is limited, typically around 10 000 cycles
Param | Value | Format |
ipmode | 0 = static IP, other values are not allowed | Decimal Notation |
ipaddr | xxx.xxx.xxx.xxx | Decimal Notation |
nmask | xxx.xxx.xxx.xxx | Decimal Notation |
gw | xxx.xxx.xxx.xxx | Decimal Notation |
1) In case of Success
Sniffer should answer HTTP 200 OK. Html page contains http://UWB_SNIFFER_IP/sett.shtml .
2) In case of Error
Sniffer should answer HTTP 200 OK. Html page contains: “Wrong parameters!” string.
SET Host Settings
Send HTTP GET request in following format (all parameters are required):
http://UWB_SNIFFER_IP/remoteipset.cgi?remoteip=10.10.10.1&remoteport=17754
WARNING: Following parameters are stored in nonvolatile FLASH memory. Number of write cycles is limited, typically around 10 000 cycles
Param | Value | Format |
remoteip | xxx.xxx.xxx.xxx | Decimal Notation |
remoteport | 0-65535 | Decimal Notation |
1) In case of Success
Sniffer should answer HTTP 200 OK. Html page contains http://UWB_SNIFFER_IP/sett.shtml .
2) In case of Error
Sniffer should answer HTTP 200 OK. Html page contains: “Wrong parameters!” string.
Injection Mode
GET Injection Status
Send HTTP GET request in following format: http://UWB_SNIFFER_IP/inject.shtml
Sniffer should answer HTTP 200 OK. Within HTML page following line of code is interesting:
var values = splitSSIarray('< !--#pinject-->STOPPED|||0|2|0|0|3|3|1|4|6|1|0|1|1|1|');
Param | Value | Format |
State | RUNNING/STOPPED/INJECTING/ERROR | String |
Error message | Text (in normal state no text) | String |
Info message | Text (usually information about recent action) | String |
Remainig time | number in miliseconds of injecting, 0 = no injecting | Decimal Notation |
Channel | 1/2/3/4/5/7 | Decimal Notation |
PRF (Pulse repetition frequency) | 0 = 16MHz, 1 = 64MHz | Decimal Notation |
Data rate | 0 = 110kbps, 1 = 850kbps, 2 = 6.8Mbps | Decimal Notation |
Preamble code | Values from 1 to 12 and 17 to 20 | Decimal Notation |
Preamble length | 0 = 4096 symb, 1 = 2048 symb, 2 = 1536 symb, 3 = 1024 symb, 4 = 512 symb, 5 = 256 symb, 6 = 128 symb, 7 = 64 symb |
Decimal Notation |
(Non) Standard Frame Delimiter | 0 = Standard, 1 = Non-Standard | Decimal Notation |
TX power coarse | 0 = 18dB, 1 = 15dB, 2 = 12dB, 3 = 9dB, 4 = 6dB, 5 = 3dB, 6 = dB | Decimal Notation |
TX power fine | 0 = 0.0dB, 1 = 0.5dB, 2 = 1.0dB, … , 30 = 15dB, 31 = 15.5dB | Decimal Notation |
PGdly (Pulse Generator Delay) | 0 = 0xC9, 1 = 0xC2, 2 = 0xC5, 3 = 0x95, 4 = 0xC0, 5 = 0x93 | Decimal Notation |
Rx Enable | 0 = No, 1 = Yes | Decimal Notation |
Repeat number | 1-100000 | Decimal Notation |
Time space | 1-35791 (miliseconds) | Decimal Notation |
Auto CRC | 0 = CRC not generate, 1 = CRC generate and included | Decimal Notation |
var ssipayload = splitSSIarray('< !--#ppayload-->010203');
Param | Value | Format |
Payload | Chain of bytes, one byte is Two hexadecimal numbers | Hex Notation |
Example: 010203 represents 3 bytes: 0x01, 0x02, 0x03 (0x01 is sending as a first byte).
SET Injection mode
Send HTTP GET request in following format: http://UWB_SNIFFER_IP/inject.cgi?chan=2&prf=0&pream=3&rate=0&txcode=3&nssfd=1&txcoarse=0&txfine=31&pgdly=1&rxen=0&nrepeat=1
&tspace=1&autocrc=1&spayload=010203&len=3
Where parameters are:
Param | Value | Format |
chan | 1/2/3/4/5/7 | Decimal Notation |
prf | 0 = 16MHz, 1 = 64MHz | Decimal Notation |
pream | 0 = 4096 symb, 1 = 2048 symb, 2 = 1536 symb, 3 = 1024 symb, 4 = 512 symb, 5 = 256 symb, 6 = 128 symb, 7 = 64 symb | Decimal Notation |
rate | 0 = 110kbps, 1 = 850kbps, 2 = 6.8Mbps | Decimal Notation |
txcode | Values from 1 to 12 and 17 to 20 | Decimal Notation |
nssfd | 0 = Standard, 1 = Non-Standard | Decimal Notation |
txcoarse | 0 = 18dB, 1 = 15dB, 2 = 12dB, 3 = 9dB, 4 = 6dB, 5 = 3dB, 6 = dB | Decimal Notation |
txfine | 0 = 0.0dB, 1 = 0.5dB, 2 = 1.0dB, … , 30 = 15dB, 31 = 15.5dB | Decimal Notation |
pgdly | 0 = 0xC9, 1 = 0xC2, 2 = 0xC5, 3 = 0x95, 4 = 0xC0, 5 = 0x93 | Decimal Notation |
rxen | 0 = No, 1 = Yes | Decimal Notation |
nrepeat | 1-100000 | Decimal Notation |
tspace | 1-35791 (miliseconds) | Decimal Notation |
autocrc | 0 = CRC not generate, 1 = CRC generate and include | Decimal Notation |
spayload | Chain of bytes. One byte is Two hexadecimal numbers | Hex Notation |
len | 1-125 (127 for autocrc = 0) | Decimal Notation |
1) In case of Success
Sniffer should answer HTTP 200 OK. Html page contains http://UWB_SNIFFER_IP/inject.shtml .
2) In case of Error
Sniffer should answer HTTP 200 OK. Html page contains: “Wrong parameters!” string.