We are using imx6q-sdb with oreo
how to create and include serial port details on android apk, when we press the apk option that information should send to the serial port(ttymxc0 or ttymxc2 or ttymxc3) console.
Unfortunately, creating the implementation of Android apps is out of our scope of support.
However, you could use the following java command to execute shell commands and then perform the serial connection as it should be in a Linux terminal. However, this is a suggestion, we cannot guarantee if this will work.
Process process = Runtime.getRuntime().exec(command); //Where command, is the Linux command that you are willing to execute I apologize for the inconvenience this may give you. Best regards, Diego.