rafavi EW
Car Extended Warranty
NXP wireless solutions build upon decades of Wi-Fi and Bluetooth silicon, system and software design expertise. NXP is committed to drive large-scale deployment across multiple markets by a broad array of power- and cost-optimized Wi-Fi and Bluetooth chipsets, enabling products with today’s most advanced Wi-Fi capabilities.
NXP Semiconductors N.V. (NASDAQ: NXPI) announced on May 15 this year the availability of new devices within its KW3x family of microcontrollers (MCUs). The new KW39/38/37 MCUs add Bluetooth 5.0 long-range capabilities and expanded Bluetooth advertising channels. These enhancements are made while offering seamless migration with hardware, software and tools compatibility with the previous generation of devices, KW34/35/36. The connectivity MCUs allow Bluetooth LE devices to communicate at distances of more than a mile and increase the amount of Bluetooth advertising channels and advertising data within the Bluetooth standard, the predominant IoT protocol. The new wireless MCU solutions allow developers to address emerging use cases within automotive and industrial digitization.
The FRDM-KW41Z is a development kit enabled by the Kinetis® W series KW41Z/31Z/21Z (KW41Z) family built on Arm® Cortex®-M0+ processor with integrated 2.4 GHz transceiver supporting Bluetooth® Smart/Bluetooth®Low Energy (BLE) v4.2, Generic FSK, IEEE® 802.15.4 and Thread.
The FRDM-KW41Z kit contains two Freedom boards that can be used as a development board or a shield to connect to a host processor. The FRDM-KW41Z is form-factor compatible with the Arduino® Rev3 pin layout for more expansion options.
The FRDM-KW41Z highly-sensitive, optimized 2.4 GHz radio features a PCB F-antenna which can be bypassed to test via SMA connection, multiple power supply options, push/capacitive touch buttons, switches, LEDs and integrated sensors.
The FRDM-KW41Z platform is now supported by Arm® Mbed™ OS and Zephyr™ OS, both open source embedded operating systems for developing the Internet of Things.

Freedom Development Boards for Kinetis KW21Z, KW31Z and KW41Z MCUs. 2 boards
Technical and Functional Specifications
|
|
Can be configured as Host or Shield for connection to Host Processor |
|
Connectivity
|
SMA RF Connector |
| Sensors | Onboard NXP FXOS8700CQ digital sensor, 3D Accelerometer (±2g/±4g/±8g) + 3D Magnetometer |
| Debug | OpenSDA and JTAG debug |
| Support |
|
|
低功耗蓝牙作为物联网重要无线连接技术,使用场景越来越丰富,国内厂商也在加速布局,除去传统蓝牙芯片企业积极转型或拓展新板块,低功耗蓝牙创业公司也如雨后春笋般萌发。尽管国外低功耗蓝牙芯片发展较早占据优势,但国外产品普遍价格昂贵,且面临着继续开发难度大、国内本土化服务不足等劣势,为国内企业进入低功耗蓝牙芯片领域创造了机会。
国内传统蓝牙厂商出货的ble蓝牙芯片的普遍集中在低端BLE上,版本在4.2及以下,近两年才开始转型布局BLE5.0,但主要还是应用在蓝牙音频上的双模低功耗蓝牙芯片,少数厂商开发具有蓝牙mesh和室内定位等功能的单模蓝牙透传芯片。在2016年以后才陆续研发高端BLE,近两年有部分BLE蓝牙芯片5.0产品出货,但量还不算大。

