takashi kadono
/
Nucleo_446
Color Oled(SSD1331) connect to STMicroelectronics Nucleo-F466
Diff: main.cpp
- Revision:
- 1:e396a61d2631
- Parent:
- 0:8fdf9a60065b
- Child:
- 2:018812000e6e
--- a/main.cpp Wed Oct 10 00:33:53 2018 +0000 +++ b/main.cpp Wed Oct 10 00:56:53 2018 +0000 @@ -8,7 +8,7 @@ public: SPI_LIB(PinName mosi,PinName miso,PinName sclk,PinName cs):_spi(mosi,miso,sclk),_cs(cs) { _spi.format(8,3); - _spi.frequency(500000); + _spi.frequency(1000000); } void SendData(uint8_t data) { @@ -46,9 +46,9 @@ thread.start(print_thread); while (true) { - for(uint8_t i=0; i<10; i++) { + for(uint8_t i=0; i<255; i++) { SPIx.SendData(i); - wait(1); + wait_us(100); } } } \ No newline at end of file