How to print text message on serial console from a shell script?

Hi
I am creating a headless image to meet our app requirements. To debug the issues, I would like to print out some text message to the serial port console Pin 3 and 4 of J50 on Carrier Board Rev B01 from my shell script?
Would you please let me know how.
Thanks

CX

Sorry for the late response, have you managed to get issue resolved or still need the support? Thanks

hello changwen.xie,

I’m not fully understand your use-case, what’s the text messages you’re going to prints?
the serial console by default prints the low-level messages, if you’re asking for user-space logs, it populates /var/log/syslog.

Hi JerryCheng,
Thank you very much for your kind reply.
syslog is very helpful for me to debug the issue of headless image I created.
“the serial console by default prints the low-level messages” it means we can’t easily use it to output the message from user’s shell script or user’s application debug message?

CX

hello changwen.xie,

that’s correct, shell script, or user’s application is user-space. that populate logs to syslog, or shows the messages to terminal.

may I know what’s the actual use-case, I meant what’s the pipeline shell script is called, are you able to access that driver?
you may modify the driver for adding debug messages, then you’ll able to output kernel level logs via serial port console.

At this moment, the syslog is enough for me.
Thanks

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.