Mozzi
version v2.0
sound synthesis library for Arduino
teensyPinMap.h
1
/*
2
* teensyPinMap.h
3
*
4
* This file is part of Mozzi.
5
*
6
* Copyright 2021-2024 T. Combriat and the Mozzi Team
7
*
8
* Mozzi is licensed under the GNU Lesser General Public Licence (LGPL) Version 2.1 or later.
9
*
10
*/
11
12
#
ifndef
TEENSYPINMAP_H_
13
#
define
TEENSYPINMAP_H
14
15
16
inline
uint8_t teensyPinMap(uint8_t pin)
17
{
18
if
(pin < 24)
return
pin-14;
// common to all teensys
19
20
#
if
defined
(
__MK20DX128__
)
// Teensy 3.0
21
return
pin - 24;
22
23
#
elif
defined
(
__MK20DX256__
)
// Teensy 3.1/3.2
24
25
switch
(pin)
26
{
27
case
34:
28
return
10;
29
case
35:
30
return
11;
31
case
36:
32
return
12;
33
case
37:
34
return
13;
35
case
40:
36
return
14;
37
case
26:
38
return
15;
39
case
27:
40
return
16;
41
case
28:
42
return
17;
43
case
29:
44
return
18;
45
case
30:
46
return
19;
47
case
31:
48
return
20;
49
}
50
51
52
53
54
#
elif
defined
(
__MKL26Z64__
)
//TeensyLC
55
return
pin-14;
56
57
58
#
elif
defined
(
__MK64FX512__
)
||
defined
(
__MK66FX1M0__
)
// Teensy 3.5//3.6
59
switch
(pin)
60
{
61
case
64:
62
return
10;
63
case
65:
64
return
11;
65
case
31:
66
return
12;
67
case
32:
68
return
13;
69
case
33:
70
return
14;
71
case
34:
72
return
15;
73
case
35:
74
return
16;
75
case
36:
76
return
17;
77
case
37:
78
return
18;
79
case
38:
80
return
19;
81
case
39:
82
return
20;
83
case
66:
84
return
21;
85
case
67:
86
return
22;
87
case
49:
88
return
23;
89
case
50:
90
return
24;
91
case
68:
92
return
25;
93
case
69:
94
return
26;
95
}
96
97
#
elif
defined
ARDUINO_TEENSY40
98
return
pin-14;
99
100
#
elif
defined
ARDUINO_TEENSY41
101
if
(pin< 28)
return
pin-14;
102
return
pin-24;
103
#
endif
104
105
106
107
}
108
109
110
111
112
113
#
endif
Generated automatically using Doxygen. If info on this page is outdated, incomplete, or wrong, please open an issue at https://github.com/sensorium/Mozzi/issues