summaryrefslogtreecommitdiff
path: root/recipes-connectivity/lora/lora-gateway
diff options
context:
space:
mode:
authorJesse Gilles <jgilles@multitech.com>2015-05-22 14:47:15 -0500
committerJesse Gilles <jgilles@multitech.com>2015-05-22 14:47:15 -0500
commitbfd5846c53d528c16a875f5b2469e1d29381763e (patch)
tree8182631bb580d0a05c05624b7e8a736f4ec983c6 /recipes-connectivity/lora/lora-gateway
parent2fe4b3bfcaef7164f8890d4eec58450e7271b639 (diff)
downloadmeta-mlinux-bfd5846c53d528c16a875f5b2469e1d29381763e.tar.gz
meta-mlinux-bfd5846c53d528c16a875f5b2469e1d29381763e.tar.bz2
meta-mlinux-bfd5846c53d528c16a875f5b2469e1d29381763e.zip
add recipes for initial LoRa support for MTAC-LORA
Diffstat (limited to 'recipes-connectivity/lora/lora-gateway')
-rw-r--r--recipes-connectivity/lora/lora-gateway/library.cfg73
-rw-r--r--recipes-connectivity/lora/lora-gateway/lora-gateway-debug.patch13
2 files changed, 86 insertions, 0 deletions
diff --git a/recipes-connectivity/lora/lora-gateway/library.cfg b/recipes-connectivity/lora/lora-gateway/library.cfg
new file mode 100644
index 0000000..01b066d
--- /dev/null
+++ b/recipes-connectivity/lora/lora-gateway/library.cfg
@@ -0,0 +1,73 @@
+# That file will be included in the Makefile files that have hardware dependencies
+
+### SPI interface to the concentrator ###
+# Accepted values:
+# native Linux native SPI driver (/dev/spidev32766.0)
+# ftdi FTDI SPI-over-USB bridge using libmpsse/libftdi/libusb
+
+CFG_SPI= ftdi
+CFG_SPI_DEV = "/dev/spidev32766.2"
+
+### Concentrator chip ###
+# Accepted values:
+# sx1301 Semtech SX1301 production chip
+# fpga1301 FPGA containing the SX1301 IP
+
+CFG_CHIP= sx1301
+
+### Radio chip(s) ###
+# Accepted values:
+# sx1257 Dual SX1257 transceivers, covering 860-1000 MHz
+# sx1255 Dual SX1255 transceivers, covering 400-510 MHz
+
+CFG_RADIO= sx1257
+
+### RF band configuration ###
+# Used to configured frequency restrictions (eg. if a SAW filter is installed)
+# Accepted values:
+# full Full range supported by the radio(s)
+# eu868 ETSI 868 (866) MHz band
+# us915 FCC 915 MHz band
+# cn470 China 470 MHz band
+# eu433 ETSI 433 MHz band
+# cn780 China 780 MHz band
+
+CFG_BAND= full
+
+### Board misc parameters & calibration ###
+# Used to configure misc board options.
+# RX RSSI indication and TX power are highly dependant on radio, band, filter
+# and RF front-ends, and must be calibrated for each new board design.
+# Available calibration parameters:
+# dev_nano_868 FPGA-based nano-concentrator, with 868 MHz SAW filter
+# ref_1301_868 SX1301 reference board with SX1257 radios, 868 MHz filters
+# ref_1301_433 SX1301 reference board with SX1255 radios, 433 MHz filters
+# kerlink_868 Kerlink LoRa 868MHz gateway
+# kerlink_433 Kerlink LoRa 433MHz gateway
+# cisco_433 Cisco LoRa 433MHz gateway
+# cisco_470 Cisco LoRa 470MHz gateway
+# cisco_780 Cisco LoRa 780MHz gateway
+# Keep empty for no calibration parameters (neutral values will be used).
+
+# MTAC-LORA 900MHz
+CFG_BRD= mtaclora
+
+### Network Type ###
+# Accepted values:
+# private Default
+# lora_mac Only compliant with devices running LoRa MAC
+
+CFG_NET= private
+
+### Debug options ###
+# Set the DEBUG_* to 1 to activate debug mode in individual modules.
+# Warning: that makes the module *very verbose*, do not use for production
+
+DEBUG_AUX= 0
+DEBUG_SPI= 0
+DEBUG_REG= 0
+# jjg - turning this on is useful to get HAL-related error messages that
+# don't print out otherwise. It doesn't seem to add that much printing
+# under normal operation.
+DEBUG_HAL= 1
+DEBUG_GPS= 0
diff --git a/recipes-connectivity/lora/lora-gateway/lora-gateway-debug.patch b/recipes-connectivity/lora/lora-gateway/lora-gateway-debug.patch
new file mode 100644
index 0000000..dba4392
--- /dev/null
+++ b/recipes-connectivity/lora/lora-gateway/lora-gateway-debug.patch
@@ -0,0 +1,13 @@
+Index: git/libloragw/src/loragw_hal.c
+===================================================================
+--- git.orig/libloragw/src/loragw_hal.c 2014-12-16 16:07:20.812506157 -0600
++++ git/libloragw/src/loragw_hal.c 2014-12-16 16:18:34.427454833 -0600
+@@ -1626,6 +1626,8 @@
+ break;
+ }
+ }
++
++ DEBUG_PRINTF("DEBUG: Tx pow_index %d, rf_power %d\n", pow_index, tx_pow_table[pow_index].rf_power);
+
+ /* loading TX imbalance correction */
+ target_mix_gain = tx_pow_table[pow_index].mix_gain;