Setting region on FiPy doesnt seem to work



  • Yesterday I reflashed my FiPy to use AU915 instead of EU868. It asked for the region during the flash and I selected it carefully. It had all been working on 868 MHz up to this point.

    I have a Things Network gateway working on AU915, I have my Raspberry Pi with LoRa GPS/HAT talking to it at 916.8 MHz (channel 1)

    I ran my new code using AU915
    (from 868 to 915 MHz)

    # Initialize LoRa in LORAWAN mode.
    # Please pick the region that matches where you are using the device:
    # Asia = LoRa.AS923
    # Australia = LoRa.AU915
    # Europe = LoRa.EU868
    # United States = LoRa.US915
    lora = LoRa(mode=LoRa.LORAWAN, region=LoRa.AU915)
    

    It all runs without errors. But nothing seen on my gateway, no traffic, nothing from my FiPy. As I said this was all code working perfectly on 868 MHz to a third-party commercial gateway.
    Any ideas? How can I ask the FiPy to tell me what frequency it is broadcasting on? It should be doing ABP connection on 916.8 MHz but my gateway supports all AU915 frequencies



  • Note that the code above was inside a class with a contained 'lora' object. This will work better with your code snippet:

    for index in range(0,8):
        lora.remove_channel(index)
    for index in range(16,65):
        lora.remove_channel(index)
    for index in range(65,72):
        lora.remove_channel(index)
    


  • Hi

    The AU915 channel plan sets up all 72 channels -- which means that you could be transmitting on any one of them. That wouldn't be a problem if the gateway listened on all 72, but most (all) gateways for AU915 only listen on 9.

    If you are using the latest firmware then the best way to get to just the 9, is to remove all channels that you don't need (as there is still a bug with adding the top channels). There are posts on this forum on how to get rid of channels for AU915)

    This code should remove channels 0-7, 16-64 and 65-71, leaving 8-15 and 65:

                for index in range(0,8):
                    self.lora.remove_channel(index)
                for index in range(16,65):
                    self.lora.remove_channel(index)
                for index in range(65,72):
                    self.lora.remove_channel(index)
    

    As these are the only channels that an AU915 TTN gateway listens on, your transmissions should be heard.


Log in to reply
 

Pycom on Twitter