Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Unsolved Deploy wiringpi libraries while cross compiling

    Mobile and Embedded
    4
    4
    575
    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.
    • G
      grk3010 last edited by

      Has anyone had any luck deploying wiringpi or similar libaries during cross compiling to a rpi3?

      I've been doing some experimentation (successfully) with controlling the GPIO pins using direct register access by just defining a new "mmapGpio" class using modified code from here:
      http://www.hertaville.com/rpimmapgpio.html

      I am deploying this on a lightweight embedded linux image on rpi3 that does not have the wiringpi libraries installed. This approach is working fine, but where I am running into problems is when I try to incorporate additional features such as interrupts and integrating analog i/o cards. This is where I need to use the wiringpi or similar libraries.

      Do I need to build or find an embedded linux image that includes the wiringpi libraries. Or is there any other way to accomplish this or deploy the libraries during cross compile?

      1 Reply Last reply Reply Quote 0
      • SGaist
        SGaist Lifetime Qt Champion last edited by

        Hi,

        Cross-compilation and deployment are two different things.

        The best thing is usually get the library with the distribution/image whatever you use for your target as it’s ready to use.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply Reply Quote 1
        • S
          sukoon last edited by

          Hi @grk3010 ,
          Did you find a way to include wiring Pi library in your linux image?
          I'm using a RPi4 with an ubuntu 18.04 server image installed on it, and want to use the wiring Pi to access the GPIOs instead of using sysfs(this uses more overhead). Can you please share resources to help me set up wiringPi on this system. Thanks!

          jsulm 1 Reply Last reply Reply Quote 0
          • jsulm
            jsulm Lifetime Qt Champion @sukoon last edited by

            @sukoon Install libwiringpi2 and libwiringpi-dev on your RPi using apt and then sync your sysroot.

            https://forum.qt.io/topic/113070/qt-code-of-conduct

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