• Hi,

    1: IYO, what 'd be the best way to wire to those Sck & Data pins ?

    Probably opendrain with a pullup. Are you sure you're using all 5v capable pins? You shouldn't use any marked with 3.3v on http://www.espruino.com/Original#pinout

    Could it be that your hardware SPI is just going too fast? With a long wire and a 1.5k pullup it might just not be enough to produce a clear signal. Do you have an oscilloscope?

    2: any way to get hardware SPI working to increase the refresh rate & lessen cpu usage ?

    Could be the output speed as above. It's worth noting that hardware SPI doesn't decrease CPU usage, so actually the gains from it are not as much as you might think.

    3: would 'compiled' code helps in getting more precise & faster 'scheduled updates' ?

    Maybe, but honestly there are other things I would try first like removing console.log in things that have to do fast, and maybe trying some simple benchmarking with getTime to see what's slow.

    Honestly I think for everyone I've seen that has tried to use compiled this far it's been a huge mistake, so I would avoid it if at all possible.

    4: am I driving these correctly at all ? ( or what may the 'spi behavior'* come from ? )

    As above really - it could be the SPI speed you're trying to use with the level shifting via resistor. If you have an oscilloscope it would be a huge help.


Avatar for Gordon @Gordon started