BarryW Active Member Licensed User Longtime User Aug 10, 2018 #1 Trying to serial.ListPorts in Linux but no success. Any advice?
Erel B4X founder Staff member Licensed User Longtime User Aug 10, 2018 #2 Should we guess what no success means? Upvote 0
BarryW Active Member Licensed User Longtime User Aug 10, 2018 #3 Here is my code. Code: Copy Sub Process_Globals Dim serial As Serial End Sub Sub AppStart (Args() As String) serial.Initialize("") For Each port As String In serial.ListPorts Log(port) Next End Sub No logs has been printed. I used "java -jar app.java" in Linux Upvote 0
Here is my code. Code: Copy Sub Process_Globals Dim serial As Serial End Sub Sub AppStart (Args() As String) serial.Initialize("") For Each port As String In serial.ListPorts Log(port) Next End Sub No logs has been printed. I used "java -jar app.java" in Linux
OliverA Expert Licensed User Longtime User Aug 10, 2018 #4 You may need to run the app as root. If that works and you don't want to run your app as root just to get to the serial ports, you need to add your user to the appropriate group (which may be distro specific). Edit: See https://www.b4x.com/android/forum/threads/serial-in-linux.84714/#post-536563 Upvote 0
You may need to run the app as root. If that works and you don't want to run your app as root just to get to the serial ports, you need to add your user to the appropriate group (which may be distro specific). Edit: See https://www.b4x.com/android/forum/threads/serial-in-linux.84714/#post-536563