Hi, the command "stty" is the canonical way to change the serial port parameters on Linux systems. There is a limit in the baud rates: if you use one that can't be achieved due to hardware configuration, the command assigns automatically the one that's closest to the desidered one, but is compatible with the hardware. Just for example, the ttyS0 on my tablet based on WM8650 SOC, cannot set the baud rate to 4800 BPS and if you try that, it assigns 9600, while if you try to set 19200 or 38400 it goes well. I don't know what Android version is running on your specific hardware. The example I proposed on my post, works on a tablet based on Android 2.2 (so, it's very old), but newer version have changed many and many things, diverting much more from classical Linux substrate, so may be the command "stty" has been modified or is unsupported. On a terminal, try if it's possible to get some information about the command using something like "man stty". About your question, I don't know if the file you extracted ("serialport_api.jar") can be inserted in a B4A library, the person that can give you a full answer may be Erel or some of other "gurus" of B4A. You can take a look in the jar file just to discover what part of source that handles the serial port parameters, then reproduce that behaviour with available shell commands, but this is just a suggestion. Anyway, for serial applications on modern tablets and smartphones, I actually use an USB converter (USB-RS232 or USB-RS485 or USB-TTL), that gives me full control by means of existent USB_Serial library. Note that USB-RS485 doesn't need for a control pin to set the flow direction, 'cause FTDI chips (and many others) automatically handle it. So, in order to control devices on RS485 bus you just need to send your packet on the serial port at the right moment. Hope this can help... bye