| 数据搜索系统,热门电子元器件搜索 |
|
PM0237 数据表(PDF) 45 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
PM0237 数据表(HTML) 45 Page - STMicroelectronics |
|
45 / 88 page ![]() DocID027104 Rev 2 45/88 PM0237 Design an application using BlueNRG, BlueNRG-MS ACI APIs 88 3.1.1 BLE addresses The following device addresses are supported from BlueNRG and BlueNRG-MS devices: • Public address • Random address • Private address Public MAC addresses (6 bytes- 48 bits address) uniquely identifies a BLE device, and they are defined by Institute of Electrical and Electronics Engineers (IEEE). The first 3 bytes of the public address identify the company that issued the identifier and are known as the Organizationally Unique Identifier (OUI). An Organizationally Unique Identifier (OUI) is a 24-bit number that is purchased from the IEEE. This identifier uniquely identifies a company and it allows to reserve a block of possible public addresses (up to 2^24 coming from the remaining 3 bytes of the public address) for the exclusive use of a company with a specific OUI. An organization/company can request a new set of 6 bytes addresses when at least the 95% of previously allocated block of addresses have been used (up to 2^24 possible addresses are available with a specific OUI). BlueNRG and BlueNRG-MS devices don't have a valid preassigned MAC address since the MAC address is specific to manufacturers. The public address must be set by the external processor. The ACI command to set the MAC address is ACI_HAL_WRITE_CONFIG_DATA (opcode 0xFC0C) with command parameters as follow: • Offset: 0x00 (0x00 identify the BTLE public address, i.e. MAC address) • Length: 0x06 (Length of the MAC address) • Value: 0xaabbccddeeff (48 bit array for MAC address) The command ACI_HAL_WRITE_CONFIG_DATA should be sent to BlueNRG and BlueNRG-MS devices by the uC before starting BLE operations (after each power-up or reset of BlueNRG). The following pseudocode example illustrates how to set a public address: uint8_t bdaddr[] = {0x12, 0x34, 0x00, 0xE1, 0x80, 0x02}; ret=aci_hal_write_config_data(CONFIG_DATA_PUBADDR_OFFSET,CONFIG_DATA_PUBAD DR_LEN, bdaddr); if(ret)PRINTF("Setting address failed.\n")} MAC address needs to be stored somewhere in the non-volatile memory associated to the product during product manufacturing. A user can write its application assuming that the MAC address is placed at a known Flash location of the microcontroller. During manufacturing, the microcontroller can be programmed with the customer Flash image via JTAG. A second step could involve generating the unique MAC address (i.e. reading it from a database) and storing of the MAC address in the known location in a free 48 bits area of the Flash. When the microcontroller’s application needs to access the MAC address simply refers to the known Flash memory location. |
|
链接网址 |
| ALLDATASHEET是否为您带来帮助? [ DONATE ] |
关于 Alldatasheet | 广告服务 | 联系我们 | 隐私政策 | 数据表链接 | 链接交换 | 制造商名单 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |