/* matlab wrapper for ezcaGetTimeout */ /* Author: Till Straumann , 2002-2003 */ /* LICENSE: EPICS open license, see ../LICENSE file */ #include "mglue.h" #include #include void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[]) { LcaError theErr; lcaErrorInit(&theErr); LHSCHECK(nlhs, plhs); if ( 1 < nlhs ) { lcaSetError(&theErr, EZCA_INVALIDARG, "Need one output arg"); goto cleanup; } if ( 0 != nrhs ) { lcaSetError(&theErr, EZCA_INVALIDARG, "Expected no rhs argument"); goto cleanup; } if ( ! (plhs[0] = mxCreateDoubleMatrix( 1, 1, mxREAL )) ) { lcaSetError(&theErr, EZCA_FAILEDMALLOC, "Not enough memory"); goto cleanup; } *mxGetPr(plhs[0]) = ezcaGetTimeout(); nlhs = 0; cleanup: ERR_CHECK(nlhs, plhs, &theErr); }