spi

You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • As @allObjects says, I think this is specific to whatever SPI device you have. Usually, it works as follows:

    var data = SPI.send([command, 0xFF], csPin);
    result = data[1];
    

    So you send a command, then a 'no-op' byte (usually 0xFF or 0x00). Two bytes are returned - the first is useless, but the second will be the result of the SPI command.

About

Avatar for Gordon @Gordon started