The problem comes from that I have to send data via bluetooth serial port from a tiny robot to my laptop at baudrate 115200, robot sends 32-bytes packet every 10ms (100 times per second). Transmission works only a few seconds, and then cat shows nothing. When I decrease frequency to 10 times per second it works smoothly. I suppose that bluetooth serial port rx buffer overflows.

Getting status of serial ports (ttyS*) via terminal is simple:

sudo cat /proc/tty/driver/serial

Then it shows serinfo with list of all uarts and info about status and buffers. When I call

sudo cat /proc/tty/drivers

I can see that rfcomm drivers are available:

rfcomm   /dev/rfcomm   216 0-255 serial

And, of course, reading data coming from paired bluetooth device (e.g. via cat or pipe) is not a problem.

The question is: how to get status of rfcomm serial ports (e.g. Blueotooth SPP devices), especially amount of data in rx/tx buffers? Is this information available somewhere in the /proc directory like for ttyS* or could I use totally different way?

  • Welcome to Ask Ubuntu. ;-) That is so development-related that I'm afraid you'll be better off asking that at stackoverflow.com a sister site to Ask Ubuntu... :(
    – Fabby
    Mar 19, 2015 at 20:53
  • Heh, actually I've asked very similar question on stackoverflow. I hadn't got helpful answers but the same suggestion - to ask on another stack site concerning linux related problems :D Mar 20, 2015 at 21:23


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy