Statistics
| Revision:

root / Ports / examples / SMDdemo / SMDdemo.pde

History | View | Annotate | Download (497 Bytes)

1
//>>> The latest version of this code can be found at https://github.com/jcw/ !!
2
3
// Test sketch for the JeeSMD plug - continuously toggle all the I/O lines.
4
// 2010-03-18 <jcw@equi4.com> http://opensource.org/licenses/mit-license.php
5
// $Id: SMDdemo.pde 7763 2011-12-11 01:28:16Z jcw $
6
7
byte value;
8
9
void setup () {
10
    UCSR0B = 0; // disable the UART
11
    for (byte i = 0; i < 20; ++i)
12
        pinMode(i, OUTPUT);
13
}
14
15
void loop () {
16
    value = !value;    
17
    for (byte i = 0; i < 20; ++i)
18
        digitalWrite(i, value);
19
    delay(500);
20
}