Skip to content

Commit 1c16383

Browse files
author
Cruz Monrreal
authored
Merge pull request #8708 from SeeedJP/wio_bg96_hal
[Wio BG96] Adding platform HAL
2 parents 3c0d6f0 + cd2a583 commit 1c16383

File tree

7 files changed

+1061
-0
lines changed

7 files changed

+1061
-0
lines changed

features/cellular/framework/common/CellularTargets.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ namespace mbed {
2525
#define CELLULAR_DEVICE QUECTEL_BC95
2626
#elif TARGET_WIO_3G
2727
#define CELLULAR_DEVICE QUECTEL_UG96
28+
#elif TARGET_WIO_BG96
29+
#define CELLULAR_DEVICE QUECTEL_BG96
2830
#elif TARGET_MTS_DRAGONFLY_F411RE
2931
#define CELLULAR_DEVICE TELIT_HE910
3032
#elif TARGET_MTB_MTS_DRAGONFLY
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
/* Mbed Microcontroller Library
2+
*******************************************************************************
3+
* Copyright (c) 2018, STMicroelectronics
4+
* All rights reserved.
5+
*
6+
* SPDX-License-Identifier: BSD-3-Clause-Clear
7+
*
8+
* Redistribution and use in source and binary forms, with or without
9+
* modification, are permitted provided that the following conditions are met:
10+
*
11+
* 1. Redistributions of source code must retain the above copyright notice,
12+
* this list of conditions and the following disclaimer.
13+
* 2. Redistributions in binary form must reproduce the above copyright notice,
14+
* this list of conditions and the following disclaimer in the documentation
15+
* and/or other materials provided with the distribution.
16+
* 3. Neither the name of STMicroelectronics nor the names of its contributors
17+
* may be used to endorse or promote products derived from this software
18+
* without specific prior written permission.
19+
*
20+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21+
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22+
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
23+
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
24+
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25+
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
26+
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
27+
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
28+
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29+
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30+
*******************************************************************************
31+
*/
32+
33+
#ifndef MBED_PERIPHERALNAMES_H
34+
#define MBED_PERIPHERALNAMES_H
35+
36+
#include "cmsis.h"
37+
38+
#ifdef __cplusplus
39+
extern "C" {
40+
#endif
41+
42+
typedef enum {
43+
ADC_1 = (int)ADC1_BASE,
44+
ADC_2 = (int)ADC2_BASE,
45+
ADC_3 = (int)ADC3_BASE
46+
} ADCName;
47+
48+
typedef enum {
49+
DAC_1 = (int)DAC_BASE
50+
} DACName;
51+
52+
typedef enum {
53+
UART_1 = (int)USART1_BASE,
54+
UART_2 = (int)USART2_BASE,
55+
UART_3 = (int)USART3_BASE,
56+
UART_4 = (int)UART4_BASE,
57+
UART_5 = (int)UART5_BASE,
58+
UART_6 = (int)USART6_BASE,
59+
UART_7 = (int)UART7_BASE,
60+
UART_8 = (int)UART8_BASE
61+
} UARTName;
62+
63+
typedef enum {
64+
SPI_1 = (int)SPI1_BASE,
65+
SPI_2 = (int)SPI2_BASE,
66+
SPI_3 = (int)SPI3_BASE,
67+
SPI_4 = (int)SPI4_BASE,
68+
SPI_5 = (int)SPI5_BASE,
69+
SPI_6 = (int)SPI6_BASE
70+
} SPIName;
71+
72+
typedef enum {
73+
I2C_1 = (int)I2C1_BASE,
74+
I2C_2 = (int)I2C2_BASE,
75+
I2C_3 = (int)I2C3_BASE
76+
} I2CName;
77+
78+
typedef enum {
79+
PWM_1 = (int)TIM1_BASE,
80+
PWM_2 = (int)TIM2_BASE,
81+
PWM_3 = (int)TIM3_BASE,
82+
PWM_4 = (int)TIM4_BASE,
83+
PWM_5 = (int)TIM5_BASE,
84+
PWM_8 = (int)TIM8_BASE,
85+
PWM_9 = (int)TIM9_BASE,
86+
PWM_10 = (int)TIM10_BASE,
87+
PWM_11 = (int)TIM11_BASE,
88+
PWM_12 = (int)TIM12_BASE,
89+
PWM_13 = (int)TIM13_BASE,
90+
PWM_14 = (int)TIM14_BASE
91+
} PWMName;
92+
93+
typedef enum {
94+
CAN_1 = (int)CAN1_BASE,
95+
CAN_2 = (int)CAN2_BASE
96+
} CANName;
97+
98+
#ifdef __cplusplus
99+
}
100+
#endif
101+
102+
#endif

0 commit comments

Comments
 (0)