comparison main.c @ 422:91e3d410ed51

turn off the fridge port first
author Matt Johnston <matt@ucc.asn.au>
date Wed, 10 Oct 2012 22:50:02 +0800
parents 5055caf46064
children b32ddec655c5
comparison
equal deleted inserted replaced
421:5055caf46064 422:91e3d410ed51
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?