Changeset 11845 for trunk/FACT++/src/fscctrl.cc
- Timestamp:
- 08/08/11 14:58:23 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/fscctrl.cc
r11835 r11845 242 242 } 243 243 244 if (volt.size()!=84 || resist.size()!=64) 245 { 246 ostringstream out; 247 248 out << "Corrupted data received (" << volt.size() << " voltages and "; 249 out << resist.size() << "resistances; 84 and 64 expected)"; 250 Warn(out); 251 StartRead(); 252 return; 253 } 254 244 255 int mapv[] = 245 256 { … … 306 317 vector<float> temperatures; 307 318 308 for (int *pv=mapv; *pv> 0; pv++)319 for (int *pv=mapv; *pv>=0; pv++) 309 320 voltages.push_back(volt[*pv]); 310 321 311 for (int *pc=mapc; *pc> 0; pc++)322 for (int *pc=mapc; *pc>=0; pc++) 312 323 currents.push_back(volt[*pc]*5); 313 324 … … 325 336 326 337 int idx=0; 327 for (int *ph=maprh; *ph> 0; ph++, idx++)338 for (int *ph=maprh; *ph>=0; ph++, idx++) 328 339 humidities.push_back((volt[*ph]-offrh[idx])*0.0313); 329 340 330 for (int *pt=mapt; *pt> 0; pt++)341 for (int *pt=mapt; *pt>=0; pt++) 331 342 temperatures.push_back(resist[*pt]>800&&resist[*pt]<2000 ? GetTempPT1000(resist[*pt]) : 0); 332 343
Note:
See TracChangeset
for help on using the changeset viewer.