Changeset 14372
- Timestamp:
- 08/14/12 12:30:05 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/smartfact.cc
r14362 r14372 705 705 return GetCurrentState(); 706 706 707 cout << d.GetQoS() << ": " << d.GetText() << endl;708 709 707 if (d.GetQoS()==90) 710 708 HandleControlMessageImp(d); … … 718 716 return StateMachineImp::kSM_KeepState; 719 717 720 // [0] DimControl::kReady (Idle) 721 // [1] DimControl::kLoad 722 // [2] DimControl::kStarted 723 if (d.GetQoS()==1 && fDimControl.scriptdepth==0) 724 fControlMessageHist.clear(); 725 726 // Not that this will also "ding" just after program startup 727 // if the dimctrl is still in state -3 728 if (fDimControl.last.second!=DimState::kOffline && 729 d.GetQoS()==0 && fDimControl.scriptdepth==0) 730 SetAudio("ding"); 718 if (fDimControl.scriptdepth>0) 719 return StateMachineImp::kSM_KeepState; 731 720 732 721 if (d.GetQoS()>=2) … … 739 728 #endif 740 729 741 HandleControlMessageImp(Event(d, fDimControl.shortmsg.data(), fDimControl.shortmsg.length()+1)); 742 if (!file.empty()) 730 // [0] DimControl::kReady (Idle) 731 // [1] DimControl::kLoad 732 // [2] DimControl::kStarted 733 if (d.GetQoS()==1) 734 { 735 fControlMessageHist.clear(); 736 HandleControlMessageImp(Event(d, "========================================", 41)); 737 } 738 739 HandleControlMessageImp(Event(d, ("----- "+fDimControl.shortmsg+" -----").data(), fDimControl.shortmsg.length()+13)); 740 if (!file.empty() && d.GetQoS()<2) 743 741 HandleControlMessageImp(Event(d, file.data(), file.length()+1)); 742 743 // Not that this will also "ding" just after program startup 744 // if the dimctrl is still in state -3 745 if (d.GetQoS()==0) 746 { 747 HandleControlMessageImp(Event(d, "========================================", 41)); 748 if (fDimControl.last.second!=DimState::kOffline) 749 SetAudio("ding"); 750 } 744 751 745 752 return StateMachineImp::kSM_KeepState; … … 1824 1831 1825 1832 if (&state==&fDimControl) 1826 return HTML::kGreen +'\t'+(state.state() <-2?"Idle":fDimControl.shortmsg)+'\n';1833 return HTML::kGreen +'\t'+(state.state()==0?"Idle":fDimControl.shortmsg)+'\n'; 1827 1834 1828 1835 const State rc = state.description(); … … 2513 2520 } 2514 2521 } 2515 if (fDimDNS.online() && fDimDriveControl.state()==0x100) // Armed, Moving, Tracking 2516 out << " [ERR]"; 2522 if (fDimDNS.online() && fDimDriveControl.state()==0x100) 2523 out << " <ERR>"; 2524 if (fDimDNS.online() && fDimDriveControl.state()==Drive::State::kLocked) 2525 out << " ⊗"; 2517 2526 out << '\n'; 2518 2527 … … 2651 2660 2652 2661 out.str(""); 2653 out << Header(now) << '\t' << (fErrorList.size()>0) << '\t' << (fDimControl.state()> -3) << '\n';2662 out << Header(now) << '\t' << (fErrorList.size()>0) << '\t' << (fDimControl.state()>0) << '\n'; 2654 2663 2655 2664 if (!fDimDNS.online())
Note:
See TracChangeset
for help on using the changeset viewer.