Mercurial > templog
comparison main.c @ 123:b2700c7e5492
turn off the fridge port first
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Wed, 10 Oct 2012 22:50:02 +0800 |
parents | 30c2c3341a4a |
children | b32ddec655c5 |
comparison
equal
deleted
inserted
replaced
122:30c2c3341a4a | 123:b2700c7e5492 |
---|---|
212 | 212 |
213 // 3.3v power for bluetooth and SD | 213 // 3.3v power for bluetooth and SD |
214 DDR_LED |= _BV(PIN_LED); | 214 DDR_LED |= _BV(PIN_LED); |
215 DDR_SHDN |= _BV(PIN_SHDN); | 215 DDR_SHDN |= _BV(PIN_SHDN); |
216 | 216 |
217 PORT_FRIDGE &= ~_BV(PIN_FRIDGE); | |
217 DDR_FRIDGE |= _BV(PIN_FRIDGE); | 218 DDR_FRIDGE |= _BV(PIN_FRIDGE); |
218 PORT_FRIDGE &= ~_BV(PIN_FRIDGE); | |
219 | 219 |
220 // set pullup | 220 // set pullup |
221 PORTD |= _BV(PD2); | 221 PORTD |= _BV(PD2); |
222 // INT0 setup | 222 // INT0 setup |
223 EICRA = (1<<ISC01); // falling edge - data sheet says it won't work? | 223 EICRA = (1<<ISC01); // falling edge - data sheet says it won't work? |