That you can send multiple bytes at a time. I am using particle build and yet when I implement this I get “Build didn’t produce binary error: Command Failed…”
Parameters:
tx_buffer: array of Tx bytes that is filled by the user before starting the SPI transfer
rx_buffer: array of Rx bytes that will be filled by the slave during the SPI transfer
length: number of data bytes that are to be transferred
myFunction: user specified function callback to be called after completion of the SPI DMA transfer
I thought it might be worth asking if this happens if you comment out the SPI1.transfer too? This is also the classic symptom a file in the dev directory that is not a source file and you need to add to the ignore file. It's a long-shot but worth mentioning.
You are running into a missing HAL layer problem that has been fixed in the develop branch. The real error reported by the web IDE (build button) is:
^
../../../build/target/wiring/platform-6-m//libwiring.a(spark_wiring_spi.o): In function `SPIClass::transfer(void*, void*, unsigned int, void (*)())':
/spark/compile_service/shared/workspace/6_photon_18_1/firmware/wiring/src/spark_wiring_spi.cpp:164: undefined reference to `HAL_SPI_DMA_Transfer'
I recognized this immediately from this thread:
So you can compile locally or wait for 0.4.6 for the fix.
@bko, thank you, I did run into that post before posting mine actually. I guess I read it to quickly, because I missed the part where it was said it was in the developer branch.
Guess, I’ll have to wait. As for local compiling I wish Particle would make one set of instructions from scratch step by step and not assuming anything the user knows or does not on what to get and install, and lastly then create, compile and download.