🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Cant use GPS and LTE module at the same time

    General
    2
    5
    3.0k
    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.
    • J
      jkeyser
      last edited by jkeyser

      I have these 2 modules along with the core 2. The LTE module is on pins 14/13, and the gps is on 1/3. LTE module is being powered externally.
      https://shop.m5stack.com/products/gps-module
      https://shop.m5stack.com/collections/m5-modules/products/com-lte-modulesim7600g?variant=35800524488868

      When used separately, everything works fine, but when using both at the same time i get this error as soon as i try to initialize them.

      File "<string>", line 35, in <module>
      File "comx/lte.py, line 27, in __init__
      File "libs/simcom/common.py", line 164, in ...
      IndexError: list index out of range
      
      1 Reply Last reply Reply Quote 0
      • felmueF
        felmue
        last edited by

        Hello @jkeyser

        have you tried to set the GPS module to use GPIOs 5/13 which translates to GPIOs 33 and 19 for M5Core2? (There is a table here (see Pinmap) for the translation.)

        Thanks
        Felix

        GPIO translation table M5Stack / M5Core2
        Information about various M5Stack products.
        Code examples

        J 1 Reply Last reply Reply Quote 0
        • J
          jkeyser @felmue
          last edited by

          @felmue
          just tried, but the same thing happened.

          One thing i did notice was if i initialize the LTE modem first, i dont get the index out of range error, but only the gps works. All the modem status checks such as get_single_quality() get_network_registration() return false as if it isnt even there.

          1 Reply Last reply Reply Quote 0
          • felmueF
            felmue
            last edited by

            Hello @jkeyser

            hmm, I wonder if the code internally uses the same Serial for both devices hence the device which is initialized last 'wins'?

            Thanks
            Felix

            GPIO translation table M5Stack / M5Core2
            Information about various M5Stack products.
            Code examples

            1 Reply Last reply Reply Quote 0
            • felmueF
              felmue
              last edited by

              Hello @jkeyser

              BTW: the LTE modem SIM7600G also has a GPS, but you need to add an antenna.

              Thanks
              Felix

              GPIO translation table M5Stack / M5Core2
              Information about various M5Stack products.
              Code examples

              1 Reply Last reply Reply Quote 0
              • First post
                Last post