2.6.29?
Ok then forget what I mentioned about BT subsystem creating an rfkill.

So all you need is the 2.6.29's rfkill driver.
You can find it at drivers/misc/ of the kernel/omap project under 2.6.29
branch on git.source.android.com

well rfkill is VERY necessary for BT chips which need to be powered on by
the apps processor.
in you usb case, it might be always ON.. but same is not the case with most
UART BT chips.. which is more frequent on an embedded system.

So you can go ahead and remove off the rfkill toggling in bluedroid or write
yourself a "fake" driver ...

(USB BT is more often used in the PC/laptop category)

On Fri, Oct 8, 2010 at 11:16 AM, MikeS <mstic...@gmail.com> wrote:

> I'm running 2.6.29 ... maybe that is part of the issue?
> Also, is timing important?  I start the hcid manually after boot.  But
> shouldn't this create the rfkill/hci0 entry then?  And does the USB device
> have to be powered up and ready when hcid starts, or can it be connected
> later?
>
> I'm not sure why an rfkill driver is necessary when the external board
> cannot be powered on or off by the processor anyway.  Does one just write
> something that returns "done" immediately when asked to power on or off?
>
> Thanks.    Mike
>
>
> On Fri, Oct 8, 2010 at 11:03 AM, Pavan Savoy <pavan.sa...@gmail.com>wrote:
>
>> wow.. this is confusing..
>> actually the HCI core or BT subsystem should have created an rfkill entry
>> for you.
>>
>> note that this has nothing to do with the rfkill entry which is required
>> for bluedroid to turn on BT from the UI !!!
>>
>> so on a generic system... where on android BT works from UI you should
>> see...
>> 2 rfkill entries. 1 named hci0 and another named after the manufacturer..
>> (or whatever you like.. since you write it...)
>>
>> any case so which kernel version are you using? this rfkill mess came in
>> on/after 2.6.32...
>> you can have a look @
>> net/bluetooth/ --> and grep for rfkill to look who creates rfkill entries.
>> also you will have to write your own rfkill driver, there is no escaping
>> that !!
>>
>> you might choose to ignore the values and all, but entry should exist for
>> it to turn ON from UI. this you can look up on android FS code @
>> system/bluetooth/bluedroid/
>>
>>
>>
>> On Fri, Oct 8, 2010 at 10:57 AM, MikeS <mstic...@gmail.com> wrote:
>>
>>> I think it is working from the console.
>>> For example:
>>> # hciconfig -a
>>> hci0:   Type: USB
>>>         BD Address: 00:07:80:93:84:47 ACL MTU: 310:10 SCO MTU: 64:8
>>>         UP RUNNING PSCAN
>>>         RX bytes:978 acl:0 sco:0 events:29 errors:0
>>>         TX bytes:605 acl:0 sco:0 commands:29 errors:0
>>>         Features: 0xff 0xff 0x8f 0xfe 0x9b 0xff 0x59 0x83
>>>         Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
>>>         Link policy: RSWITCH HOLD SNIFF PARK
>>>         Link mode: SLAVE ACCEPT
>>>         Name: 'beagleboard'
>>>         Class: 0x40020c
>>>         Service Classes: Telephony
>>>         Device Class: Phone, Smart phone
>>>         HCI Ver: 2.1 (0x4) HCI Rev: 0x13e2 LMP Ver: 2.1 (0x4) LMP Subver:
>>> 0x13e2
>>>         Manufacturer: Cambridge Silicon Radio (10)
>>>
>>> And if I turn Bluetooth on in my phone and do an   hcitool scan    if
>>> finds the phone
>>> # hcitool scan
>>> Scanning ...
>>>         00:23:AF:4D:xx:xx       Motorola Phone
>>>
>>> Still nothing in /sys/class/rfkill
>>>
>>> Any suggestions on where to look?
>>>
>>> Thanks much for your help.
>>> Mike
>>>
>>>
>>> On Fri, Oct 8, 2010 at 10:05 AM, Pavan Savoy <pavan.sa...@gmail.com>wrote:
>>>
>>>> Well you have to write one.
>>>>
>>>>
>>>> http://android.git.kernel.org/?p=kernel/omap.git;a=blob;f=drivers/misc/wl127x-rfkill.c;h=bc47ed43dc7cf8e66332d331266a756e8e711ebb;hb=refs/heads/android-omap-2.6.32
>>>>
>>>> can be your reference.
>>>> With this sort of a driver you will get entries under /sys/class/rfkill/
>>>> also did you first try it out from a console, just to make sure your
>>>> usb-BT device works?
>>>>
>>>> because if that had worked you would have got atleast 1 entry under
>>>> rfkill/ directory from hci core BT sub-system in kernel.
>>>>
>>>> On Fri, Oct 8, 2010 at 10:12 AM, ms12 <mstic...@gmail.com> wrote:
>>>>
>>>>> I found out how to get rfkill enabled in kernel, but there are no
>>>>> directories under it, just /sys/class/rfkill.  Symptoms still the
>>>>> same, bluetooth blinks on and off immediately when trying to enable
>>>>> it.  This thread
>>>>>
>>>>>
>>>>> http://groups.google.com/group/android-porting/browse_thread/thread/c37f87e81f63e7cc/32ef5a457e2eeef7?lnk=gst&q=problem+when+trying+to+on+bluetooth+under+beagleboard#32ef5a457e2eeef7
>>>>>
>>>>> suggests you need some drivers for the wl127x chip from TI, but this
>>>>> is device is not a WL127x chip, it is an external eval board connected
>>>>> via USB.
>>>>>
>>>>> Is there a way to get this to work?
>>>>>
>>>>> Thanks,
>>>>> Mike
>>>>>
>>>>>
>>>>> On Oct 7, 11:30 am, ms12 <mstic...@gmail.com> wrote:
>>>>> > Using Android 1.6 Donut
>>>>> >
>>>>> > I have the device (Bluegiga WT11, based on CSR Bluecore I believe)
>>>>> > connected via usb hub to beagle board. I don't have a tty that I can
>>>>> > spare.  I have started hcid, hciconfig shows hci0 up, and I can
>>>>> > communicate with the device to read feature, etc.  So I believe it is
>>>>> > basically working at the console level.
>>>>> >
>>>>> > But if I try to enable Bluetooth via the Android settings on the
>>>>> > touchscreen, it briefly blinks on then off.  The logcat shows
>>>>> >
>>>>> > D/BluetoothDeviceService(  907): Bluetooth state 0 -> 1
>>>>> > D/BluetoothDeviceService(  907): Bluetooth state 1 -> 0
>>>>> >
>>>>> > which seems to mean it tries to turn on but goes right back off.
>>>>> >
>>>>> > Is there a way to get this to work, or will it only work thru a tty
>>>>> > that is hciattach'd ?
>>>>> >
>>>>> > Mike
>>>>>
>>>>> --
>>>>> unsubscribe: 
>>>>> android-porting+unsubscr...@googlegroups.com<android-porting%2bunsubscr...@googlegroups.com>
>>>>> website: http://groups.google.com/group/android-porting
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --Pavan Savoy
>>>>
>>>>
>>>
>>
>>
>> --
>> --Pavan Savoy
>>
>>
>


-- 
--Pavan Savoy

-- 
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-porting

Reply via email to