forked driver
Dependents: ESHD_L475VG_IOT01-Sensors-BSP
Diff: MB85RSxx_SPI.cpp
- Revision:
- 3:f31e1990e1f3
- Parent:
- 2:9a0f9faada7f
--- a/MB85RSxx_SPI.cpp Fri Aug 18 05:27:05 2017 +0000 +++ b/MB85RSxx_SPI.cpp Fri Aug 30 06:13:56 2019 +0000 @@ -36,8 +36,21 @@ _di_p(new DigitalOut(nss)), _di(*_di_p) { + char sts; + printf("SPI pointer %x\n", _spi_p); + printf("SPI_CS pointer %x\n", _di_p); + _spi.format(8,0); - _spi.frequency(10000000); + _spi.frequency(2000000); + + _spi.write(RDID); + for(int i=0; i<8; i++) + { + sts=_spi.write(0x00); + printf("byte%i %x\n", i, sts); + } + printf("\n\n"); + } MB85RSxx_SPI::~MB85RSxx_SPI()