projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
working beep at around 4khz
[fw/altos]
/
target
/
beep
/
beep.c
diff --git
a/target/beep/beep.c
b/target/beep/beep.c
index 08422082755f07067bbf5f3c67c8edc2a23d9eb1..09c915b7a0b0b069855fa42d4c8e926332527dcf 100644
(file)
--- a/
target/beep/beep.c
+++ b/
target/beep/beep.c
@@
-46,9
+46,11
@@
delay (unsigned char n)
unsigned char i = 0;
n <<= 1;
unsigned char i = 0;
n <<= 1;
- while (--n != 0)
+ while (--n != 0) {
+ i = 211;
while (--i != 0)
nop();
while (--i != 0)
nop();
+ }
}
void
}
void
@@
-78,12
+80,12
@@
low() {
main ()
{
CLKCON = 0;
main ()
{
CLKCON = 0;
- /* Set
p1_1
to output */
+ /* Set
P2_0
to output */
P2DIR = 0x01;
P1INP = 0x00;
P2INP = 0x00;
for (;;) {
high();
P2DIR = 0x01;
P1INP = 0x00;
P2INP = 0x00;
for (;;) {
high();
- low();
+/* low(); */
}
}
}
}