Trying out the Winbond W25N library so I can use the NAND based SPI flash W25N01GVZEIG with the ESP32. Use case is to store GPS ASCII strings and/or GPS binary data (Ublox UBX protocol) to flash.
The example "WriteString" that comes with the library does not compile on any ESP32 board but it compiles ok with many AVR boards.
Adding (uint8_t*) to each line that was causing the error fixed the problem.
There was a typo in your example with unit8_t (instead of uint8_t) so that threw me for a while. In the end this worked well.
SPI.transfer((uint8_t*)cmdbuf, sizeof(cmdbuf));
For others trying this out, the SPI bus was too fast in the example "WriteString". Hardware was PCB board and tracks less than 20mm long.
Slowing the SPI bus by changing SPI.beginTransaction(SPISettings(80000000, MSBFIRST, SPI_MODE0)); to SPI.beginTransaction(SPISettings(10000000, MSBFIRST, SPI_MODE0));
Apologies for that, the text was correct, the code not I will correct the code line.
You can mark your thread as "solved" by clicking the solution checkbox under the most useful post. That will let others know that a solution was provided that solved the problem.