国内BLE厂商及主要产品
国内低功耗蓝牙厂商,比如富瑞坤、上海巨微、奉加微、联睿微、桃芯科技结合中国企业的需求,开发本土化程度更高的低功耗蓝牙芯片。能够开发功耗极低,连接稳定性高的BLE芯片,并且能有效控制成本的厂商才有机会开拓市场,和下游应用厂商紧密合作,从而在市场中占有一席之地。因此具备较强技术研发能力,能够进行极强低功耗设计和性能设计的高端BLE厂商是重点关注对象。上海巨微代理商英尚微提供样品及技术支持。
芯片设计产业转移大势所趋,多重驱动使得国内低功耗蓝牙厂商实现进口替代确定性高。随着中国对集成电路产业政策支持发力,以及为了抵御中美贸易摩擦带来IC供应链风险等外部因素;还有国内物联网发展带来蓝牙终端市场的巨大需求刺激,以及国内芯片设计优秀人才变多等内部因素;蓝牙厂商逐渐向内地转移,高端低功耗蓝牙作为一个好赛道,国产替代是一个必然。
在全球可穿戴设备、物联网细分市场增势良好的激励下,低功耗蓝牙应用增长空间巨大,预计2023年将达到65亿美元。中国作为低功耗蓝牙芯片的重要市场,急需国内公司布局高端低功耗蓝牙,更好地解决国内终端应用厂商定制化需求,从而实现进口替代。
Until 2020, the Internet of Things (IoT) will reach 1.3 trillion USD, and the IoT devices will reach 30 billion units. In the next 25 years, the requirement of IoT devices will increase to 80 billion. ( Research Institute IDC company forecast)
In 2025, there will be 1.8 billion Mobile IoT connects in 3.1 billion cellular IoT in the world. The GSMA expected that by 2025, there will be 13.8 billion industrial IoT connections, and 65% will form the Asia-Pacic and China (6.3 billion). (GSMA)
Keynote speech by industry leading CXO
In-depth discussion of the opportunities and challenges facing the Internet of Things industry in the era of new infrastructure
蓝牙是一种短距离的无线通信技术,可以实现固定设备、移动设备之间的数据交换。一般将蓝牙分为两大类,蓝牙3.0规范之前的版本称为传统蓝牙,蓝牙4.0规范之后的版本称为低功耗蓝牙,也就是常说的BLE(Bluetooth Low Energy)。
本文主要讲解的是Android设备与BLE设备之间的通信,Android 从4.3版本(API Level 18)开始支持BLE通信。

首先要判断当前的Android设备是否支持蓝牙,如果支持则再判断当前蓝牙是否处于开启状态,如果未开启则发送广播通知系统开启蓝牙,蓝牙开启后开始搜索周围的蓝牙设备,注意搜索一定要设置超时处理,搜索到指定蓝牙设备后停止搜索任务。
此时可以以列表的形式供用户选择需要连接的设备,或者内部自动连接特定的设备,连接成功后,搜索此蓝牙设备提供的服务(特性、描述符的集合),搜索完成后设置一些对应的参数,即可与蓝牙设备进行通信了。
看下我们在开发过程中需要用到的一些API:
本地蓝牙适配器,用于一些蓝牙的基本操作,比如判断蓝牙是否开启、搜索蓝牙设备等。
蓝牙设备对象,包含一些蓝牙设备的属性,比如设备名称、mac地址等。
一个通用的蓝牙规范,设备之间按照这个规范来收发数据。
蓝牙通用属性协议,定义了BLE通讯的基本规则,是BluetoothProfile的实现类,Gatt是Generic Attribute Profile的缩写,用于连接设备、搜索服务等操作。
蓝牙设备连接成功后,用于回调一些操作的结果,必须连接成功后才会回调。
蓝牙设备提供的服务,是蓝牙设备特征的集合。
蓝牙设备特征,是构建GATT服务的基本数据单元。
蓝牙设备特征描述符,是对特征的额外描述。
需用用到的权限:
<uses-permission android:name="android.permission.BLUETOOTH" />
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
当蓝牙连接成功后,会回调BluetoothGattCallback中的onConnectionStateChange方法,但是此时还不能与蓝牙设备进行通信,还需要调用BluetoothGatt中的discoverServices方法搜索蓝牙设备提供的服务,也就是我们上文中提到的BluetoothGattService,搜索完成后会回调BluetoothGattCallback中的onServicesDiscovered方法,这时就轮到setBleNotification方法大显身手了。
首先通过一个UUID获取到蓝牙设备提供的服务(BluetoothGattService),这个UUID是由硬件程序定义的,开发的过程中看文档就可以了,获取到服务后,再通过一个UUID获取到蓝牙设备的特征(BluetoothGattCharacteristic),然后再获取设备特征的描述符(BluetoothGattDescriptor),设置在蓝牙设备数据改变时,主动通知App,此时回调BluetoothGattCallback中的onCharacteristicChanged方法,通过characteristic.getValue()可以获取到通知的数据。
在BluetoothGattCallback还有很多回调方法,都是与BluetoothGatt的操作相对应的
应用启动后首先检测当前设备蓝牙是否可用,以及蓝牙是否开启,然后开始搜索蓝牙设备,注意一定要设置搜索的超时时间,将搜索到的蓝牙设备信息存到一个集合中,搜索时间为10s。
然后绑定BleService,以便调用Service中的方法,同时再通过startService的方式开启服务,这样Activity被销毁后service依旧可以运行。
接下来再注册一个广播接收器,接收service发来的消息并做一些处理,这时在蓝牙设备列表中点击你想要连接的设备就可以正常通信了。
在产品需求中,一般应用都是长时间连接一个硬件设备,比如手环,此时就需要做一些特殊处理,比如蓝牙连接断开后主动搜索之前已经连接的设备,或者应用运行过程中手机蓝牙被关闭之后的处理等。