Changeset 11166 for trunk/FACT++/gui


Ignore:
Timestamp:
06/24/11 12:55:20 (13 years ago)
Author:
tbretz
Message:
Added PLL lock.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/gui/FactGui.h

    r11159 r11166  
    390390    DimStampedInfo fDimFadConnections;
    391391    DimStampedInfo fDimFadFwVersion;
     392    DimStampedInfo fDimFadPllLock;
    392393    DimStampedInfo fDimFadStatistics;
    393394
     
    11101111        fFadFwVersion->setToolTip(tip.str().c_str());
    11111112
    1112         SetLedColor(fFadLEDFwVersion, d.qos?kLedGreen:kLedOrange, d.time);
     1113        SetLedColor(fFadLedFwVersion, d.qos?kLedGreen:kLedOrange, d.time);
     1114    }
     1115
     1116    void handleFadPllLock(const DimData &d)
     1117    {
     1118        if (!CheckSize(d, 43*sizeof(uint8_t)))
     1119            return;
     1120
     1121        SetLedColor(fFadLedPllLock, d.qos?kLedGreen:kLedOrange, d.time);
     1122
     1123        const uint8_t *ptr = d.ptr<uint8_t>();
     1124
     1125        ostringstream tip;
     1126        tip << "<table border='1'><tr><th colspan='11'>" << Time().GetAsStr() << "</th></tr><tr><th></th>";
     1127        for (int b=0; b<10; b++)
     1128            tip << "<th>" << b << "</th>";
     1129        tip << "</tr>";
     1130
     1131        for (int c=0; c<4; c++)
     1132        {
     1133            tip << "<tr><th>" << c << "</th>";
     1134            for (int b=0; b<10; b++)
     1135            {
     1136                tip << "<td>"
     1137                    << (int)(ptr[c*10+b+3]&8)
     1138                    << (int)(ptr[c*10+b+3]&4)
     1139                    << (int)(ptr[c*10+b+3]&2)
     1140                    << (int)(ptr[c*10+b+3]&1)
     1141                    << "</td>";
     1142            }
     1143            tip << "</tr>";
     1144        }
     1145        tip << "</table>";
     1146
     1147        fFadLedPllLock->setToolTip(tip.str().c_str());
    11131148    }
    11141149
     
    19081943            return PostInfoHandler(&FactGui::handleFadFwVersion);
    19091944
     1945        if (getInfo()==&fDimFadPllLock)
     1946            return PostInfoHandler(&FactGui::handleFadPllLock);
     1947
    19101948        if (getInfo()==&fDimFadStatistics)
    19111949            return PostInfoHandler(&FactGui::handleFadStatistics);
     
    23492387        fDimFadConnections     ("FAD_CONTROL/CONNECTIONS",      (void*)NULL, 0, this),
    23502388        fDimFadFwVersion       ("FAD_CONTROL/FIRMWARE_VERSION", (void*)NULL, 0, this),
     2389        fDimFadPllLock         ("FAD_CONTROL/PLL_LOCK",         (void*)NULL, 0, this),
    23512390        fDimFadStatistics      ("FAD_CONTROL/STATISTICS",       (void*)NULL, 0, this)
    23522391    {
Note: See TracChangeset for help on using the changeset viewer.