User Tools

Site Tools


wiki:loraloc

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
wiki:loraloc [2016/10/12 18:07]
dlr
— (current)
Line 1: Line 1:
-====== LoRaLoc modem ====== 
  
- 
-===== HALv2 (Loraloc / sx1301 array) ===== 
- 
-The downloadable source tarball is available in dedicated [[wiki:​ressources|ressources]] page. 
- 
-The HAL provided by Kerlink is based on new Semtech HAL **lora_gateway_v2**. \\ 
-Main modifications aim to adapt HAL to Kerlink boards: 
-  * Multi-board support 
-  * Calibration parameters can now be parsed as an overload config file (similarly to local_conf.json) named /​tmp/​calib_loraloc.json 
- 
- 
-As Loraloc architecture is much more complex, this HAL is quite different from HAL v1. \\ 
- 
-==== Compilation ==== 
- 
-To compile it, please use following commands: 
-<code bash> 
-cd lora_gateway_v2 
-source /​opt/​toolchains/​loraV2/​environment-setup-cortexa9hf-neon-poky-linux-gnueabi 
-make SPI_HOST=imx 
-</​code>​ 
- 
-To simplify deployment on board, Kerlink provides a script called **build_package.sh**. \\ 
-This tool script make all tools and prepare an OPKG package including them. 
- 
-==== Usage ==== 
- 
-The main modification in tools since HALv1 is the '​-d'​ argument. \\ 
-As this HAL is mainly designed to handle multiple RF chips, this optional argument allows to specify which spidevice to use. 
- 
-Kerlink provides a automatic discovery script at startup to handle correctly plugged boards. 
- 
-By default, if a WAN module is provided, loraloc modules are mapped from slot 2. 
- 
-So to use tools with this Loraloc module, please specify on tool's command-line **-d /​dev/​slot/​2/​spidev0**. \\ 
-For example: 
-<code bash> 
-./​pkt_logger -d /​dev/​slot/​2/​spidev0 
-</​code>​ 
- 
-==== Configuration ==== 
- 
-Due to architecture,​ the configuration is quite more complex than HAL v1: 
-  * **board** keyword means "​Loraloc board" or "​LoraLoc module"​ (one "​board"​ by slot) 
-  * each board includes 2 **chip** configs (i.e. sx1301 configs) 
-  * each board includes 2 **rfchain** configs 
- 
-=== Chip config === 
- 
-This configuration must include SX1301 channel config. \\ 
-These channels can be configured through "​sx1301ar_conf_chan"​ function. \\ 
-Please note that this function takes as "​channel number"​ the concatenation of chip number and channel. (see function description in sx1301ar_hal.h) 
- 
-=== RF Chain config === 
- 
-This configuration is mainly used to correct RSSI and TX power values. \\ 
-Corresponding calibration values are set in Production by Kerlink and extracted during board startup in ///​tmp/​calib_loraloc.json//​ file. 
- 
-Thanks to ad9361 transceiver chip. We are able to get +-0.25 dBm precision on real TX power. \\ 
-As a consequence,​ up to 32 power steps (tx_lut) are generated and calibrated in production. 
- 
-=== JSON Config === 
- 
-The JSON configuration file has been improved to simplify software by using JSON tables. \\ 
-Indeed: 
-  * The main Radio config object "​SX1301_array_conf"​ is now a table to support multiple boards 
-  * "​rf_chain_conf"​ is also a 2-objects-sized table 
-  * "​SX1301_conf"​ is a 2-objects-sized table 
-  * "​tx_lut"​ is a variable table (up to 32 objects) 
- 
-===== Radio scanning ===== 
-The radio scanner can be addressed by a serial port from host CPU. The COM port can be retreived in the platform json description file /​tmp/​sys_startup_status.json,​ modem COM port is contained inside the field “module”.“acm_path”. The modem is identified by its physical location given in the field “module”.“position”.\\ 
- 
-The command to enable an spectrum scanning is **sx1239** with the following parameters: 
-  * scan mode : need to be **fl** 
-  * number of path : need to be 1 for Lora Dual modem 
-  * start frequency in Hertz 
-  * stop frequency in Hertz 
-  * frequency step in Hertz (should be 62500) 
-  * frequency bandwith in Hertz (should be 62500) ​ 
-  * Bitrate (should be 600) 
-  * loop number, set to **0** for an infinite scanning 
- 
-Example: 
-<code bash> 
-sx1239 fl 1 863000000 870000000 62500 62500 600 0\r 
-</​code>​ 
- 
- 
-The spectrum data are returned line by line separated by a \r\n, each line correspond to a complete scan of the band. The format is ASCII and respects the following protocol: 
-<​code>​ 
-[PATH] : [DURATION] : [DATA] [FIN] 
-</​code>​ 
- 
-Where : 
-  * [PATH] : radio path number : 0 or 1 (always 0 for Lora Dual modem) 
-  * [DURATION] : duration of the scan of the full band expressed in milli-seconds coded as a decimal 
-  * [DATA] : N x data coded as hexascii between 00 and FF, it expresses the opposite of the received power (-RSSI) 
-  * [FIN] : synchro character: \r\n (0x0D 0x0A) 
- 
-Exemple 
-<​code>​ 
-0:​915:​7F7F807F80807F80807F7F7F7F7F7E7E777E7F7E7F7F807F7F7F7F80807F7F7F807F7F7F807F7F7F807F7F7F807F7F80807F7F7F7F807F807F7F7F7F807F7F7F7F807F7F7F7F7F7F7F7F7F7F80807F7F7F7F7F7F7F7F7F807F7F7F807F807F7F7F7F7F7F7F7F7F807F807F807F7F7F7F7E 
-0:​915:​7F7F8080807F7F7F7F807F7F7F7F7E7E777E7F7F7E7F7F7F807F7F807F807E807F7F7F7F7F7F7F7F7F807F7F7F7F7F80807F7F80807F807F80807F7F807F807F807F7F7F807F7F7F7F7F80807F7F7F7F7F807F7F7F80807F7F7F7F7F7F807F7F807F7F7F7F7F7F7F807F7F7F807F7F7F7F 
-0:​915:​7F807F807F7F80807F807F7F7F7F7F7E787E7E7F7F7F807F7F7F7F80808080807F7F7F7F8080807F8080807F808080807F80807F807F80807F7F7F8080807F7F807F7F80807F7F807F8080808080807F7F80807F80807F7F7F807F7F7F7F7E807F7F7F7F807F807F7F7F7F807F7F7F7F7F 
-0:​915:​7F7F807F807F7F7F7F7F7F7F807F7F7E777E7E7E7F7F7F7F7E7F7E807F8080807F7F7F7F807F7F7F80807F807F8080807F7F7F7F7F7F7F7F7F80807F7F7F7F7F807F7F80807F7F7F7F807F7F8080807F7F7F807F7F80807F7F80807F7F7F7F7F807F808080807F7F7F807F7F807F807F7E 
-0:​915:​7F807F7F807F807F7F8080807F7F7E7F777E7E7F7F7F7F80807F7F8080807F8080807F7F7F7E8080807F807F7F80807F7F807F7F807F8080807F7F7F80807F7F807F807F7F7F807F7F7F8080807F807F7F7F80807F7F7F7F7F7F807F7F7F7F807F7F7F7F7F7F80807F7F807F807F7F7F7F 
-0:​915:​7F7F807F7F7F7F7F7F7F7F7F7F7E7F7F777E7E7F7E7F7F7F807F7F7F807F808080808080807F7F7F80807F7F807F80807F7F7F7F807F807F7F8080807F7F807F807F7F7F7F7F7F7F807F7F7F807F807F80807F807F7F7F7F807F7F7F7F8080807F7F7F7F7F7F7F7F7F7F7F7F807F807F7F 
-0:​915:​7F7F7F7F807F807F80807F7F7F7F7E7E777E7E7E7F7F7F7F7F807F7F807F807F7F80808080807F80807F7F8080807F807F7F807F7F7F7F7F7F80807F7F807F7F7F7F807F807F7F7F807F7F7F80807F8080807F7F7F807F7F80807F7F7F807F807F7F7F7F80807F7F80807F7F807F7F7F7F 
-</​code>​ 
- 
-To stop a scan, simply enter CTRL-C value. 
wiki/loraloc.1476288473.txt.gz · Last modified: 2019/01/17 10:01 (external edit)