The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.

Dependents:   hello SerialTestv11 SerialTestv12 Sierpinski ... more

mbed 2

This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.

Committer:
AnnaBridge
Date:
Wed Feb 20 20:53:29 2019 +0000
Revision:
172:65be27845400
Parent:
171:3a7713b1edbc
mbed library release version 165

Who changed what in which revision?

UserRevisionLine numberNew contents of line
AnnaBridge 167:84c0a372a020 1 /*******************************************************************************
AnnaBridge 167:84c0a372a020 2 * Copyright (C) 2016 Maxim Integrated Products, Inc., All Rights Reserved.
AnnaBridge 167:84c0a372a020 3 *
AnnaBridge 167:84c0a372a020 4 * Permission is hereby granted, free of charge, to any person obtaining a
AnnaBridge 167:84c0a372a020 5 * copy of this software and associated documentation files (the "Software"),
AnnaBridge 167:84c0a372a020 6 * to deal in the Software without restriction, including without limitation
AnnaBridge 167:84c0a372a020 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
AnnaBridge 167:84c0a372a020 8 * and/or sell copies of the Software, and to permit persons to whom the
AnnaBridge 167:84c0a372a020 9 * Software is furnished to do so, subject to the following conditions:
AnnaBridge 167:84c0a372a020 10 *
AnnaBridge 167:84c0a372a020 11 * The above copyright notice and this permission notice shall be included
AnnaBridge 167:84c0a372a020 12 * in all copies or substantial portions of the Software.
AnnaBridge 167:84c0a372a020 13 *
AnnaBridge 167:84c0a372a020 14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
AnnaBridge 167:84c0a372a020 15 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
AnnaBridge 167:84c0a372a020 16 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
AnnaBridge 167:84c0a372a020 17 * IN NO EVENT SHALL MAXIM INTEGRATED BE LIABLE FOR ANY CLAIM, DAMAGES
AnnaBridge 167:84c0a372a020 18 * OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
AnnaBridge 167:84c0a372a020 19 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
AnnaBridge 167:84c0a372a020 20 * OTHER DEALINGS IN THE SOFTWARE.
AnnaBridge 167:84c0a372a020 21 *
AnnaBridge 167:84c0a372a020 22 * Except as contained in this notice, the name of Maxim Integrated
AnnaBridge 167:84c0a372a020 23 * Products, Inc. shall not be used except as stated in the Maxim Integrated
AnnaBridge 167:84c0a372a020 24 * Products, Inc. Branding Policy.
AnnaBridge 167:84c0a372a020 25 *
AnnaBridge 167:84c0a372a020 26 * The mere transfer of this software does not imply any licenses
AnnaBridge 167:84c0a372a020 27 * of trade secrets, proprietary technology, copyrights, patents,
AnnaBridge 167:84c0a372a020 28 * trademarks, maskwork rights, or any other form of intellectual
AnnaBridge 167:84c0a372a020 29 * property whatsoever. Maxim Integrated Products, Inc. retains all
AnnaBridge 167:84c0a372a020 30 * ownership rights.
AnnaBridge 167:84c0a372a020 31 *******************************************************************************
AnnaBridge 167:84c0a372a020 32 */
AnnaBridge 167:84c0a372a020 33
AnnaBridge 167:84c0a372a020 34 #ifndef MBED_PERIPHERALNAMES_H
AnnaBridge 167:84c0a372a020 35 #define MBED_PERIPHERALNAMES_H
AnnaBridge 167:84c0a372a020 36
AnnaBridge 167:84c0a372a020 37 #include "cmsis.h"
AnnaBridge 167:84c0a372a020 38
AnnaBridge 167:84c0a372a020 39 #ifdef __cplusplus
AnnaBridge 167:84c0a372a020 40 extern "C" {
AnnaBridge 167:84c0a372a020 41 #endif
AnnaBridge 167:84c0a372a020 42
AnnaBridge 167:84c0a372a020 43 typedef enum {
AnnaBridge 167:84c0a372a020 44 UART_0 = MXC_BASE_UART0,
AnnaBridge 167:84c0a372a020 45 UART_1 = MXC_BASE_UART1,
AnnaBridge 167:84c0a372a020 46 UART_2 = MXC_BASE_UART2,
AnnaBridge 167:84c0a372a020 47 UART_3 = MXC_BASE_UART3,
AnnaBridge 167:84c0a372a020 48 STDIO_UART = UART_1
AnnaBridge 167:84c0a372a020 49 } UARTName;
AnnaBridge 167:84c0a372a020 50
AnnaBridge 167:84c0a372a020 51 typedef enum {
AnnaBridge 167:84c0a372a020 52 I2C_0 = MXC_BASE_I2CM0,
AnnaBridge 167:84c0a372a020 53 I2C_1 = MXC_BASE_I2CM1,
AnnaBridge 167:84c0a372a020 54 I2C_2 = MXC_BASE_I2CM2
AnnaBridge 167:84c0a372a020 55 } I2CName;
AnnaBridge 167:84c0a372a020 56
AnnaBridge 167:84c0a372a020 57 typedef enum {
AnnaBridge 167:84c0a372a020 58 SPI_0 = MXC_BASE_SPIM0,
AnnaBridge 167:84c0a372a020 59 SPI_1 = MXC_BASE_SPIM1,
AnnaBridge 167:84c0a372a020 60 SPI_2 = MXC_BASE_SPIM2
AnnaBridge 167:84c0a372a020 61 } SPIName;
AnnaBridge 167:84c0a372a020 62
AnnaBridge 167:84c0a372a020 63 typedef enum {
AnnaBridge 167:84c0a372a020 64 PWM_0 = MXC_BASE_PT0,
AnnaBridge 167:84c0a372a020 65 PWM_1 = MXC_BASE_PT1,
AnnaBridge 167:84c0a372a020 66 PWM_2 = MXC_BASE_PT2,
AnnaBridge 167:84c0a372a020 67 PWM_3 = MXC_BASE_PT3,
AnnaBridge 167:84c0a372a020 68 PWM_4 = MXC_BASE_PT4,
AnnaBridge 167:84c0a372a020 69 PWM_5 = MXC_BASE_PT5,
AnnaBridge 167:84c0a372a020 70 PWM_6 = MXC_BASE_PT6,
AnnaBridge 167:84c0a372a020 71 PWM_7 = MXC_BASE_PT7,
AnnaBridge 167:84c0a372a020 72 PWM_8 = MXC_BASE_PT8,
AnnaBridge 167:84c0a372a020 73 PWM_9 = MXC_BASE_PT9,
AnnaBridge 167:84c0a372a020 74 PWM_10 = MXC_BASE_PT10,
AnnaBridge 167:84c0a372a020 75 PWM_11 = MXC_BASE_PT11,
AnnaBridge 167:84c0a372a020 76 PWM_12 = MXC_BASE_PT12,
AnnaBridge 167:84c0a372a020 77 PWM_13 = MXC_BASE_PT13,
AnnaBridge 167:84c0a372a020 78 PWM_14 = MXC_BASE_PT14,
AnnaBridge 167:84c0a372a020 79 PWM_15 = MXC_BASE_PT15
AnnaBridge 167:84c0a372a020 80 } PWMName;
AnnaBridge 167:84c0a372a020 81
AnnaBridge 167:84c0a372a020 82 typedef enum {
AnnaBridge 167:84c0a372a020 83 ADC = MXC_BASE_ADC
AnnaBridge 167:84c0a372a020 84 } ADCName;
AnnaBridge 167:84c0a372a020 85
AnnaBridge 167:84c0a372a020 86 #ifdef __cplusplus
AnnaBridge 167:84c0a372a020 87 }
AnnaBridge 167:84c0a372a020 88 #endif
AnnaBridge 167:84c0a372a020 89
AnnaBridge 167:84c0a372a020 90 #endif