Author Topic: Bluetooth Problem On Henntges Oz 3.5.3  (Read 7279 times)

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« on: August 28, 2005, 04:52:06 pm »
I have Hentges OZ 3.5.3 and Cardfs up and running on my Z.
Now how do I get bluetooth started on OZ 3.5.3 ?

I have an LSE038 Bluecard which is recognised as soon as I put it into the Z.
However the light never goes on.
The network bnep0 cant be started.
I've tried sdp tool browse but nothing happens.

Card Details

cardctl ident

socket 0:
product info : "WSS" , "LSE039"
manfid: 0x0264, 0x0008
funtion: 6 (network)
Socket 1:
no product info available


I've checked bluetooth.conf - here's the driver for my card.

device "bluecard_cs"
  class "bluetooth" module "bluecard_cs"

card  "LSE039 Bluetooth PC Card"
     version "wss","LSE039"
bind "bluecard_cs"

I assume bluecard_cs is part of the bluetooth module - I dont see it as an opie or oz module  -can someone confirm this?

Help please!

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #1 on: August 28, 2005, 07:06:47 pm »
Ok I have my bluecard recognised in hentges oz 3.5.3.   I found an old post which showed me how to download the missing bluetooth driver from the kernel modules.

"Download http://bluez.sourceforge.net/download/zaur...18-mh14_arm.ipk

Rename it to bluez-kernel-2.4.18-mh14_arm.tar.gz and open it with winrar or winzip.
There is a bluecard_cs.o in this file. Copy it to your zaurus (lib/modules/2.4.18-rmk7-pxa3-embedix/kernel/drivers/bluetooth) and reboot.

At console use: hciconfig hci0 up"

Installing bluecard_cs.o in the kernel modules means oz now recognises my card.
Note this is obviously missing from oz!!

However I still have problems!
I do sdptool browse and the z sees my motorola phone mac address - but also says it doesnt have permission to connect to this sdp service ???

Anyway undeterred I enter my phones' mac address into rfcomm.conf.
ok I've forgotten what to do next ? (Actually i dont know with oz.!)
(I have also set "automatically bind at start up" in rfcomm)

Still cant start bnep0 service in "networks"  ....
Need some help now please!!

Also I find when I tap on the card manager icon and select "eject lse039 bluetooth card the light on the card goes on and stays on and the z hangs.
The only way out is to reboot with the switch at the back. - am I still missing some configuration somewhere???

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #2 on: August 29, 2005, 08:50:33 am »
Quote
Note this is obviously missing from oz!!

Is it not in one of the machine related ipks in the machine feed?


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

Greg2

  • Hero Member
  • *****
  • Posts: 790
    • View Profile
    • http://
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #3 on: August 29, 2005, 10:15:42 am »
Quote
Installing bluecard_cs.o in the kernel modules means oz now recognises my card.
Note this is obviously missing from oz!!
bluecard_cs.o is in the kernel-module-bluecard-cs_2.4.18-rmk7-pxa3-embedix-r18_collie.ipk in the /machine/collie feed... (as lardman has already suggested)  

Greg

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #4 on: August 29, 2005, 02:50:39 pm »
Whoops so it is!  I was looking for a file starting with bluecard_cs.o instead of kernel...

Ok have downloaded and installed driver and re-booted.

At konsole I entered   #hciconfig hci0 up

..and the card light flashed on and off..
Now I enter  #sdptool browse
and the z sees my motorola phone correctly - mac address and all.

Ok but in the sharp rom I was able to use the network applet to create a bluetooth connection via  "/device/rfcomm0" and enter a number to dial up via gprs.

How do I do this with open zaurus?

I have downloaded the bluetooth manager and bluepin applet and after using hciconf hci up at the konsole I have been able to scan and see my motorola phone.

How do I create a dialup - what do I do next??

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #5 on: August 29, 2005, 05:04:16 pm »
Ah I may be ok! I have found a very good description of how to set up bluetooth and setup a GPRS connection to a phone within the opie site.

http://opie.handhelds.org/cgi-bin/moin.cgi/BluetoothGprs

I'll give this a go first!

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #6 on: August 29, 2005, 07:35:43 pm »
Success ! I have configured bluez (rfcomm etc) and I have added a new network connection to "networks" and made a bluetooth GPRS dial up connection to the internet.

Sounds good except:

When I put the card in I have to execute this command from the konsole

/etc/init.d/bluetooth start

