Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: BLE_API_Tiny_BLE MPU6050-DMP-Seeed-Tiny-BLE mbed
MPUService.cpp
00001 /* mbed Microcontroller Library 00002 * Copyright (c) 2006-2013 ARM Limited 00003 * 00004 * Licensed under the Apache License, Version 2.0 (the "License"); 00005 * you may not use this file except in compliance with the License. 00006 * You may obtain a copy of the License at 00007 * 00008 * http://www.apache.org/licenses/LICENSE-2.0 00009 * 00010 * Unless required by applicable law or agreed to in writing, software 00011 * distributed under the License is distributed on an "AS IS" BASIS, 00012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00013 * See the License for the specific language governing permissions and 00014 * limitations under the License. 00015 * 00016 00017 * 00018 * 00019 */ 00020 00021 #include "MPUService.h" 00022 00023 const uint8_t MPUServiceBaseUUID[LENGTH_OF_LONG_UUID] = { 00024 0xD9, 0x88, 0x8D, 0xC0, 0x0E, 0x91, 0x11, 0xE5, 00025 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00026 }; 00027 const uint16_t MPUServiceShortUUID = 0x8DC0; 00028 00029 const uint16_t MPUServiceYPRCharacteristicShortUUID = 0x8DC1; 00030 00031 const uint16_t MPUServiceAccelCharacteristicShortUUID = 0x8DC2; 00032 const uint16_t MPUServiceQuatCharacteristicShortUUID = 0x8DC3; 00033 const uint16_t MPUServiceTimeCharacteristicShortUUID = 0x8DC4; 00034 const uint16_t MPUServiceSettingCharacteristicShortUUID = 0x8DC5; 00035 00036 const uint8_t MPUServiceUUID[LENGTH_OF_LONG_UUID] = { 00037 0xD9, 0x88, (uint8_t)(MPUServiceShortUUID >> 8), (uint8_t)(MPUServiceShortUUID & 0xFF), 0x0E, 0x91, 0x11, 0xE5, 00038 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00039 }; 00040 00041 const uint8_t MPUServiceUUID_reversed[LENGTH_OF_LONG_UUID] = { 00042 0x66, 0x9A, 0x0C, 0x20, 0x00, 0x08, 0x39, 0xB9, 00043 0xE5, 0x11, 0x91, 0x0E, (uint8_t)(MPUServiceShortUUID & 0xFF), (uint8_t)(MPUServiceShortUUID >> 8), 0x88, 0xD9 00044 }; 00045 00046 const uint8_t MPUServiceYPRCharacteristicUUID[LENGTH_OF_LONG_UUID] = { 00047 0xD9, 0x88, (uint8_t)(MPUServiceYPRCharacteristicShortUUID >> 8), (uint8_t)(MPUServiceYPRCharacteristicShortUUID & 0xFF), 0x0E, 0x91, 0x11, 0xE5, 00048 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00049 }; 00050 00051 const uint8_t MPUServiceAccelCharacteristicUUID[LENGTH_OF_LONG_UUID] = { 00052 0xD9, 0x88, (uint8_t)(MPUServiceAccelCharacteristicShortUUID >> 8), (uint8_t)(MPUServiceAccelCharacteristicShortUUID & 0xFF), 0x0E, 0x91, 0x11, 0xE5, 00053 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00054 }; 00055 00056 const uint8_t MPUServiceQuatCharacteristicUUID[LENGTH_OF_LONG_UUID] = { 00057 0xD9, 0x88, (uint8_t)(MPUServiceQuatCharacteristicShortUUID >> 8), (uint8_t)(MPUServiceQuatCharacteristicShortUUID & 0xFF), 0x0E, 0x91, 0x11, 0xE5, 00058 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00059 }; 00060 00061 const uint8_t MPUServiceTimeCharacteristicUUID[LENGTH_OF_LONG_UUID] = { 00062 0xD9, 0x88, (uint8_t)(MPUServiceTimeCharacteristicShortUUID >> 8), (uint8_t)(MPUServiceTimeCharacteristicShortUUID & 0xFF), 0x0E, 0x91, 0x11, 0xE5, 00063 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00064 }; 00065 00066 const uint8_t MPUServiceSettingCharacteristicUUID[LENGTH_OF_LONG_UUID] = { 00067 0xD9, 0x88, (uint8_t)(MPUServiceSettingCharacteristicShortUUID >> 8), (uint8_t)(MPUServiceSettingCharacteristicShortUUID & 0xFF), 0x0E, 0x91, 0x11, 0xE5, 00068 0xB9, 0x39, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66 00069 }; 00070 00071
Generated on Tue Jul 12 2022 18:38:30 by
1.7.2