Welcome to the Pycom forum Forum
    • \[\[global:header.categories\]\]
    • \[\[global:header.recent\]\]
    • \[\[global:header.tags\]\]
    • \[\[global:header.popular\]\]
    • Login

    Explore Pybytes | Official Documentation | Report a Firmware Bug/Issue | GitHub

    Setting region on FiPy doesnt seem to work

    Scheduled Pinned Locked Moved FiPy
    lora au915
    3 Posts 2 Posters 698 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S Offline
      smbunn
      last edited by

      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

      1 Reply Last reply Reply Quote 0
      • B Offline
        bed
        last edited by

        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.

        1 Reply Last reply Reply Quote 1
        • B Offline
          bed
          last edited by

          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)
          
          1 Reply Last reply Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • 1 / 1
          • First post
            Last post

          Pycom on Twitter

          Pycom