
#define M24C01 0x50	// 0101 0000

void main(void)
{
  P1M1 &= 0xEF;
  P1M1 |= 0x20;
  P1M2 &= 0xDF;
  P1M2 |= 0x10;

  P1 |= 0x10;
  i2c_init(0x00, 0);
  EA=1;
  while(1)
  {
    STA=1;
    i2c_transmit(M24C01);					// send peripherical address
    while(STA);// wait trans. to be completed (device address)
    STO=1;
  }
}
