root 4 years ago
parent
commit
dfb37a5488
  1. 6
      lib/App/common/hardwareResourceSerialProvider.cpp

6
lib/App/common/hardwareResourceSerialProvider.cpp

@ -1227,7 +1227,9 @@ int hardwareResourceSerialProvider::sendBlock(unsigned char* Data, int DataSize)
// setRTS( 1 ); // setRTS( 1 );
do{ do{
#if defined( USE_WIRINGPI ) || defined( USE_WIRINGX ) #if defined( USE_WIRINGPI ) || defined( USE_WIRINGX )
if( m_bManualRTS ) digitalWrite( 0, HIGH );
if( m_bManualRTS ) {
digitalWrite( 0, HIGH );
};
#endif #endif
RetVal = write( m_iOutFID, Data, DataSize); RetVal = write( m_iOutFID, Data, DataSize);
if( m_bManualRTS ){ if( m_bManualRTS ){
@ -1235,7 +1237,7 @@ int hardwareResourceSerialProvider::sendBlock(unsigned char* Data, int DataSize)
do { do {
int r = ioctl( m_iOutFID, TIOCSERGETLSR, &lsr ); int r = ioctl( m_iOutFID, TIOCSERGETLSR, &lsr );
} while (!(lsr & TIOCSER_TEMT)); } while (!(lsr & TIOCSER_TEMT));
#ifdef defined( USE_WIRINGPI ) || defined( USE_WIRINGX )
#if defined( USE_WIRINGPI ) || defined( USE_WIRINGX )
digitalWrite( 0, LOW); digitalWrite( 0, LOW);
#endif #endif
}; };

Loading…
Cancel
Save