Changeset 1653

Show
Ignore:
Timestamp:
09/04/09 12:41:36 (13 years ago)
Author:
arnonym
Message:

Implement getting a simple list of all current peaks.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/libffado/src/dice/dice_eap.cpp

    r1651 r1653  
    15661566Device::EAP::Router::getPeakValues() 
    15671567{ 
    1568     // To be implemented by ppalmers 
    1569     return PeakValues(); 
     1568    m_peak.read(); 
     1569    Control::CrossbarRouter::PeakValues values; 
     1570    for (unsigned int i=0; i<m_peak.getNbRoutes(); ++i) { 
     1571        Control::CrossbarRouter::PeakValue tmp; 
     1572        RouterConfig::Route route = m_peak.getRoute(i); 
     1573        tmp.destination = getDestinationIndex(route.dst, route.dstChannel); 
     1574        tmp.peakvalue = route.peak; 
     1575        values.push_back(tmp); 
     1576    } 
     1577    return values; 
    15701578} 
    15711579 
  • trunk/libffado/src/libcontrol/CrossbarRouter.h

    r1651 r1653  
    5454    struct PeakValue 
    5555    { 
    56         int source; 
    5756        int destination; 
    5857        double peakvalue;