Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of AkiSpiLcd by
Diff: AkiSpiLcd.cpp
- Revision:
- 20:5ae48914555f
- Parent:
- 19:b53d3942c983
- Child:
- 21:8de1035017b5
diff -r b53d3942c983 -r 5ae48914555f AkiSpiLcd.cpp --- a/AkiSpiLcd.cpp Wed Feb 10 09:37:21 2016 +0000 +++ b/AkiSpiLcd.cpp Tue May 10 19:55:55 2016 +0100 @@ -13,7 +13,7 @@ _csl=0; _csr=1; _spi.format(8,0); - _spi.frequency(10000000); + _spi.frequency(1000000); _comflag = _modeflag = _clearflag = 0; // if(_csr != NULL) { @@ -92,8 +92,10 @@ for (int j=0; j<=length; j++) { _spi.write( (_modeflag << 7) | (_comflag << 6) | (_clearflag << 5) ); _spi.write((uint8_t)lcd_line[line+1]); + for(int i=0; i<_width/8; i++) { - _spi.write( *(data+(_width/8*j+i)) ); + //_spi.write( *(data+(_width/8*j+i)) ); + _spi.write(__RBIT( *(data+(((_width/8)*j)+i)))>>24 ); } line+=1; }