projects
/
goodfet
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
GoodFET11 sent to Gold Phoenix for fabrication.
[goodfet]
/
firmware
/
blink.c
1
//GOODFET Blinker
\r
2
\r
3
//1611 is preferred, but 1612 accepted
\r
4
\r
5
#include <signal.h>
\r
6
#include <io.h>
\r
7
#include <iomacros.h>
\r
8
\r
9
//LED on P1.0
\r
10
//IO on P5
\r
11
\r
12
//! Initialize registers and all that jazz.
\r
13
void init(){
\r
14
WDTCTL = WDTPW + WDTHOLD; // Stop watchdog timer
\r
15
\r
16
//LED and TX OUT
\r
17
P1DIR = 0x03;
\r
18
\r
19
//Enable Interrupts.
\r
20
//eint();
\r
21
}
\r
22
\r
23
//! Main loop.
\r
24
int main(void)
\r
25
{
\r
26
volatile unsigned int i;
\r
27
init();
\r
28
\r
29
while(1){
\r
30
i = 10000;
\r
31
while(i--);
\r
32
\r
33
P1OUT^=1; // Blink
\r
34
}
\r
35
}
\r
36
\r