File tree 2 files changed +15
-0
lines changed
2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,8 @@ const byte CH_SLIDER = 4;
40
40
const byte CH_LIGHT = 5 ;
41
41
const byte CH_TEMPERATURE = 6 ;
42
42
const byte CH_MIC = 7 ;
43
+ const byte CH_TINKERKIT_A = 8 ;
44
+ const byte CH_TINKERKIT_B = 9 ;
43
45
const byte CH_JOYSTICK_SW = 10 ;
44
46
const byte CH_JOYSTICK_X = 11 ;
45
47
const byte CH_JOYSTICK_Y = 12 ;
@@ -156,6 +158,16 @@ class _Esplora {
156
158
void tone (unsigned int freq);
157
159
void tone (unsigned int freq, unsigned long duration);
158
160
void noTone ();
161
+
162
+ inline unsigned int readTinkerkitInput (byte whichInput) {
163
+ return readChannel (whichInput + CH_TINKERKIT_A);
164
+ }
165
+ inline unsigned int readTinkerkitInputA () {
166
+ return readChannel (CH_TINKERKIT_A);
167
+ }
168
+ inline unsigned int readTinkerkitInputB () {
169
+ return readChannel (CH_TINKERKIT_B);
170
+ }
159
171
};
160
172
161
173
Original file line number Diff line number Diff line change @@ -28,6 +28,9 @@ writeBlue KEYWORD2
28
28
readRed KEYWORD2
29
29
readGreen KEYWORD2
30
30
readBlue KEYWORD2
31
+ readTinkerkitInput KEYWORD2
32
+ readTinkerkitInputA KEYWORD2
33
+ readTinkerkitInputB KEYWORD2
31
34
tone KEYWORD2
32
35
noTone KEYWORD2
33
36
You can’t perform that action at this time.
0 commit comments