Home Forums Hardware GPIO Numbering

Viewing 4 reply threads
  • Author
    Posts
    • mathewgrabaumathewgrabau
      Participant
      Post count: 9

      Can you confirm the GPIO assignments for the MPU-MCU pins are GPIO27 and GPIO17 on FlexCase G?

      I have exported those via sysfs, but they are not reading anything from the MCU.

    • ConnorConnor
      Keymaster
      Post count: 35

      Hi Mathew,

      You are likely using a Radxa MPU rather than a Raspberry Pi, and the pins you mention are for Raspberry Pi. I will update the FlexCase G datasheet to be more clear on that distinction.

      There is a script “/usr/local/FLXdevice.py” included on your MPU that indicates your pin mappings, and also includes a driver that uses the popular python GPIO syntax so you don’t have to directly import/export from the filesystem. This driver is also used by the modem control scripts so it shouldn’t be moved from the default location.

      • mathewgrabaumathewgrabau
        Participant
        Post count: 9

        Hi Connor,

        Thank you for the clarification. I appreciate it. I was using the sysfs to do some testing/debugging.

        Kind regards,
        Mathew

    • mathewgrabaumathewgrabau
      Participant
      Post count: 9

      Hi Connor,

      The script is not present in my unit. That one and several of them in /usr/local are only .pyc files.

      Thanks,
      Mathew

    • ConnorConnor
      Keymaster
      Post count: 35

      Hi Mathew,

      The attached script has basic examples for reading/writing GPIO pins using the .pyc driver files. The only functions you’ll likely need are setup(pin, mode) , input(pin) , and output(pin, level), since the other setup functions are dummy functions for compatibility with raspi libraries.

      Please follow up if you have questions about specific functions, or if the script isn’t downloading correctly.

      • This reply was modified 2 weeks, 5 days ago by ConnorConnor.
      Attachments:
      You must be logged in to view attached files.
    • mathewgrabaumathewgrabau
      Participant
      Post count: 9

      Thanks for the excellent information, Connor. That was very helpful.

Viewing 4 reply threads
  • You must be logged in to reply to this topic.