because bluetooth isnt being started automatically

Then I can start the network connection I've just made and I can connect to the internet ok.

I can stop the connection ok but if I try and eject the card using cardmanager th elight comes on and it locks up so I have to reboot.

To avoid this I have to enter this command from the konsole  

/etc/init.d/bluetooth stop

Hmm seems to me that bluetooth was automatically started and stopped when using bluez with the sharp rom.
How do you do this with OZ?

I have installed the bluetooth applet (it looks dark all the time) I can launch the bluetooth manager from it ok but nothing seems to happen when I try and enable bluetooth.

Nearly there.. a couple of more clues/ suggestions on how to fix this would be most welcome!!!

HeavyWeaponDude

  • Newbie
  • *
  • Posts: 37
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #7 on: September 07, 2005, 07:50:16 pm »
Would you please help me reach your same result?

I've managed to install correctly a Billionton card at kernel level.
It is correctly recognized, and if i use

Code: [Select]
setserial /dev/ttyS3 baud_base 921600
modprobe hci_uart
hciattach /dev/ttyS3 billionton
hciconfig hci0 up

the cards go up and running. I've just tried to make some "hcitool scan" with other bt peripherals around, just to test, and everything is fine.

But if i try to run:
/etc/init.d/bluetooth start

I got this error:
Starting Bluetooth subsystem: hcid sdpd Can't open HIDP control socket: No such file or directory
  hidd rfcomm.

And nothing works.
I would like to make at least /etc/init.d/bluetooth start (and stop) to work.
Otherwise, being unable to stoppping the service, every time I extract the card I need to reboot the Z to make it work again.

Thanks for any help!
« Last Edit: September 14, 2005, 09:16:31 am by HeavyWeaponDude »
Zaurus SL-5500
OpenZaurus 3.5.3 + Opie 1.2 (Hentges ROM T3)

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #8 on: September 08, 2005, 06:54:39 am »
What's hidp? I assume it's either not installed, or hasn't been created. Either install it, or edit the script to not faiol if it's not available,


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

Mickeyl

  • Hero Member
  • *****
  • Posts: 1495
    • View Profile
    • http://www.Vanille.de
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #9 on: September 08, 2005, 07:39:57 am »
Hidp is the Bluetooth Human Interface Devices Protocol (keyboards, mice, etc.) - I'm not sure if the bluez patch adds this to 2.4.18. It works fine on the Zaurii with 2.4.20 and 2.6.13.
Cheers,

Michael 'Mickey' Lauer | Embedded Linux Freelancer | www.Vanille-Media.de
Consider donating, if you like the software I contribute to.

HeavyWeaponDude

  • Newbie
  • *
  • Posts: 37
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #10 on: September 08, 2005, 07:43:41 am »
Ok, I'm getting some progress  
Basing upon Lardman suggestion and the information I got here:

https://www.oesf.org/forums/index.php?showtopic=9347&hl=hidp

about the absence of the HIDP support, I edited the script, commenting out
all the references to it.
Now the script start and stop correctly:

Code: [Select]
/etc/init.d/bluetooth start
Starting Bluetooth subsystem: hcid sdpd rfcomm

/etc/init.d/bluetooth stop
Stopping Bluetooth subsystem: pand dund rfcomm sdpd hcid

