diff --git a/cmRtSys.c b/cmRtSys.c index 348f484..5aee4b0 100644 --- a/cmRtSys.c +++ b/cmRtSys.c @@ -1232,6 +1232,46 @@ unsigned cmRtSysSubSystemCount( cmRtSysH_t h ) return p->ssCnt; } + +bool cmRtSysNetIsInitialized( cmRtSysH_t h ) +{ + cmRt_t* p = _cmRtHandleToPtr(h); + unsigned i = 0; + for(; issCnt; ++i) + if( cmRtNetIsInitialized(p->ssArray[i].netH) ) + return true; + return false; +} + + +cmRtRC_t cmRtSysNetDoSync( cmRtSysH_t h ) +{ + cmRtRC_t rc = kOkRtRC; + cmRt_t* p = _cmRtHandleToPtr(h); + unsigned i = 0; + for(; issCnt; ++i) + if( cmRtNetIsInitialized(p->ssArray[i].netH) ) + cmRtNetDoSync(p->ssArray[i].netH); + + return rc; +} + +cmRtRC_t cmRtSysNetReport( cmRtSysH_t h ) +{ + cmRtRC_t rc = kOkRtRC; + cmRt_t* p = _cmRtHandleToPtr(h); + unsigned i = 0; + for(; issCnt; ++i) + { + cmRptPrintf(p->err.rpt,"Sub-system:%i\n",i); + if( cmRtNetIsValid(p->ssArray[i].netH)) + cmRtNetDoSync(p->ssArray[i].netH); + } + return rc; + +} + + //=========================================================================================================================== // // cmRtTest() diff --git a/cmRtSys.h b/cmRtSys.h index 2c09c40..de1231c 100644 --- a/cmRtSys.h +++ b/cmRtSys.h @@ -319,6 +319,10 @@ extern "C" { // Audio system test and example function. void cmRtSysTest( cmCtx_t* ctx, int argc, const char* argv[] ); + bool cmRtSysNetIsInitialized( cmRtSysH_t h ); + cmRtRC_t cmRtSysNetDoSync( cmRtSysH_t h ); + cmRtRC_t cmRtSysNetReport( cmRtSysH_t h ); + #ifdef __cplusplus