-/*! \file spi.c
+/*! \file twe.c
\author EiNSTeiN_ <einstein@g3nius.org>
\brief Atmel 2-wire EEPROM
*/
CLRSCL;
delay_us(15);
}
- //~ else {
- //~ SETSDA;
- //~ }
-
return rd;
}
twe_tx(0xa0); // preamble=1010, device adr=000, write=0
// output address bytes
- //~ debughex((adr >> 8) & 0xff);
twe_tx((adr >> 8) & 0xff);
- //~ debughex(adr & 0xff);
twe_tx(adr & 0xff);
// start command / read
twe_start();
twe_stop();
-
-
}
//! Handles a monitor command.