From 8c7bdcd5b6037245a6785ece11dc99e115567e70 Mon Sep 17 00:00:00 2001 From: Myles Watson Date: Mon, 2 Mar 2015 10:46:12 -0800 Subject: nrf51: Add Bluetooth LE support RADIO_STATE is broken: remove it. Build on the geneneric radio support to send and receive Bluetooth LE packets. Add macros in registers.h to configure PCNF0 and PCNF1. BUG=None BRANCH=None TEST=Send advertisements with console commands ble_adv type length [interval_us] for example: ble_adv 2 8 Advertisements should be received by other devices The Bluetooth Address has the form C5:A4:A3:A2:A1:A* The device name is a substring of ABCDEFGH... ABCDEFGH @ C5:A4:A3:A2:A1:A2 (name length is 8, type is 2) ABCDEFGH @ C5:A4:A3:A2:A1:A2 (name length is 8, type is 2) ABCDEF @ C5:A4:A3:A2:A1:A6 (name length is 6, type is 6) TEST=Listen for advertisements with console commands ble_adv_scan chan [num] [addr0] for example: ble_scan 37 Example output: BLE packet @ 20000448: type 2, len 33, 5c.f3.70.6b.65.d2 AdvA 20000454: 02 01 08 17 09 43 68 72 2000045c: 6f 6d 65 62 6f 78 20 66 20000464: 6f 72 20 4d 65 65 74 69 2000046c: 6e 46 16 02 01 08 = 2 bytes, Flags, LE and BR capable 17 09 43... = 23 bytes, Name, "Chromebox for Meetings" Change-Id: I2bd3f1d87acb069da0b56c1d7878e7d4fd6a06f3 Signed-off-by: Myles Watson Reviewed-on: https://chromium-review.googlesource.com/361960 Reviewed-by: Randall Spangler Reviewed-by: Levi Oliver --- chip/nrf51/build.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'chip/nrf51/build.mk') diff --git a/chip/nrf51/build.mk b/chip/nrf51/build.mk index 88509bba3c..69a2e3ed41 100644 --- a/chip/nrf51/build.mk +++ b/chip/nrf51/build.mk @@ -13,7 +13,7 @@ CFLAGS_CPU+=-march=armv6-m -mcpu=cortex-m0 chip-y+=gpio.o system.o uart.o chip-y+=jtag.o watchdog.o ppi.o -chip-$(CONFIG_BLUETOOTH_LE)+=radio.o +chip-$(CONFIG_BLUETOOTH_LE)+=radio.o bluetooth_le.o chip-$(CONFIG_COMMON_TIMER)+=hwtimer.o clock.o chip-$(CONFIG_I2C)+=i2c.o chip-$(HAS_TASK_KEYSCAN)+=keyboard_raw.o -- cgit v1.2.1