Jump to content


Photo

[ROM]<<<Mokee SF2>>>Link up

* * * * * 3 votes

  • Please log in to reply
88 replies to this topic

#41
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo

If this is what you hope is it poss it could be implemented in ics or only gb.
Good work


Both, but we might have to modify it a little more for ICS but that shouldn't be a problem.

  • 0
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#42
PsYcHoKiLLa

PsYcHoKiLLa

    Addict

  • Members
  • PipPipPipPipPip
  • 802 posts
  • Gender:Male
  • Devices:LG Nexus 4, Tesco Hudl
  • Twitter:@djsubterrain
Never actually use BT myself but I'm glad you seem to be getting it sorted, I know it bugged you....a lot ;)


By the way, you might want to use the centre clock addon, I can confirm it works fine. Although they have a warning "Be careful if you are using soft buttons, they can overlap and it looks ugly."

Was just looking through the apps too (was actually removing es file explorer...yuk, replaced with root explorer...yum :P), did you notice you're using the zte skate settings apk?

Edited by PsYcHoKiLLa, 13 June 2012 - 04:19 PM.

  • 0

#43
Mtman1

Mtman1

    Addict

  • Members
  • PipPipPipPipPip
  • 686 posts
  • Gender:Male
  • Devices:Liquid MT
Just wanna let you know that there is a new update for the skate (raverrr, you might want to update)

  • 0

#44
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo
logcat: http://pastebin.com/6jZbuJV9
dmesg: http://pastebin.com/B2ychSsq

Of particular note, line 151 on the logcat it clearly pulls my MAC address with the Wi-Fi being disabled. It's generally a lot more interesting than what we had in the past and is probably a simple fix.

Edit: Sorry for hijacking the thread, raverrr :P

Edit 2: Seems to complain that bluetoothd isn't up, so I'm manually running this. Before I turn on Bluetooth, I get spammed with "connect: Connection refused" in bluetoothd and:

I/DTUN_CLNT( 2124): connect_srv ret:-1 server name:brcm.bt.btlif.9000
D/DTUN_CLNT( 2124): BTLIF_MAKE_LOCAL_SERVER_NAME return name: brcm.bt.btlif.9000

In logcat. When I turn Bluetooth on however I get a really horrible crash, firstly, "Connected (9)" in bluetoothd, and after a while, the Bluetooth icon shows up in the notification area. This is short lived as the device immediately reboots, and continues to reboot until I kill bluetoothd. Sample log: http://pastebin.com/pD0ERhag

Though I actually think we've got further with this.

Edited by Dazzozo, 13 June 2012 - 05:51 PM.

  • 0
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#45
HaoRui

HaoRui

    Newbie

  • Members
  • Pip
  • 23 posts
  • Gender:Male
  • Location:china
can it work for TMW? :huh:

  • 0

#46
Metooism

Metooism

    Newbie

  • Members
  • Pip
  • 44 posts

Just checked it out on the Skate forums. Looks lovely. Can't wait to flash it onto my sis' blade 2! data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAMAAAC6V+0/AAAABGdBTUEAANbY1E9YMgAAAdRQTFRFV0AI////V0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIV0AIW0IIV0AIW0IIW0QJW0IIV0AIV0AIV0AIQzQQa0oJbEwJbVELbk4Kb0wJb1QMcVILc1cMlF8Ll2oNmXEQnn8Vo2gLpGgLpGoMpW8NpXEOp3YQq4MUrH0Rro0Xr4QUsI4XsZAYuXQNwIkSwI0VyIAOyocQyqcdy4QQzosS1Kod1rIf3ZMS3ZUT3a8c3o4Q3rcf4ZER5JUR5ZYS5ZgS5aIW55wT554U6KkZ6qQV6qUW6qYW6qcX66gW7Lsf7a0X7a0Y7a8Z7bEb7rAY7rEY7rMa7rMb77Ma77cd77oc8bob8b4f8cUh8skh870c88If88kk89Im9Mwl9cch9scf9skh9swi9swk98og988k99Mm+dMk+dYm+9cl+9gl+9kn+9on+9oo+9op+9so/Ngl/Non/Nso/N0o/N0p/eAp/eEp/uAn/uIq/uMp/uMq/uQq/+An/+En/+Eo/+Io/+Ip/+Mo/+Mp/+Mq/+Qp/+Qq/+Qr/+Uq/+Ur////QENjqgAAACd0Uk5TAAABCQoLHCYnMDY4OjuCg4WHiImKm56fx8jJys3P1Ofp6enq7/DyAdnyKAAAASJJREFUGNNjYMQCGBgZgICZi09CRUWCj4sZxIMIsgnr2ngW5HlYaQmzQQWZOOWM8xvaWuurSmOM5DiZwILsSq4NHb2zZvS015ZnOsmzgwRZxewbu9TVZ82cqa5eW5JmKcoCFOTRr2hXB4pMV582Sb0yN0ybGygoZFfXPX369GlTpkyZ3FldmGAhABSU8WuZChaZOHHihKbiFHdJoKBKdrO6OkhkYn9/n7p6srcCUFA1q0Z9tjoUzFaP9wIJyvpUqs+GA/UoN2mgoIhtMbJgqJkgUJBXL70MLqoe6a/DA3K8uHVGEVRUPTrQVIwV5E0OZcfUHIg94YEOiuywADEMjktKjI0I8TWABQgo6DTNXYICnE004EEHDmR+KTU1KX54IGMBAGd3XCYdIc62AAAAAElFTkSuQmCC

