Quieten some more debug messages. Fix a misleading clock status return.
This commit is contained in:
@@ -1279,7 +1279,7 @@ static abuf_t *buffer_get_frame(rtsp_conn_info *conn) {
|
||||
if (do_wait == 0)
|
||||
if ((conn->ab_synced != 0) && (conn->ab_read == conn->ab_write)) { // the buffer is empty!
|
||||
if (notified_buffer_empty == 0) {
|
||||
debug(1, "Buffers exhausted.");
|
||||
debug(3, "Buffers exhausted.");
|
||||
notified_buffer_empty = 1;
|
||||
// reset_input_flow_metrics(conn); // don't do a full flush parameters reset
|
||||
conn->initial_reference_time = 0;
|
||||
|
||||
+5
-1
@@ -82,7 +82,11 @@ int ptp_get_clock_info(uint64_t *actual_clock_id, uint64_t *raw_offset) {
|
||||
response = clock_no_master;
|
||||
}
|
||||
} else {
|
||||
response = clock_version_mismatch;
|
||||
// the version can not be zero. If zero is returned here, it means that the shared memory is not yet initialised, so not availalbe
|
||||
if (nqptp_data.version == 0)
|
||||
response = clock_service_unavailable;
|
||||
else
|
||||
response = clock_version_mismatch;
|
||||
}
|
||||
} else {
|
||||
response = clock_data_unavailable;
|
||||
|
||||
@@ -290,8 +290,8 @@ void *rtp_control_receiver(void *arg) {
|
||||
obfp += 2;
|
||||
};
|
||||
*obfp = 0;
|
||||
|
||||
|
||||
|
||||
|
||||
// get raw timestamp information
|
||||
// I think that a good way to understand these timestamps is that
|
||||
// (1) the rtlt below is the timestamp of the frame that should be playing at the
|
||||
@@ -302,19 +302,19 @@ void *rtp_control_receiver(void *arg) {
|
||||
// Thus, (3) the latency can be calculated by subtracting the second from the
|
||||
// first.
|
||||
// There must be more to it -- there something missing.
|
||||
|
||||
|
||||
// In addition, it seems that if the value of the short represented by the second
|
||||
// pair of bytes in the packet is 7
|
||||
// then an extra time lag is expected to be added, presumably by
|
||||
// the AirPort Express.
|
||||
|
||||
|
||||
// Best guess is that this delay is 11,025 frames.
|
||||
|
||||
|
||||
uint32_t rtlt = nctohl(&packet[4]); // raw timestamp less latency
|
||||
uint32_t rt = nctohl(&packet[16]); // raw timestamp
|
||||
|
||||
|
||||
uint32_t fl = nctohs(&packet[2]); //
|
||||
|
||||
|
||||
debug(1,"Sync Packet of %d bytes received: \"%s\", flags: %d, timestamps %u and %u,
|
||||
giving a latency of %d frames.",plen,obf,fl,rt,rtlt,rt-rtlt);
|
||||
//debug(1,"Monotonic timestamps are: %" PRId64 " and %" PRId64 "
|
||||
@@ -1413,12 +1413,9 @@ void *rtp_event_receiver(void *arg) {
|
||||
finished = 1;
|
||||
}
|
||||
} while (finished == 0);
|
||||
debug(1, "Connection %d: AP2 Event Receiver RTP thread \"normal\" exit.",
|
||||
conn->connection_number);
|
||||
pthread_cleanup_pop(1); // close the socket
|
||||
|
||||
pthread_cleanup_pop(1); // do the cleanup
|
||||
debug(1, "Connection %d: AP2 Event Receiver RTP thread exit.", conn->connection_number);
|
||||
debug(2, "Connection %d: AP2 Event Receiver RTP thread \"normal\" exit.", conn->connection_number);
|
||||
pthread_exit(NULL);
|
||||
}
|
||||
|
||||
|
||||
@@ -379,7 +379,7 @@ int get_play_lock(rtsp_conn_info *conn) {
|
||||
#else
|
||||
} else if (config.allow_session_interruption == 1) {
|
||||
#endif
|
||||
debug(1, "Connection %d: Asking Connection %d to stop playing.", conn->connection_number,
|
||||
debug(2, "Connection %d: Asking Connection %d to stop playing.", conn->connection_number,
|
||||
playing_conn->connection_number);
|
||||
playing_conn->stop = 1;
|
||||
interrupting_current_session = 1;
|
||||
@@ -406,7 +406,7 @@ int get_play_lock(rtsp_conn_info *conn) {
|
||||
}
|
||||
|
||||
if ((have_the_player == 1) && (interrupting_current_session == 1)) {
|
||||
debug(1, "Connection %d: got player lock", conn->connection_number);
|
||||
debug(2, "Connection %d: Got player lock", conn->connection_number);
|
||||
response = 1;
|
||||
} else {
|
||||
debug(1, "Connection %d: failed to get player lock", conn->connection_number);
|
||||
@@ -1398,7 +1398,7 @@ void handle_setrateanchori(rtsp_conn_info *conn, rtsp_message *req, rtsp_message
|
||||
debug(2, "Connection %d: Stop playing.", conn->connection_number);
|
||||
conn->ap2_play_enabled = 0;
|
||||
// not sure this is needed yet
|
||||
reset_anchor_info(conn); // needed if the player resumes
|
||||
// reset_anchor_info(conn); // needed if the player resumes
|
||||
}
|
||||
pthread_cleanup_pop(1); // unlock the conn->flush_mutex
|
||||
|
||||
|
||||
Reference in New Issue
Block a user