Closed Bug 946240 Opened 11 years ago Closed 11 years ago

[Bluetooth][gonk-kk] [bluedroid]Porting bluetooth module

Categories

(Firefox OS Graveyard :: Bluetooth, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(blocking-b2g:1.4+, firefox28 wontfix, firefox29 fixed, b2g-v1.4 fixed)

RESOLVED FIXED
1.3 C2/1.4 S2(17jan)
blocking-b2g 1.4+
Tracking Status
firefox28 --- wontfix
firefox29 --- fixed
b2g-v1.4 --- fixed

People

(Reporter: seinlin, Assigned: shawnjohnjr)

References

Details

(Whiteboard: [qa-])

Attachments

(1 file, 2 obsolete files)

Bluetooth module is complied failed in gonk-kk.
Blocks: gonk-kk
Assignee: nobody → shuang
Summary: [Bluetooth][gonk-kk] Porting bluetooth module → [Bluetooth][gonk-kk] [bluedroid]Porting bluetooth module
A few build errors: BluetoothDeviceEventBinding.cpp:156:16: error: invalid use of incomplete type 'class mozilla::dom::BluetoothDeviceEvent' ../../dist/include/mozilla/dom/BluetoothDeviceEventBinding.h:17:7: error: forward declaration of 'class mozilla::dom::BluetoothDeviceEvent' BluetoothDiscoveryStateChangedEventBinding.cpp:166:16: error: invalid use of incomplete type 'class mozilla::dom::BluetoothDiscoveryStateChangedEvent' ../../dist/include/mozilla/dom/BluetoothStatusChangedEventBinding.h:15:7: error: forward declaration of 'class mozilla::dom::BluetoothStatusChangedEvent' They are all webidl related.
It looks like js/xpconnect/src/event_impl_gen.conf.in, MOZ_B2G_BT was not defined.
Build errors in AVRCP HAL, we need to add one callback in the front of callback btrc_remote_features_callback. Since AVRCP HAL API changed in kitkat. ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)()' to 'btrc_remote_features_callback {aka void (*)(bt_bdaddr_t*, btrc_remote_features_t)}' [-fpermissive] ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)(btrc_player_attr_t)' to 'btrc_list_player_app_attr_callback {aka void (*)()}' [-fpermissive] ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)(uint8_t, btrc_player_attr_t*) {aka void (*)(unsigned char, btrc_player_attr_t*)}' to 'btrc_list_player_app_values_callback {aka void (*)(btrc_player_attr_t)}' [-fpermissive] ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)(uint8_t, uint8_t, uint8_t*) {aka void (*)(unsigned char, unsigned char, unsigned char*)}' to 'btrc_get_player_app_attrs_text_callback {aka void (*)(unsigned char, btrc_player_attr_t*)}' [-fpermissive] ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)(btrc_player_settings_t*)' to 'btrc_get_player_app_values_text_callback {aka void (*)(unsigned char, unsigned char, unsigned char*)}' [-fpermissive] ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)(uint8_t, btrc_media_attr_t*) {aka void (*)(unsigned char, btrc_media_attr_t*)}' to 'btrc_set_player_app_value_callback {aka void (*)(btrc_player_settings_t*)}' [-fpermissive] ../../../gecko/dom/bluetooth/bluedroid/BluetoothA2dpManager.cpp:391:1: error: invalid conversion from 'void (*)(btrc_event_id_t, uint32_t) {aka void (*)(btrc_event_id_t, unsigned int)}' to 'btrc_get_element_attr_callback {aka void (*)(unsigned char, btrc_media_attr_t*)}' [-fpermissive]
Attached patch avrcp-kitkat.patch (obsolete) — Splinter Review
btrc_remote_features_callback was added in KitKat, which is the first callback function of btrc_callbacks_t. We need to add it, otherwise, signature of callback functions will not be matched.
Attachment #8350594 - Flags: feedback?(echou)
(In reply to Shawn Huang [:shuang] [:shawnjohnjr] from comment #3) > It looks like js/xpconnect/src/event_impl_gen.conf.in, MOZ_B2G_BT was not > defined. This was caused by changing configure.in after code generated. auto-gen files shall need to re-generate again. After that, things are good. So I think we only need attachment 8350594 [details] [diff] [review].
HFP/A2DP looks good on KitKat.
Hardware: x86_64 → ARM
Target Milestone: --- → 1.3 C2/1.4 S2(17jan)
blocking-b2g: --- → 1.4?
KitKat bluetooth HAL now added AVRCP 1.4 feature for AbsoluteVolume in HAL. We shall open another bug. For this bug, we just focus on functions that 1.3 version supported.
Comment on attachment 8350594 [details] [diff] [review] avrcp-kitkat.patch Review of attachment 8350594 [details] [diff] [review]: ----------------------------------------------------------------- Looks good. This also reminds me that maybe we could use the same flag to exclude AVRCP 1.3 related code if Android 4.2.2 or previous version is used. Make sense?
Attachment #8350594 - Flags: feedback?(echou) → feedback+
(In reply to Shawn Huang [:shuang] [:shawnjohnjr] from comment #10) > Created attachment 8351165 [details] [diff] [review] > Bug 946240 - [Bluetooth][gonk-kk]Add flag to support different AVRCP profile > version This change would support JB 4.2.x, since JB 4.2 does not support AVRCP 1.3, based on Comment 9, in this patch, which fixes build break in JB 4.2. We have to do it since there are still a few BSPs only support Android 4.2.
Comment on attachment 8351165 [details] [diff] [review] Bug 946240 - [Bluetooth][gonk-kk]Add flag to support different AVRCP profile version Review of attachment 8351165 [details] [diff] [review]: ----------------------------------------------------------------- Looks good. Please make sure it compiles in all cases(ANDROID_VERSION < 17, = 17 and > 17). Thanks.
Attachment #8351165 - Flags: review?(echou) → review+
Compiled on Android JB 4.3, Android JB 4.2 with bluedroid.
blocking-b2g: 1.4? → 1.4+
I also tried to build on different versions 4.2.2, 4.3, 4.4.
Attachment #8350594 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Whiteboard: [qa-]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: