A simple I2C master implementation on the MSP430
simplyembedded.org
simplyembedded.org
That's not to say that such platforms are bad (MSP430 has it's advantages and disadvantages depending on what you want to do with it), but more of a testament to the Wire library.
Here's the equivalent code for the Atmel peripheral: https://github.com/arduino/Arduino/blob/master/hardware/ardu...
Just went to find the page of internet archive:
web.archive.org has been blocked by Sky Broadband Shield, which lets you choose the websites that can be seen in your home.
I hate ISPs. If someone could update the link, that would be grand!http://webcache.googleusercontent.com/search?q=cache:gmd3HGA...
https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#5xx_...
This is much easier to implement than fully intercepting every HTTP connection, and this is what most ISPs go with.
But it's a bit off topic!
The code is also fully interrupt-driven, which is important for low-power applications.
Also I found these types particularly amusing. None of that code can be copy pasted without editing:
while ((err == 0) && (nbytes > 0))
But since it doesn't support interrupts, I think not being able to copy paste this code is generally a good thing.