But my device is still unavaiable: "hciconfig -a" gives no output
I've tried to load hci_uart manually (modprobe hci_uart) before running the demon, since that module is required and it's not loaded upon card insertion or by running the bluetooth demon itself.
But still no luck. "hciconfig -a" still giving me a blank output.
uhm...
Zaurus SL-5500
OpenZaurus 3.5.3 + Opie 1.2 (Hentges ROM T3)

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #11 on: September 11, 2005, 07:58:19 pm »
The only way I can get a consistent bluetooth connection is if I reboot (flix battery switch to "replace battery then back to normal"
When I come up from a reboot I insert my Bluetooth card and it blinks on and off and I run my dial up script from networks ( I have a little script to check the bluecard_cs module is loaded and also runs /etc/init.d/bluetooth start for good measure in the "execute" tab. The phone ask me for the pin number to pair it and the z and I oblige - I am now connected! I can connect and reconnect many times - no problem. Then I suspend the Z and then resume.
I start the dial up from networks it runs the script the card light flashes but I just keep getting the message that its trying to initialise the modem. When I look at the phone there's no sign of anything trying to connect to it. I then have to cancel.
I can suspend and pull out the card and put it back in again. Lights flash on the card but every time I dial I cant get past the trying to initialisation modem message. Somehow when I suspend the Z something is being altered. I'am pretty sure the bluecard_cs module is loaded ok and bluetooth is being started  but it seems something has changed!!
It seem that if I want to use bluetooth I have to reboot the z everytime - suggestions anyone!!

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #12 on: September 13, 2005, 05:23:55 pm »
I have bluetooth working consistently now - even after a suspend and resume.
To do this I have to run a script via the ppp dial up I configured within the networks tab. (The "execute" tab in the ppp dial up account allows you to run a script of your choice.)
My script is as follows - call it whatever you like, but make sure you make it executable

#!/bin/sh
/sbin/rmmod bluecard_cs
/sbin/insmod /lib/modules/2.4.18-rmk7-pxa3-embedix/kernel/drivers/usb/device/bluecard_cs.o
/etc/init.d/bluetooth stop
/etc/init.d/bluetooth start
rfcomm bind all
pand --listen GW
pand --connect <your phones mac address>

First of all I make sure that the bluecard_cs module is properly loaded then I stop and start bluetooth .
I found you had to stop bluetooth when you came out of suspend otherwise bluetooth didnt initialise properly and I could get past the modem initialiastion string in the ppp dial up.
I added rfcomm bind all and the pand commands just for good measure.
Anyway I can now put my bt card in , suspend and resume and make a bluetooth connection to the phone and dial up everytime.
I dont use the card manager icon to remove the card if I want to swap in my wifi card later I just yank my bt card out wait until the message saying "ls039 card has been ejected" and plug my wifi card in. I found that if I try and click on the card manger icon to remove the card the light on my bt card comes on and stays on - worse still the Z hangs and I have to reboot!

I'am sure these problems and the usbdo modules not loading properly after a resume are all due to the suspend and resume problem and will go away when this is fixed. I have flashed to the latest zImage which has got rid of the right key press suspend problem but there's obviously still problems with suspend /resume.

The general setup for bluetooth can be found here:

http://opie.handhelds.org/cgi-bin/moin.cgi/BluetoothGprs

I also found that I had to add the "givepin" script  as per the opie bluetooth instructions above.

Hope this helps you get by with your bluetooth until suspend/resume gets fixed.

HeavyWeaponDude

  • Newbie
  • *
  • Posts: 37
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #13 on: September 14, 2005, 09:31:33 am »
First of all, many thanks for your help.  

I fear my problem is on a most basic level.
I'm not trying to setup a connection with a phone by now, but just to have the
bluetooth card running smoothly.
What I'm asking for, is if it your /etc/init.d/bluetooth script works well without any tweaking, and if it's sufficient by itself to make the bluetooth card up and running.
As I said in my previous posts, if I try to run it I get an error, and after tweaking the file I don't get the error anymore, but I'm still unable to use the card properly.
But if I use the sequence of 4 commands (setserial, modprobe, hciattach, hciconfig) everything is fine.

So, actually to make the card works you just run the script you posted, that in turns call the /etc/init.d/bluetooth script? No other tweaks?

If this kind of discussion is not of general interest maybe we can move to PM.

Thanks for your help so far!
Zaurus SL-5500
OpenZaurus 3.5.3 + Opie 1.2 (Hentges ROM T3)

Marty

  • Newbie
  • *
  • Posts: 44
    • View Profile
Bluetooth Problem On Henntges Oz 3.5.3
« Reply #14 on: September 14, 2005, 05:59:41 pm »
The only thing I altered in /etc/initid/bluetoth was that I commented out the references to HIDD which was causing the same sort of error message that you saw appeared on my  z when I ran  "/etc/init.d/bluetooth start".
Once I did that the error message went away.

I then found that when I came out of a suspend and ran "/etc/etc/init.d/bluetooth start" the light on the card flashed but... my dial up script would'nt work.
However if I ran  "/etc/init.d/bluetooth stop" then "/etc/init.d/bluetooth start" then everything would work just fine.

I've tried modprobeing the bluecard_cs driver in the past but didnt see much happening. I found the rmmod insmod of the driver to do something (at least it told me the bluecard_cs driver was already loaded.)
I know your card uses a different driver than mine but it looks like its not being loaded properly
Maybe you should try that approach instead of modprobe. (see script)
Sorry I wish I could be more help but I'am not an expert on bluetooth.