diff --git a/src/USB2.cpp b/src/USB2.cpp index e469894e27c720dd005a1516df456d4356c95538..5e1f76ecc41efb954d1c15d23b7cea4da73b82f2 100644 --- a/src/USB2.cpp +++ b/src/USB2.cpp @@ -526,14 +526,17 @@ void USB2::write(const Tango::DevVarCharArray *argin) if(ret != 0 || bytes_written != bytes_to_write - bytes_total) { delete argin_data; - string error_mesg = "Unable to send request to device"; - close(); open(); + + string error_mesg = "Unable to send request to device"; DEBUG_STREAM << error_mesg << endl; + set_state( Tango::FAULT ); set_status( error_mesg ); + // TODO have we to wait? timeout is decreased? + Tango::Except::throw_exception( "", error_mesg, "USB2::write()");