30.11.2012 Views

The Internet Power Line Adapter - University of Queensland

The Internet Power Line Adapter - University of Queensland

The Internet Power Line Adapter - University of Queensland

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Home Automation, <strong>Power</strong> <strong>Line</strong>s and the <strong>Internet</strong> Quenten Alick<br />

}<br />

break;<br />

/*<br />

* Read command: get length byte<br />

*/<br />

case ISR_RCV_LEN:<br />

SPDR = 0;<br />

while(!spif) ; /* wait for transfer complete */<br />

transBfr.len = SPDR;<br />

ISRstate = ISR_RCV_BUF; /* change state */<br />

break;<br />

case ISR_RCV_BUF:<br />

if(transBfr.index == transBfr.len) {<br />

ISRstate = ISR_IDLE; /* done */<br />

} else {<br />

SPDR = 0;<br />

while(!spif) ;<br />

if (transBfr.len

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!