LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-03-2015, 12:51 AM   #1
ohamoha
LQ Newbie
 
Registered: May 2015
Posts: 7

Rep: Reputation: Disabled
Bluetooth - unsolicited AT command sent to client


When connecting to a Bluetooth serial port from Ubuntu:

adi@Poppy:~$ sudo rfcomm -r connect 0
Connected /dev/rfcomm0 to 1C:3E:84:FE:4F:69 on channel 8
Press CTRL-C for hangup


on the client side I receive the following data which is automatically sent from Ubuntu on connect:

41 54 5e 53 51 50 4f 52 54 3f 0d 41 54 0d 41 54 0d 41 54 0d 7e 00 78 f0 7e 7e 00 78 f0 7e

AT^SQPORT?
AT
AT
AT
~


This interferes with what I want to do so I need to prevent Ubuntu from sending any unsolicited data to the client.

Thanks.

Last edited by ohamoha; 08-03-2015 at 01:42 AM.
 
Old 08-03-2015, 07:17 AM   #2
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,813
Blog Entries: 13

Rep: Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875
I'm assuming your /etc/bluetooth configuration directory files are all defaults? There should be an rfcomm.conf file in there.

Otherwise, I'm unsure what the problem is, if it's not some odd configuration set up in that file.
 
Old 08-03-2015, 07:31 AM   #3
ohamoha
LQ Newbie
 
Registered: May 2015
Posts: 7

Original Poster
Rep: Reputation: Disabled
Of course rfcomm.conf file exists and it has the classic configuration since the connection is successfully created and I can exchange packets.
My problem is that immediately after the connection is done, Ubuntu(15) sends that data through serial channel and confuses the client (which expects a specific protocol).
My guess is that rfcomm is doing some modem negotiation on initialization or there is some service in Ubuntu who does that, but I have no idea how to investigate this.

rfcomm0 {
bind no;
device 1C:3E:84:FE:4F:69;
channel 8;
comment "Serial Port";
}
 
Old 08-03-2015, 07:43 AM   #4
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,813
Blog Entries: 13

Rep: Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875Reputation: 4875
You're running SPP? I'm assuming that PPP is not involved with this. I'd default assume that anyways, but wondering. Seems more like wvdial or ppp is sending AT commands to establish a call of some type.
 
Old 08-03-2015, 07:48 AM   #5
ohamoha
LQ Newbie
 
Registered: May 2015
Posts: 7

Original Poster
Rep: Reputation: Disabled
Yes, it's SPP. Hmm, I never came across wvdial or ppp so I don't know how they can be involved. I'll have to try to disable them and see what happens.

LE
wvdial and ppp are not installed.

Last edited by ohamoha; 08-03-2015 at 10:20 AM.
 
Old 08-03-2015, 11:59 AM   #6
ohamoha
LQ Newbie
 
Registered: May 2015
Posts: 7

Original Poster
Rep: Reputation: Disabled
Thumbs up Solved

After connecting to a port, minicom can function only with root(and that confused me). For any other user I get:

adi@Poppy:~$ minicom -D /dev/rfcomm1
minicom: cannot open /dev/rfcomm1: Device or resource busy

adi@Poppy:~$ ls -lsa /dev/rfcomm1
0 crw-rw-rw- 1 root dialout 216, 1 aug 3 19:46 /dev/rfcomm1


So I did this:

adi@Poppy:~$ sudo fuser /dev/rfcomm1
[sudo] password for adi:
/dev/rfcomm1: 696

adi@Poppy:~$ ps -p 696
PID TTY TIME CMD
696 ? 00:00:00 ModemManager


Aha, got you!

After killing the process, what do you think? No AT commands on connect.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Unsolicited Bulk Email - Sendmail SMTP manutdfan1988 Linux - Security 2 02-09-2011 09:02 AM
Amavis and Unsolicited Bulk Email i_nomad Linux - Server 2 03-22-2010 09:49 AM
Unsolicited Reboot dakota rob Solaris / OpenSolaris 3 11-08-2004 03:01 PM
Unsolicited Packets mrweirdo Linux - Security 1 04-08-2004 02:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration