Changeset 1865
- Timestamp:
- 07/09/10 06:02:44 (2 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/libffado/src/libstreaming/rme/RmeReceiveStreamProcessor.cpp
r1857 r1865 131 131 132 132 // 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. 138 137 // 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); 139 debugOutput(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)); 142 141 debugOutput(DEBUG_LEVEL_VERBOSE, " %02x %02x %02x %02x %02x %02x %02x %02x\n", 143 142 adata[0] & 0xff, adata[1] & 0xff, adata[2] & 0xff, adata[3] & 0xff, trunk/libffado/src/libstreaming/rme/RmeTransmitStreamProcessor.cpp
r1857 r1865 310 310 uint32_t pkt_ctr ) 311 311 { 312 static signed int cx = 0; 312 313 debugOutput ( DEBUG_LEVEL_VERY_VERBOSE, "XMIT EMPTY: CY=%04u, TSP=%011llu (%04u)\n", 313 314 CYCLE_TIMER_GET_CYCLES(pkt_ctr), m_last_timestamp, … … 330 331 RmeReceiveStreamProcessor *rxsp = static_cast<Rme::Device *> 331 332 (&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) 333 debugOutput(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)); 335 debugOutput(DEBUG_LEVEL_VERBOSE, " hw tx: 0x%08x\n", rxsp->n_hw_tx_buffer_samples); 336 //if (rxsp->n_hw_tx_buffer_samples < 0x38) 337 if (cx < 7) { 334 338 *length = getMaxPacketSize(); 339 cx++; 340 } else 341 cx=0; 335 342 debugOutput(DEBUG_LEVEL_VERBOSE, " txsize=%d\n", *length); 336 343 }
