Skip to content

Commit c138ded

Browse files
Ashok RaoAshok Rao
authored andcommitted
Adding MTB MXChip EMW3166 as a new target
1 parent af9e073 commit c138ded

File tree

5 files changed

+975
-0
lines changed

5 files changed

+975
-0
lines changed
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
/* mbed Microcontroller Library
2+
* Copyright (c) 2016 ARM Limited
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
#ifndef MBED_PERIPHERALNAMES_H
17+
#define MBED_PERIPHERALNAMES_H
18+
19+
#include "cmsis.h"
20+
21+
#ifdef __cplusplus
22+
extern "C" {
23+
#endif
24+
25+
typedef enum {
26+
ADC_1 = (int)ADC1_BASE
27+
} ADCName;
28+
29+
typedef enum {
30+
UART_1 = (int)USART1_BASE,
31+
UART_2 = (int)USART2_BASE,
32+
UART_3 = (int)USART3_BASE,
33+
UART_6 = (int)USART6_BASE
34+
} UARTName;
35+
36+
#define STDIO_UART_TX PD_8
37+
#define STDIO_UART_RX PD_9
38+
#define STDIO_UART UART_3
39+
40+
typedef enum {
41+
SPI_1 = (int)SPI1_BASE,
42+
SPI_2 = (int)SPI2_BASE,
43+
SPI_3 = (int)SPI3_BASE,
44+
SPI_4 = (int)SPI4_BASE,
45+
SPI_5 = (int)SPI5_BASE
46+
} SPIName;
47+
48+
typedef enum {
49+
I2C_1 = (int)I2C1_BASE,
50+
I2C_2 = (int)I2C2_BASE,
51+
I2C_3 = (int)I2C3_BASE,
52+
FMPI2C_1 = (int)FMPI2C1_BASE
53+
} I2CName;
54+
55+
typedef enum {
56+
PWM_1 = (int)TIM1_BASE,
57+
PWM_2 = (int)TIM2_BASE,
58+
PWM_3 = (int)TIM3_BASE,
59+
PWM_4 = (int)TIM4_BASE,
60+
PWM_5 = (int)TIM5_BASE,
61+
PWM_8 = (int)TIM8_BASE,
62+
PWM_9 = (int)TIM9_BASE,
63+
PWM_10 = (int)TIM10_BASE,
64+
PWM_11 = (int)TIM11_BASE,
65+
PWM_12 = (int)TIM12_BASE,
66+
PWM_13 = (int)TIM13_BASE,
67+
PWM_14 = (int)TIM14_BASE
68+
} PWMName;
69+
70+
typedef enum {
71+
CAN_1 = (int)CAN1_BASE,
72+
CAN_2 = (int)CAN2_BASE
73+
} CANName;
74+
75+
#ifdef __cplusplus
76+
}
77+
#endif
78+
79+
#endif

0 commit comments

Comments
 (0)