Changeset 428
- Timestamp:
- 03/01/07 15:26:52 (16 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/streaming-rework/src/libstreaming/MotuStreamProcessor.cpp
r425 r428 917 917 // because we're going to update the buffer again this loop 918 918 // using writeframes 919 m_data_buffer->setBufferTailTimestamp(m_last_timestamp2); 920 921 debugOutput(DEBUG_LEVEL_VERBOSE,"On enable: last ts2=%lld\n",m_last_timestamp2); 919 // m_data_buffer->setBufferTailTimestamp(m_last_timestamp2); 920 m_data_buffer->setBufferTailTimestamp(m_last_timestamp); 921 922 debugOutput(DEBUG_LEVEL_VERBOSE,"On enable: last ts=%lld, ts2=%lld = %lld (%p)\n", 923 m_last_timestamp, m_last_timestamp2, m_last_timestamp-m_last_timestamp2, 924 m_data_buffer); 925 922 926 } else { 923 927 debugOutput(DEBUG_LEVEL_VERY_VERBOSE, … … 965 969 // Then it's just a matter of adding m_ticks_per_frame rather than frame_size times this. 966 970 uint32_t first_sph = ntohl(*(quadlet_t *)(data+8)); 971 //uint32_t first_sph = ntohl(*(quadlet_t *)(data+8+(event_length*(n_events-1)))); 967 972 // m_last_timestamp = ((first_sph & 0x1fff000)>>12)*3072 + (first_sph & 0xfff); 968 973 m_last_timestamp = CYCLE_TIMER_TO_TICKS(first_sph & 0x1ffffff); … … 987 992 uint64_t ts=addTicks(m_last_timestamp, 988 993 (uint64_t)(frame_size * m_ticks_per_frame)); 994 // uint64_t ts=addTicks(m_last_timestamp, 995 // (uint64_t)(m_ticks_per_frame)); 989 996 990 997 // set the timestamp as if there will be a sample put into … … 993 1000 ts -= TICKS_PER_SECOND; 994 1001 m_data_buffer->setBufferTailTimestamp(ts); 995 debugOutput(DEBUG_LEVEL_VERBOSE,"%p, last ts=%lld, ts=%lld, lts2=%lld\n", m_data_buffer, m_last_timestamp, ts, m_last_timestamp2);1002 //debugOutput(DEBUG_LEVEL_VERBOSE,"%p, last ts=%lld, ts=%lld, lts2=%lld\n", m_data_buffer, m_last_timestamp, ts, m_last_timestamp2); 996 1003 997 1004 return RAW1394_ISO_DEFER; … … 999 1006 1000 1007 debugOutput( DEBUG_LEVEL_VERY_VERBOSE, "put packet...\n"); 1001 debugOutput(DEBUG_LEVEL_VERBOSE,"enabled: %p, last ts=%lld, ts2=%lld\n",m_data_buffer, m_last_timestamp, m_last_timestamp2);1008 //debugOutput(DEBUG_LEVEL_VERBOSE,"enabled: %p, last ts=%lld, ts2=%lld\n",m_data_buffer, m_last_timestamp, m_last_timestamp2); 1002 1009 1003 1010 //=> process the packet branches/streaming-rework/src/libstreaming/StreamProcessor.cpp
r424 r428 73 73 IsoStream::dumpInfo(); 74 74 debugOutputShort( DEBUG_LEVEL_NORMAL, " StreamProcessor info:\n"); 75 debugOutputShort( DEBUG_LEVEL_NORMAL, " Now : %011u\n",m_handler->getCycleTimerTicks()); 75 if (m_handler) 76 debugOutputShort( DEBUG_LEVEL_NORMAL, " Now : %011u\n",m_handler->getCycleTimerTicks()); 76 77 debugOutputShort( DEBUG_LEVEL_NORMAL, " Xruns : %d\n", m_xruns); 77 78 debugOutputShort( DEBUG_LEVEL_NORMAL, " Running : %d\n", m_running); branches/streaming-rework/src/motu/motu_avdevice.cpp
r426 r428 73 73 // Free ieee1394 bus resources if they have been allocated 74 74 if (m_p1394Service != NULL) { 75 if (m_p1394Service->freeIsoChannel(m_iso_recv_channel)) {75 if (m_iso_recv_channel>=0 && m_p1394Service->freeIsoChannel(m_iso_recv_channel)) { 76 76 debugOutput(DEBUG_LEVEL_VERBOSE, "Could not free recv iso channel %d\n", m_iso_recv_channel); 77 78 77 } 79 if (m_p1394Service->freeIsoChannel(m_iso_send_channel)) {78 if (m_iso_send_channel>=0 && m_p1394Service->freeIsoChannel(m_iso_send_channel)) { 80 79 debugOutput(DEBUG_LEVEL_VERBOSE, "Could not free send iso channel %d\n", m_iso_send_channel); 81 82 80 } 83 81 }