* [Bluez-devel] simultaneous read/write on SCO channel @ 2007-07-27 7:55 Irakli Tsagareli 2007-07-27 17:10 ` Andreas Kemnade 0 siblings, 1 reply; 3+ messages in thread From: Irakli Tsagareli @ 2007-07-27 7:55 UTC (permalink / raw) To: BlueZ development [-- Attachment #1: Type: text/html, Size: 5579 bytes --] [-- Attachment #2: Type: text/plain, Size: 315 bytes --] ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ [-- Attachment #3: Type: text/plain, Size: 164 bytes --] _______________________________________________ Bluez-devel mailing list Bluez-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bluez-devel ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Bluez-devel] simultaneous read/write on SCO channel 2007-07-27 7:55 [Bluez-devel] simultaneous read/write on SCO channel Irakli Tsagareli @ 2007-07-27 17:10 ` Andreas Kemnade 2007-07-30 8:07 ` Irakli Tsagareli 0 siblings, 1 reply; 3+ messages in thread From: Andreas Kemnade @ 2007-07-27 17:10 UTC (permalink / raw) To: BlueZ development On Fri, 27 Jul 2007 11:55:29 +0400 Irakli Tsagareli <itsagareli@yandex.ru> wrote: > Hi all, > > I'm writing a small code to test HandsFree capabilities between my phone and PC. everything works fine for audio playback (on the PC, I can hear sound file played on the phone and in case of incoming call, I can hear a voice of remote subscriber) but when I try at the same time to send some audio data to the handset via same socket, send() function returns "Invalid argument" error. I tried to create new socket for writing (same way I created listening socket). creation succeeds, but connect fails with "Device or resource busy". can anybody be so kind and explain, how can I read and write data through SCO channel simultaneously ? [...] > read(snd_fd, buffer, 48); > if(send(cli_scosock, buffer, 48, 0) < 0) << --- send() fails here with "Invalid argument" > { > perror("send failed"); > } I remember having trouble with sco and hardcoded packet sizes (try 64). sometimes it's 64 and sometimes 48 if I remember correctly. yout should do struct sco_options opts; int size=sizeof(opts); getsockopt(cli_scosock,SOL_SCO,SCO_OPTIONS,&opts,&size); once somewhere and then use opts.mtu Greetings Andreas Kemnade ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Bluez-devel mailing list Bluez-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bluez-devel ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Bluez-devel] simultaneous read/write on SCO channel 2007-07-27 17:10 ` Andreas Kemnade @ 2007-07-30 8:07 ` Irakli Tsagareli 0 siblings, 0 replies; 3+ messages in thread From: Irakli Tsagareli @ 2007-07-30 8:07 UTC (permalink / raw) To: Andreas Kemnade; +Cc: BlueZ development [-- Attachment #1: Type: text/html, Size: 2394 bytes --] [-- Attachment #2: Type: text/plain, Size: 315 bytes --] ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ [-- Attachment #3: Type: text/plain, Size: 164 bytes --] _______________________________________________ Bluez-devel mailing list Bluez-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bluez-devel ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-07-30 8:07 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2007-07-27 7:55 [Bluez-devel] simultaneous read/write on SCO channel Irakli Tsagareli 2007-07-27 17:10 ` Andreas Kemnade 2007-07-30 8:07 ` Irakli Tsagareli
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox