Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. [SOLVED] Qserialport in QT 5.3 running in Android !!!!
Forum Updated to NodeBB v4.3 + New Features

[SOLVED] Qserialport in QT 5.3 running in Android !!!!

Scheduled Pinned Locked Moved Mobile and Embedded
25 Posts 3 Posters 23.2k Views 1 Watching
  • 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.
  • M Offline
    M Offline
    mr_wallyit
    wrote on last edited by
    #16

    Hello,
    " JNI_OnLoad found" i see the warning in the my project.
    If you receive the bytes you can open the serial port,
    Are you sure, that are you sending the commands correctly?
    Because all device have the specific syntax, i thinks that if you can receive you can send

    I don't know how you we open the app with permission "sudo", but i have found how open by shell.

    @
    adb shell am start -n org.qtproject.example/org.qtproject.qt5.android.bindings.QtActivity

    @

    1 Reply Last reply
    0
    • P Offline
      P Offline
      projetoslinux
      wrote on last edited by
      #17

      ok thanks
      mr_wallyit

      1 Reply Last reply
      0
      • K Offline
        K Offline
        kuzulis
        Qt Champions 2020
        wrote on last edited by
        #18

        In addition, seems, there are "way":https://groups.google.com/forum/#!topic/pico-sam9g45/dNt1FJCX6ik to open the serial port with the user permissions.

        Need to setup permissions to desired serial port, e.g. do it in "init.rc" file, e.g.:

        @chmod 0666 /dev/ttyS0@

        Of course, to changing of this file required the root rights, unfortunately. But it can be done once for all non-USB serial ports "integrated" on Your device and do no worry in future.

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mr_wallyit
          wrote on last edited by
          #19

          Hi kuzulis,

          good research.

          Thanks

          1 Reply Last reply
          0
          • P Offline
            P Offline
            projetoslinux
            wrote on last edited by
            #20

            After several weeks I found out why qtserialport not run on any android

            1 - Root is necessary
            2 - Android Kernell should be compiled with the option enabled serial port, as well as some needed to install libusb and having to recompile the source code Kernell!!

            Much work!!
            Anyone know another method??

            1 Reply Last reply
            0
            • M Offline
              M Offline
              mr_wallyit
              wrote on last edited by
              #21

              Hello,

              I have tried qserialport on industrial pos (point of sales),so i thinks the kernel has enabled serial port and libusb, because i can use the serial port.

              In the Qt 5.3 we have bluetooth,
              Why Don't we use bluetooth?

              @
              http://www.brainboxes.com/product/bl-830/bluetooth-to-rs232-serial-adapter-1-port-female
              @

              I don't have tried, but i thinks that work because android uses protocol bluetooth with adapter than it convert the signal in rs232.

              What do you thinks?

              1 Reply Last reply
              0
              • P Offline
                P Offline
                projetoslinux
                wrote on last edited by
                #22

                Thanks mr_wallyit

                i testing but not have any example whit serial com over bluetooth

                looking this

                http://qt-project.org/forums/viewthread/41978/

                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  mr_wallyit
                  wrote on last edited by
                  #23

                  Dear projetoslinux,

                  if we use a adapter, the protocol between smartphone and the adapter is bluetooth, the conversation rs-232 is done by converter.

                  e.q. in qt:
                  /opt/qt/Examples/Qt-5.3/bluetooth$ ls
                  btfiletransfer
                  picturetransfer
                  scanner
                  btchat
                  btscanner
                  pingpong

                  I thinks that the pingpong is a type of communications network client - server. I like this idea but adapters bluetooth are very expensive for me, i search a economic device on ebay. I need a lot of time for try.

                  1 Reply Last reply
                  0
                  • P Offline
                    P Offline
                    projetoslinux
                    wrote on last edited by
                    #24

                    Hi mr_walyit

                    im a testing in embedded android solutions and work fine, but in my cell phone, not work, in next week i compile phone kernel. adapters is most expensive !!! and dont resolve portability
                    thanks...

                    1 Reply Last reply
                    0
                    • M Offline
                      M Offline
                      mr_wallyit
                      wrote on last edited by
                      #25

                      Hello,

                      Have you compiled Kernel?

                      My best regards

                      1 Reply Last reply
                      0

                      • Login

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • Users
                      • Groups
                      • Search
                      • Get Qt Extensions
                      • Unsolved