Changeset 1865

Show
Ignore:
Timestamp:
07/09/10 06:02:44 (2 years ago)
Author:
jwoithe
Message:

RME: more experimental work with the streaming system.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/libffado/src/libstreaming/rme/RmeReceiveStreamProcessor.cpp

    r1857 r1865  
    131131 
    132132        // Timestamps are not transmitted explicitly by the RME interfaces 
    133         // so we'll have to fake it somehow in order to fit in with the 
    134         // rest of the FFADO infrastructure.  For now just take the current 
    135         // value of the cycle timer as the "last timestamp".  In practice  
    136         // there a fixed offset that we'll have to include eventually. 
    137 uint32_t ct = m_Parent.get1394Service().getCycleTimer(); 
     133        // so we'll have to fake it somehow in order to fit in with the rest 
     134        // of the FFADO infrastructure.  For now just take the packet 
     135        // arrival time as the "last timestamp".  In practice there is a 
     136        // fixed offset that we'll have to include eventually. 
    138137//        m_last_timestamp = CYCLE_TIMER_TO_TICKS(ctm_Parent.get1394Service().getCycleTimer()); 
    139         m_last_timestamp = CYCLE_TIMER_TO_TICKS(ct); 
    140 debugOutput(DEBUG_LEVEL_VERBOSE, "  timestamp: %lld, ct=%08x (%03ld,%04ld,%04ld)\n", m_last_timestamp, ct
    141   CYCLE_TIMER_GET_SECS(ct), CYCLE_TIMER_GET_CYCLES(ct), CYCLE_TIMER_GET_OFFSET(ct)); 
     138        m_last_timestamp = CYCLE_TIMER_TO_TICKS(pkt_ctr); 
     139debugOutput(DEBUG_LEVEL_VERBOSE, "  timestamp: %lld, ct=%08x (%03ld,%04ld,%04ld)\n", m_last_timestamp, pkt_ctr
     140  CYCLE_TIMER_GET_SECS(pkt_ctr), CYCLE_TIMER_GET_CYCLES(pkt_ctr), CYCLE_TIMER_GET_OFFSET(pkt_ctr)); 
    142141debugOutput(DEBUG_LEVEL_VERBOSE, "  %02x %02x %02x %02x %02x %02x %02x %02x\n", 
    143142  adata[0] & 0xff, adata[1] & 0xff, adata[2] & 0xff, adata[3] & 0xff, 
  • trunk/libffado/src/libstreaming/rme/RmeTransmitStreamProcessor.cpp

    r1857 r1865  
    310310    uint32_t pkt_ctr ) 
    311311{ 
     312static signed int cx = 0; 
    312313    debugOutput ( DEBUG_LEVEL_VERY_VERBOSE, "XMIT EMPTY: CY=%04u, TSP=%011llu (%04u)\n", 
    313314                CYCLE_TIMER_GET_CYCLES(pkt_ctr), m_last_timestamp,  
     
    330331RmeReceiveStreamProcessor *rxsp = static_cast<Rme::Device *> 
    331332  (&m_Parent)->getRxSP(); 
    332 debugOutput(DEBUG_LEVEL_VERBOSE, "hw tx: 0x%08x\n", rxsp->n_hw_tx_buffer_samples); 
    333 if (rxsp->n_hw_tx_buffer_samples < 0x38) 
     333debugOutput(DEBUG_LEVEL_VERBOSE, "tx timestamp: %lld, ct=%08x (%03ld,%04ld,%04ld)\n", 
     334  m_last_timestamp, pkt_ctr, CYCLE_TIMER_GET_SECS(pkt_ctr), CYCLE_TIMER_GET_CYCLES(pkt_ctr), CYCLE_TIMER_GET_OFFSET(pkt_ctr)); 
     335debugOutput(DEBUG_LEVEL_VERBOSE, "  hw tx: 0x%08x\n", rxsp->n_hw_tx_buffer_samples); 
     336//if (rxsp->n_hw_tx_buffer_samples < 0x38) 
     337if (cx < 7) { 
    334338        *length = getMaxPacketSize(); 
     339  cx++; 
     340} else 
     341  cx=0; 
    335342debugOutput(DEBUG_LEVEL_VERBOSE, "  txsize=%d\n", *length); 
    336343    }