Benjamin van den Hout wrote: > Hi all, Hi Benjamin, > I've been lurking on the list, mainly because I'm a very happy PJSIP > user and managed to solve any problems I encountered myself with the > help of the documentation :) Cool! > Anyway, in my application I want to monitor the number of received RTP > packets periodically. Sometimes I encounter scenario's when the RTP > stream just stops but no BYE is sent (due to a flaky piece of software > on the other side). So I want to build in some sort of 'safeguard' to > detect this scenario. > > I've looked at the siprtp.c but that seems like it is re-implementing a > lot of standard library behaviour. I really like the simplicity of the > high-level PJSUA api (I'm not doing that much interesting in my app > anyway). Basically all I'm looking for is some basic info about the > number of received RTP packets that I can query from some sort of > helper-thread. > > Can you suggest something to get me started off in the right direction? > Your help is greatly appreciated! The easiest probably is access the media stream of the call and get the media statistics from there, similar to pjsua_call_dump() and dump_media_session() in pjsua_call.c. You'll have to include <pjsua-lib/pjsua_internal.h> for this purpose. cheers, -benny > Kind regards, > Benjamin van den Hout > > > ------------------------------------------------------------------------ > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org -- Benny Prijono http://www.pjsip.org