put the line var exports = {}; right at the top of it.
Copy the example initialisation code to after it, but replace require("ILI9163") with exports
So then it's a totally self-contained bit of code that you can send, tweak and debug quite quickly.
It looks like it behaves in an almost identical way - the bytes that are sent to set the pixels are identical. About the only thing that's different seems to be the bytes you have to send to initialise it...
So you just need to put this code into here and it should just start working! :)
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.
@JumJum thanks - just updated it on GitHub, so the next website update will have that fixed.
@Jorgen, that's a bit unfortunate! What I'd do is:
var exports = {};
right at the top of it.require("ILI9163")
withexports
So then it's a totally self-contained bit of code that you can send, tweak and debug quite quickly.
It looks like it behaves in an almost identical way - the bytes that are sent to set the pixels are identical. About the only thing that's different seems to be the bytes you have to send to initialise it...
So you just need to put this code into here and it should just start working! :)