Knowledge Base
HOME » KNOWLEDGE BASE » FORUM

Custom SX1301 Gateway with libloragw - Calibration Firmware Not Expected

Hello,

I am trying to build a custom SX1301 gateway with an ARM Cortex M7 microcontroller by integrating libloragw into my source code.

I have managed to pass "test_loragw_spi" and "test_loragw_reg". However, when I ran "test_loragw_hal", the following error output showed:

lgw_connect:534: INFO: no FPGA detected or version not supported (v4)
lgw_connect:572: Note: success connecting the concentrator. SX1301 Version 103
lgw_setup_sx125x:407: Note: SX125x #0 version register returned 0x21
lgw_setup_sx125x:415: Note: SX125x #0 clock output disabled
lgw_setup_sx125x:469: Note: SX125x #0 PLL start (attempt 1)
lgw_setup_sx125x:407: Note: SX125x #1 version register returned 0x21
lgw_setup_sx125x:412: Note: SX125x #1 clock output enabled
lgw_setup_sx125x:469: Note: SX125x #1 PLL start (attempt 1)
ERROR: SPI ERROR DURING REGISTER BURST READ
ERROR: Failed to load fw 1
ERROR: Version of calibration firmware not expected, actual:185 expected:2
*** Impossible to start concentrator ***

Does anyone have any idea what is wrong? I am using the the three .var files from here https://github.com/Lora-net/lora_gateway/tree/master/libloragw/src

Thank you in advance!
Solved. Problem was in SPI. Solved by comparing the SPI traffic byte by byte with an Rpi based gateway
Was this then a software bug of comparing int rather than byte?