You could do very slow software SPI pretty easily over a port expander, and could even write your own SPI class which you could feed into existing modules.
I have literally just made digitalWrite/Read able to use an object passed in, so assuming you're using a 'cutting edge' build of Espruino (or 1v95 when it's available), you should be able to do:
var spi = {
write : function() { SPI write code }
};
var cspin = {
write : function(v) { write value to pin }
};
var disp = require("MAX7219").connect(spi,cspin);
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
You could do very slow software SPI pretty easily over a port expander, and could even write your own
SPI
class which you could feed into existing modules.I have literally just made
digitalWrite/Read
able to use an object passed in, so assuming you're using a 'cutting edge' build of Espruino (or 1v95 when it's available), you should be able to do: