Cast away const for STM32

This commit is contained in:
Bill Greiman 2017-09-18 10:27:59 -07:00
parent 8b8776a5f1
commit ce5d0e9b31
2 changed files with 2 additions and 2 deletions

View file

@ -55,7 +55,7 @@ int csvReadText(File* file, char* str, size_t size, char delim) {
rtn = ch;
break;
}
if ((n+1) >= size) {
if ((n + 1) >= size) {
// string too long
rtn = -2;
n--;

View file

@ -111,7 +111,7 @@ void SdSpiAltDriver::send(const uint8_t* buf , size_t n) {
#if USE_STM32F1_DMAC
pSpi[m_spiPort]->dmaSend(const_cast<uint8*>(buf), n);
#else // #if USE_STM32F1_DMAC
pSpi[m_spiPort]->write(buf, n);
pSpi[m_spiPort]->write(const_cast<uint8*>(buf), n);
#endif // USE_STM32F1_DMAC
}
//-----------------------------------------------------------------------------