Changeset 12213
- Timestamp:
- 10/20/11 11:33:23 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/ConnectionUSB.cc
r11979 r12213 82 82 if (ec) 83 83 Error("Closing "+URL()+": "+ec.message()); 84 } 85 86 // Reset the connection status 87 fConnectionStatus = kDisconnected; 84 else 85 Info("Connection closed succesfully."); 86 } 88 87 89 88 // Stop deadline counters 90 89 fInTimeout.cancel(); 91 90 fOutTimeout.cancel(); 91 92 // Reset the connection status 93 fConnectionStatus = kDisconnected; 92 94 93 95 // Empty output queue … … 244 246 fConnectionStatus = kConnecting; 245 247 248 Info("Connecting to "+URL()+"."); 249 246 250 bs::error_code ec; 247 251 open(URL(), ec); 248 252 249 ostringstream msg;250 msg << "Connecting to " << URL() << "... ";251 253 if (ec) 252 msg << " " << ec.message() << " (" << ec << ")"; 253 else 254 msg << "success."; 255 256 if (ec) 257 { 254 { 255 ostringstream msg; 256 msg << "Error opening " << URL() << "... " << ec.message() << " (" << ec << ")"; 258 257 Error(msg); 259 258 fConnectionStatus = kDisconnected; … … 261 260 } 262 261 263 Info( msg);262 Info("Connection established."); 264 263 265 264 try … … 296 295 fBaudRate(115200), 297 296 fCharacterSize(8), fParity(parity::none), fStopBits(stop_bits::one), 298 fFlowControl(flow_control:: none),297 fFlowControl(flow_control::hardware), 299 298 fInTimeout(ioservice), fOutTimeout(ioservice), 300 299 fConnectionStatus(kDisconnected)
Note:
See TracChangeset
for help on using the changeset viewer.