|
Dec 11 ’09
SSI does MAXIM RTCYet another application for our SSI object. We have successfully used our SSI to interface with the DS3234 “extremely accurate” SPI RTC.
Dec 10 ’09
SSI does Microchip Port Expanders!G’day folks, it hasn’t even been a week since we published our SSI object, and we already found an application for it. We used the SSI to control Microchip’s MCP23017 16-bit port expander. For those of you who never tested this, Microchip port expanders are I2C or SPI ICs that give you 8 or 16 I/O lines. Add something like this to our (relatively low-pin count EM1206) and you get 16 additional I/O lines for <1US$! Without further ado, here is the code that setups an I2C channel, configures all I/O lines of the MCP23017 as outputs, and writes &hAA55 to the output ports:
Nov 22 ’09
A smarter way to format your flash disk (for debugging)How much flash space do you allocate for your flash disk? Normal answer is “the rest of it”. That is, take all space not occupied by your code: fd.format(fd.availableflashspace,32) This works, except when you are actively developing/debugging and your project keeps getting bigger, thus encroaching onto the disk space and forcing you to format your disk all the time. Here is an elegant solution: leave some spare space for the project to grow: fd.format(fd.availableflashspace/2,32) This way, formatting will happen a lot less. You can also improve it this way: if sys.runmode=DEBUG then fd.format(fd.availableflashspace/2,32) Smart, huh?
|