Skip to content

Commit 9c399ed

Browse files
committed
Adding currently still breaking example to source code.
1 parent c9cbe07 commit 9c399ed

File tree

3 files changed

+30
-0
lines changed

3 files changed

+30
-0
lines changed

examples/Breaks_5/Breaks_5.ino

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#include <Arduino_Threads.h>
2+
3+
void setup()
4+
{
5+
Thread.start();
6+
}
7+
8+
void loop()
9+
{
10+
11+
}

examples/Breaks_5/SharedVariables.h

Whitespace-only changes.

examples/Breaks_5/Thread.inot

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
/* This fails to compile because myEventHandler is declared
2+
* after setup/loop and currently there's not automatic prototype
3+
* generation as done for the ino file.
4+
*/
5+
6+
void setup()
7+
{
8+
attachInterrupt(digitalPinToInterrupt(2), myEventHandler, CHANGE);
9+
}
10+
11+
void loop()
12+
{
13+
14+
}
15+
16+
void myEventHandler()
17+
{
18+
/* Do something. */
19+
}

0 commit comments

Comments
 (0)