你玩LOL?LOL you play?

  • 0

#47
Metooism

Metooism

    Newbie

  • Members
  • Pip
  • 44 posts

Just checked out the Skate version, looks very nice. Very MIUI-like.

Posted Image Posted ImagePosted Image

Like!!!

  • 0

#48
raverrr

raverrr

    Recognised Ginger Ninja

  • Moderator Team
  • PipPipPipPipPipPip
  • 1,063 posts
  • Gender:Male
  • Devices:Moto G, ZTE Blate

logcat: http://pastebin.com/6jZbuJV9
dmesg: http://pastebin.com/B2ychSsq

Of particular note, line 151 on the logcat it clearly pulls my MAC address with the Wi-Fi being disabled. It's generally a lot more interesting than what we had in the past and is probably a simple fix.

Edit: Sorry for hijacking the thread, raverrr :P

Edit 2: Seems to complain that bluetoothd isn't up, so I'm manually running this. Before I turn on Bluetooth, I get spammed with "connect: Connection refused" in bluetoothd and:

I/DTUN_CLNT( 2124): connect_srv ret:-1 server name:brcm.bt.btlif.9000
D/DTUN_CLNT( 2124): BTLIF_MAKE_LOCAL_SERVER_NAME return name: brcm.bt.btlif.9000

In logcat. When I turn Bluetooth on however I get a really horrible crash, firstly, "Connected (9)" in bluetoothd, and after a while, the Bluetooth icon shows up in the notification area. This is short lived as the device immediately reboots, and continues to reboot until I kill bluetoothd. Sample log: http://pastebin.com/pD0ERhag

Though I actually think we've got further with this.

Don't mind me dude :). Hack away. :)

  • 0
-If i've been helpfull to you in any way, press that little green thanks button

#49
tilal6991

tilal6991

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,781 posts
  • Gender:Male
  • Devices:ZTE Skate, Huawei U8150
@Daz
The problem is Bluetooth is not being enabled but the system thinks it is so starts the framework service which realizes that Bluetooth is actually enabled and so crashes the system thread.

  • 0
If you like my work or if I helped, click the Plus button.

#50
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo

@Daz
The problem is Bluetooth is not being enabled but the system thinks it is so starts the framework service which realizes that Bluetooth is actually enabled and so crashes the system thread.


Odd. If I do setprop ctl.start hciattach I'm able to manipulate Bluetooth manually through hciconfig and hcitool, it seems to respond well to testmode and is able to show my MAC address and show that the device is up. I can do scans and such and nothing seems to show anything alarming. I just can't get Android to like it.

