Repository navigation
Expand file tree
/
Copy pathvariant.cpp
More file actions
93 lines (84 loc) · 2.11 KB
/
Copy pathvariant.cpp
File metadata and controls
93 lines (84 loc) · 2.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
/*
*******************************************************************************
* Copyright (c) 2019, STMicroelectronics
* All rights reserved.
*
* This software component is licensed by ST under BSD 3-Clause license,
* the "License"; You may not use this file except in compliance with the
* License. You may obtain a copy of the License at:
* opensource.org/licenses/BSD-3-Clause
*
*******************************************************************************
*/
#include "pins_arduino.h"
#ifdef __cplusplus
extern "C" {
#endif
// Digital PinName array
// This array allows to wrap Arduino pin number(Dx or x)
// to STM32 PinName (PX_n)
const PinName digitalPin[] = {
//PX_n, //Dx
P, //D0
P, //D1
P, //D2
P, //D3
P, //D4
P, //D5
P, //D6
P, //D7
P, //D8
P, //D9
P, //D10
P, //D11
P, //D12
P, //D13
P, //D14
P, //D15
P, //D16/A0
P, //D17/A1
P, //D18/A2
P, //D19/A3
P, //D20/A4
P, //D21/A5
// Required only if Ax pins are automaticaly defined using `NUM_ANALOG_FIRST`
// and have to be contiguous in this array
// Duplicated pins in order to be aligned with PinMap_ADC
P, //D22/A6 = D
P, //D23/A7 = D
P //D24/A8 = D
};
// If analog pins are not contiguous in the digitalPin array:
// Add the analogInputPin array without defining NUM_ANALOG_FIRST
// Analog (Ax) pin number array
// where x is the index to retrieve the digital pin number
const uint32_t analogInputPin[] = {
//PXn, //Ax = Dx
2, //A0 = Dx
8, //A1 = Dy
3 //A2 = Dz
}
#ifdef __cplusplus
}
#endif
// ----------------------------------------------------------------------------
#ifdef __cplusplus
extern "C" {
#endif
/**
* @brief System Clock Configuration
* @param None
* @retval None
*/
WEAK void SystemClock_Config(void)
{
// Here copy the desired System Clock Configuration
// It could be generated thanks STM32CubeMX after code generation for Toolchain/IDE: 'SW4STM32',
// available in src/main.c
// or
// copied from a STM32CubeYY project examples
// where 'YY' could be F0, F1, F2, F3, F4, F7, G0, G4, H7, L0, L1, L4, MP1, WB
}
#ifdef __cplusplus
}
#endif