I'm playing around with ServerThread in services.jar and it's not looking good, though I'm not sure if I've gone off on an irrelevant tangent. (I'm porting over any references to broadcom, pretty much.)

Any pointers?

Edit: For what it's worth, all files that contain "broadcom" in all of the framework jars. I'd say the top... 6 (ignoring the first)? are the challenge as they already exist in CM and need to be merged.
http://pastebin.com/eEkeiJWM

Edited by Dazzozo, 14 June 2012 - 05:38 PM.

  • 0
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#51
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo
Quick update: merging smali was a bit of a failure, couldn't even get it to compile. It seems the broadcom stuff has its own BluetoothHidService and it's... not fun replacing all that, and I'm not even sure it's the solution.

I had a look at the stock ROM earlier but I couldn't get much information out of that. Just seems like we've hit a second dead end. :(

  • 0
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#52
tilal6991

tilal6991

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,781 posts
  • Gender:Male
  • Devices:ZTE Skate, Huawei U8150
TBH I don't think the problem is in the framework - even when I had bad issues with BT not enabling at all on early CM7 on the Skate the framework itself was never the issue.

  • 0
If you like my work or if I helped, click the Plus button.

#53
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo

TBH I don't think the problem is in the framework - even when I had bad issues with BT not enabling at all on early CM7 on the Skate the framework itself was never the issue.


I'll revert back to the unmodified framework.jar and keep all the btld stuff in place, and see what happens when I setprop ctl.start hciattach.

  • 0
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#54
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo
Well I never. You are indeed right.

My input:
echo 1 > /sys/class/rfkill/rfkill1/state
setprop ctl.start hciattach
bt_testmode.sh

logcat:
E/bluez_hciattach(  633): Call init_uart
E/bluez_hciattach(  633): ->bcm2035
E/bluez_hciattach(  633): read HCD file ok, size=38135
E/bluez_hciattach(  633): download hcd file success
E/bluez_hciattach(  633): bt-addr:0x0ebeccb21a68
E/bluez_hciattach(  633): Set PCM ok
E/bluez_hciattach(  633): Set sleep mode ok
E/bluez_hciattach(  633): BT chip change BaudRate to: 3000000
E/bluez_hciattach(  633): <-bcm2035
E/bluez_hciattach(  633): Device setup complete

Output:
# bt_testmode.sh
bt_testmode.sh
BCM-DUT start
< HCI Command: ogf 0x03, ocf 0x0003, plen 0
> HCI Event: 0x0e plen 4
  01 18 0C 00
< HCI Command: ogf 0x03, ocf 0x0005, plen 3
  02 00 02
> HCI Event: 0x0e plen 4
  01 03 0C 00
< HCI Command: ogf 0x03, ocf 0x001a, plen 1
  03
> HCI Event: 0x0e plen 4
  01 1A 0C 00
< HCI Command: ogf 0x06, ocf 0x0003, plen 0
> HCI Event: 0x0e plen 4
  01 03 18 00
BCM-DUT ok
# hciconfig hci0
hciconfig hci0
hci0:   Type: BR/EDR  Bus: UART
		BD Address: 0E:BE:CC:B2:1A:68  ACL MTU: 1021:8  SCO MTU: 64:1
		UP RUNNING PSCAN ISCAN
		RX bytes:380 acl:0 sco:0 events:14 errors:0
		TX bytes:65 acl:0 sco:0 commands:14 errors:0
# hcitool dev
hcitool dev
Devices:
		hci0	0E:BE:CC:B2:1A:68
#

Okay, now I'm really confused. What's stopping Android using it?

Edit: I reverted every framework file that I edited (services.jar and framework.jar)

Edited by Dazzozo, 14 June 2012 - 09:39 PM.

  • 0
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#55
tilal6991

tilal6991

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,781 posts
  • Gender:Male
  • Devices:ZTE Skate, Huawei U8150
I'm honestly lost now. No idea.

  • 0
If you like my work or if I helped, click the Plus button.

#56
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo
Going to see if I can figure out how to scan with hcitool and get it to list devices (I think you can do that with it?), just waiting for a dead BlackBerry to power up. See you in about 25 years.

Edit: Yep, it's definitely working.

# hcitool scan
hcitool scan
Scanning ...
	    33:33:CE:30:7C:30	   Retired Old BlackBerry

# hcitool info 33:33:CE:30:7C:30
hcitool info 33:33:CE:30:7C:30
Requesting information ...
	    BD Address:  33:33:CE:30:7C:30
	    Device Name: Retired Old BlackBerry
	    LMP Version: 2.1 (0x4) LMP Subversion: 0x12e9
	    Manufacturer: Cambridge Silicon Radio (10)
...

Edited by Dazzozo, 14 June 2012 - 09:59 PM.

  • 1
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#57
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo
Fixed! Android's Bluetooth is working without Wi-Fi being on on CM7. Oh my...

Incredibly simple. Leave everything as it is (including hciattach) and run "echo 1 > /sys/class/rfkill/rfkill1/state" before starting Bluetooth. Works fine.

The problem is how to do this properly. Where to run this automatically, etc.

Edit: Actually, on second thoughts, isn't bluedroid meant to do this?

Edit 2: Tried putting it in the init.qcom.bt.sh script but it doesn't seem to be actually setting the state. I don't think this is the "proper" way to fix it, either. I still think bluedroid is meant to do this and I'm puzzled as to why it doesn't.

Edited by Dazzozo, 15 June 2012 - 12:17 AM.

  • 2
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#58
Dazzozo

Dazzozo

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,309 posts
  • Gender:Male
  • Location:Shropshire, UK
  • Devices:Crescent, G300, Y300, Nexus 5
  • Twitter:@Dazzozo
Right, /sys/class/rfkill/rfkill1/state only has to be set to 1 when we want Bluetooth on with Wi-Fi off. Its value is seemingly ignored when we have Wi-Fi on. rfkill0 is controlled automatically (I assume by bluedroid), is set to 1 when it is (trying) to turn Bluetooth on, and set to 0 when it isn't. It currently has no way of knowing that rfkill1 must be set to 1 when Wi-Fi is off, though I guess we could just be safe to set it to 1 whenever we want Bluetooth on.

Edit: Going to test if the fix works on ICS (no reason why not).

Edit 2: Does indeed.

Edited by Dazzozo, 15 June 2012 - 01:41 AM.

  • 1
Like my work? Give me rep!

Like my work a lot? Donate! Remember to leave your forum name if you want to be credited!

#59
fr0do

fr0do

    Hardcore

  • Members
  • PipPipPipPipPipPip
  • 1,156 posts
  • Gender:Male
  • Devices:Huawei G300
Congrats on that dazz ;)

  • 0

Posted Image


#60
tilal6991

tilal6991

    Hardcore

  • Developer Team
  • PipPipPipPipPipPip
  • 3,781 posts
  • Gender:Male
  • Devices:ZTE Skate, Huawei U8150
So have you just set rfkill1 to 1 in init.blade2.rc?

  • 0
If you like my work or if I helped, click the Plus button.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users