[WIP] sprintf_s to sprintfSExt

parent 4dfe730e
......@@ -274,7 +274,7 @@ the preprocessor change these values to strings:
then we can use in:
sprintf_s(infoBuff, bufCharCount, "platform[%s] configuration[%s]",
__sprintfSExt(infoBuff, bufCharCount, "platform[%s] configuration[%s]",
VS_PLATFORM,
VS_CONFIGURATION);
......
......@@ -352,9 +352,23 @@ typedef struct {
} STC_traceAcq;
//================================================================
//================================================================
namespace lima
{
namespace Pco
{
class Camera;
#define SIZEARR_stcPcoHWIOSignal 10
#define SIZESTR_PcoHWIOSignal 1024
struct stcPcoData
......@@ -503,7 +517,8 @@ struct stcPcoData
time_t ts[DIM_ACTION_TIMESTAMP];
} action_timestamp;
stcPcoData();
stcPcoData(Camera *);
Camera *m_cam;
void traceAcqClean();
......@@ -523,6 +538,8 @@ struct stcPcoData
}; // struct stcPcoData
} // Pco
} // lima
......@@ -1151,7 +1168,6 @@ namespace lima
void getLastImgFifo(int & val);
char *__sprintfExt(char* _ptr, char* _ptrMax, const char* format, ...);
}; // class camera
} // namespace pco
......@@ -1159,6 +1175,7 @@ namespace lima
void _pco_time2dwbase(double exp_time, DWORD &dwExp, WORD &wBase);
int __sprintfSExt(char* ptr, size_t nrMax, const char* format, ...);
//================================================================
......
......@@ -540,7 +540,7 @@ int BufferCtrlObj::_xferImag_buff2lima(DWORD &dwFrameIdx, int &bufIdx)
if(dbgWaitobj)
{
char msg[256];
sprintf_s(msg, sizeof(msg), "... PROCESS PCObuff[%d] TO LIMAbuff[%d] frame[%d]", bufIdx, lima_buffer_nb, dwFrameIdx);
__sprintfSExt(msg, sizeof(msg), "... PROCESS PCObuff[%d] TO LIMAbuff[%d] frame[%d]", bufIdx, lima_buffer_nb, dwFrameIdx);
DEB_ALWAYS() << msg;
}
m_pcoData->traceAcq.nrImgAcquired = dwFrameIdx;
......@@ -714,7 +714,7 @@ int BufferCtrlObj::_xferImag()
if(dbgWaitobj)
{
char msg[512];
sprintf_s(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] recordState[%d] live[%d]", bufIdx, dwFrameFirst2assign, recording, live_mode);
__sprintfSExt(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] recordState[%d] live[%d]", bufIdx, dwFrameFirst2assign, recording, live_mode);
m_cam->m_tmpLog->add(msg); DEB_ALWAYS() << msg;
}
if( (error = _assignImage2Buffer(
......@@ -734,7 +734,7 @@ int BufferCtrlObj::_xferImag()
m_cam->_pco_GetBufferStatus(sBufNr, &dwStatusDll, &dwStatusDrv,errPco);
char msg[128];
sprintf_s(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
__sprintfSExt(msg, sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
DEB_ALWAYS() << "... PCO_GetBufferStatus: " << msg;
}
}
......@@ -776,7 +776,7 @@ int BufferCtrlObj::_xferImag()
if(dbgWaitobj)
{
char msg[256];
sprintf_s(msg,sizeof(msg),"... LOOP inside while dwFrameIdx[%d] <= dwRequestedFrames[%d]", dwFrameIdx, dwRequestedFrames);
__sprintfSExt(msg, sizeof(msg),"... LOOP inside while dwFrameIdx[%d] <= dwRequestedFrames[%d]", dwFrameIdx, dwRequestedFrames);
DEB_ALWAYS() << msg;
}
......@@ -821,7 +821,7 @@ int BufferCtrlObj::_xferImag()
if(!found)
{
char msg[256];
sprintf_s(msg,sizeof(msg),"... ERROR - dwFrameIdx[%d] not found in the assigned buffers",dwFrameIdx);
__sprintfSExt(msg, sizeof(msg),"... ERROR - dwFrameIdx[%d] not found in the assigned buffers",dwFrameIdx);
DEB_ALWAYS() << msg;
}
......@@ -884,7 +884,7 @@ int BufferCtrlObj::_xferImag()
if(dbgWaitobj)
{
char msg[256];
sprintf_s(msg,sizeof(msg),"... WAITOBJ [%d] found", eventRet);
__sprintfSExt(msg, sizeof(msg),"... WAITOBJ [%d] found", eventRet);
DEB_ALWAYS() << msg;
}
}
......@@ -893,7 +893,7 @@ int BufferCtrlObj::_xferImag()
{
char msg[256];
sprintf_s(msg,sizeof(msg),
__sprintfSExt(msg, sizeof(msg),
"err[0x%lx] dwStatusDll[0x%lx] dwStatusDrv[0x%lx] \n"
"sBufNr[%d] WAITOBJ[%d] dwFrameIdx[%d] iLoopsPolled[%d] msTimeout[%d]\n",
errPco, dwStatusDll, dwStatusDrv,
......@@ -925,7 +925,7 @@ int BufferCtrlObj::_xferImag()
if(dbgWaitobj)
{
char msg[256];
sprintf_s(msg, sizeof(msg), "... EVENT FIRED buffNr[%d] dwBuffFrame[%d] dwFrameIdx[%d] dwStatusDll[0x%08lx] dwStatusDrv[0x%08lx] err[0x%x], iLoopsPolled[%d]",
__sprintfSExt(msg, sizeof(msg), "... EVENT FIRED buffNr[%d] dwBuffFrame[%d] dwFrameIdx[%d] dwStatusDll[0x%08lx] dwStatusDrv[0x%08lx] err[0x%x], iLoopsPolled[%d]",
sBufNr, dwBuffFrame, dwFrameIdx, dwStatusDll, dwStatusDrv, errPco, iLoopsPolled);
DEB_ALWAYS() << msg;
}
......@@ -956,7 +956,7 @@ int BufferCtrlObj::_xferImag()
if(dbgWaitobj)
{
char msg[256];
sprintf_s(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] live[%d]", bufIdx, dwFrameFirst2assign, live_mode);
__sprintfSExt(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] live[%d]", bufIdx, dwFrameFirst2assign, live_mode);
DEB_ALWAYS() << msg;
}
......@@ -981,7 +981,7 @@ int BufferCtrlObj::_xferImag()
if(dbgWaitobj)
{
char msg[256];
sprintf_s(msg, sizeof(msg), "... BYPASSED ASSIGN BUFFER[%d] dwFrameFirst2assign[%d] dwRequestedFrames[%d] live[%d]",
__sprintfSExt(msg, sizeof(msg), "... BYPASSED ASSIGN BUFFER[%d] dwFrameFirst2assign[%d] dwRequestedFrames[%d] live[%d]",
bufIdx, dwFrameFirst2assign, dwRequestedFrames, live_mode);
DEB_ALWAYS() << msg;
}
......@@ -2270,7 +2270,7 @@ int BufferCtrlObj::_xferImagDoubleImage()
bufIdx = iEvent;
if(dbgWaitobj){
sprintf_s(msg, RING_LOG_BUFFER_SIZE, "... ASSIGN BUFFER[%d] frame[%d]", bufIdx, dwPcoFrameFirst2assign);
__sprintfSExt(msg, RING_LOG_BUFFER_SIZE, "... ASSIGN BUFFER[%d] frame[%d]", bufIdx, dwPcoFrameFirst2assign);
m_cam->m_tmpLog->add(msg); DEB_ALWAYS() << msg;
}
......@@ -2384,7 +2384,7 @@ _RETRY:
m_cam->_pco_GetBufferStatus(sBufNr, &dwStatusDll, &dwStatusDrv,errPco);
if((dwStatusDll != 0x80000000) || dwStatusDrv || errPco)
{
sprintf_s(msg, sizeof(msg),"SDK ERROR got frame[%d / %d] bufIdx[%d] size[%ld] dest[%p] src[%p] \n"
__sprintfSExt(msg, sizeof(msg),"SDK ERROR got frame[%d / %d] bufIdx[%d] size[%ld] dest[%p] src[%p] \n"
"dwStatusDll[%08x] dwStatusDrv[%08x] errPco[%08x] err[%s]\n",
dwPcoFrameIdx, dwPcoRequestedFrames, bufIdx,
size, ptrLimaBuffer, ptrPcoBuffer,
......@@ -2533,7 +2533,7 @@ _RETRY_WAIT:
for(int _id = 0; _id<m_cam->m_pco_buffer_nrevents; _id++)
{
flag = m_allocBuff.bufferAssignedFrameFirst[_id] == dwPcoFrameIdx ? "***" : " ";
ptr += sprintf_s(ptr, ptrMax - ptr,
ptr += __sprintfSExt(ptr, ptrMax-ptr,
"\n%s [%d] pcoBuffNr[%d] ready[%d] limaFrame[%d] limaPtr[%p] limaPtr1[%p] pcoPtr[%p] limaSize[%d] pcoSize[%d]",
flag, _id,
m_allocBuff.pcoAllocBufferNr[_id],
......
This diff is collapsed.
......@@ -973,7 +973,7 @@ void Camera::_waitForRecording(int nrFrames, DWORD &_dwValidImageCnt, DWORD &_dw
char _msg[LEN_MSG + 1];
sprintf_s(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
_traceMsg(_msg);
m_pcoData->traceAcq.fnId = fnId;
......@@ -1039,7 +1039,7 @@ void Camera::_waitForRecording(int nrFrames, DWORD &_dwValidImageCnt, DWORD &_dw
if( ((DWORD) nb_frames > _dwMaxImageCnt) ){
nb_frames_fixed = true;
sprintf_s(msgErr,LEN_ERROR_MSG,
__sprintfSExt(msgErr,LEN_ERROR_MSG,
"=== %s [%d]> ERROR INVALID NR FRAMES fixed nb_frames[%d] _dwMaxImageCnt[%d]",
fnId, __LINE__, nb_frames, _dwMaxImageCnt);
printf("%s\n", msgErr);
......@@ -1150,7 +1150,7 @@ void Camera::_waitForRecording(int nrFrames, DWORD &_dwValidImageCnt, DWORD &_dw
m_pcoData->traceAcq.endXferTimestamp = m_pcoData->msAcqXferTimestamp = getTimestamp();
sprintf_s(_msg, LEN_MSG, "%s [%d]> [EXIT] imgRecorded[%d] coc[%g] recLoopTime[%ld] "
__sprintfSExt(_msg, LEN_MSG, "%s [%d]> [EXIT] imgRecorded[%d] coc[%g] recLoopTime[%ld] "
"tout[(%ld) 0(%ld)] rec[%ld] xfer[%ld] all[%ld](ms)\n",
fnId, __LINE__, _dwValidImageCnt, msPerFrame, msNowRecordLoop, timeout, timeout0, msRecord, msXfer, msTotal);
_traceMsg(_msg);
......
This diff is collapsed.
......@@ -146,14 +146,14 @@ void Camera::_pco_GetCameraInfo(int &error){
char *ptr = validPixelRate;
char *ptrMax = ptr + sizeof(validPixelRate);
ptr += sprintf_s(ptr, ptrMax - ptr, "validRates:");
ptr += __sprintfSExt(ptr, ptrMax - ptr, "validRates:");
for(int i=0; i<4; i++)
{
_dwPixRate = m_pcoData->stcPcoDescription.dwPixelRateDESC[i];
if(_dwPixRate > 0)
{
dwPixelRateValid[iPixelRateValidNr++] = _dwPixRate;
ptr += sprintf_s(ptr, ptrMax - ptr, " [%d]",_dwPixRate);
ptr += __sprintfSExt(ptr, ptrMax - ptr, " [%d]",_dwPixRate);
}
if(dwPixelRateMax < _dwPixRate){
dwPixelRateMax = m_pcoData->dwPixelRateMax = _dwPixRate;
......
This diff is collapsed.
This diff is collapsed.
......@@ -49,7 +49,7 @@ Camera::Camera(const char *params) :
if(m_tmpLog == NULL)
throw LIMA_HW_EXC(Error, "m_tmpLog > creation error");
m_pcoData =new stcPcoData();
m_pcoData =new stcPcoData(this);
if(m_pcoData == NULL)
throw LIMA_HW_EXC(Error, "m_pcoData > creation error");
......@@ -130,7 +130,7 @@ void _pco_acq_thread_dimax(void *argin) {
BufferCtrlObj* m_buffer = m_cam->_getBufferCtrlObj();
char _msg[LEN_MSG + 1];
sprintf_s(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
m_cam->_traceMsg(_msg);
m_cam->_sprintComment(true, fnId, "[ENTRY]");
......@@ -203,7 +203,7 @@ void _pco_acq_thread_dimax(void *argin) {
if( (dwPcoRequestedFrames > _dwPcoMaxImageCnt) ){
nb_frames_fixed = true;
sprintf_s(msgErr,LEN_ERROR_MSG,
__sprintfSExt(msgErr,LEN_ERROR_MSG,
"=== %s [%d]> ERROR INVALID NR FRAMES fixed nb_frames[%d] _dwPcoMaxImageCnt[%d]",
fnId, __LINE__, dwPcoRequestedFrames, _dwPcoMaxImageCnt);
printf("%s\n", msgErr);
......@@ -338,7 +338,7 @@ void _pco_acq_thread_dimax(void *argin) {
m_pcoData->traceAcq.endXferTimestamp = m_pcoData->msAcqXferTimestamp = getTimestamp();
sprintf_s(_msg, LEN_MSG, "%s [%d]> [EXIT] imgRecorded[%d] coc[%g] recLoopTime[%ld] "
__sprintfSExt(_msg, LEN_MSG, "%s [%d]> [EXIT] imgRecorded[%d] coc[%g] recLoopTime[%ld] "
"tout[(%ld) 0(%ld)] rec[%ld] xfer[%ld] all[%ld](ms)\n",
fnId, __LINE__, _dwPcoValidImageCnt, msPerFrame, msNowRecordLoop, timeout, timeout0, msRecord, msXfer, msTotal);
m_cam->_traceMsg(_msg);
......@@ -437,7 +437,7 @@ void _pco_acq_thread_dimax_trig_single(void *argin) {
if( ((DWORD) nb_frames > _dwMaxImageCnt) ){
nb_frames_fixed = true;
sprintf_s(msgErr,LEN_ERROR_MSG,
__sprintfSExt(msgErr,LEN_ERROR_MSG,
"=== %s [%d]> ERROR INVALID NR FRAMES fixed nb_frames[%d] _dwMaxImageCnt[%d]",
fnId, __LINE__, nb_frames, _dwMaxImageCnt);
printf("%s\n", msgErr);
......@@ -585,7 +585,7 @@ void _pco_acq_thread_edge(void *argin) {
BufferCtrlObj* m_buffer = m_cam->_getBufferCtrlObj();
char _msg[LEN_MSG + 1];
sprintf_s(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
m_cam->_traceMsg(_msg);
m_cam->_sprintComment(true, fnId, "[ENTRY]");
......@@ -625,7 +625,7 @@ void _pco_acq_thread_edge(void *argin) {
m_pcoData->msAcqXfer = msXfer = msElapsedTime(tStart);
sprintf_s(_msg, LEN_MSG, "%s> [EXIT] xfer[%ld] (ms) status[%s]\n",
__sprintfSExt(_msg, LEN_MSG, "%s> [EXIT] xfer[%ld] (ms) status[%s]\n",
fnId, msXfer, sPcoAcqStatus[status]);
m_cam->_traceMsg(_msg);
......@@ -664,7 +664,7 @@ void _pco_acq_thread_dimax_live(void *argin) {
BufferCtrlObj* m_buffer = m_cam->_getBufferCtrlObj();
char _msg[LEN_MSG + 1];
sprintf_s(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
m_cam->_traceMsg(_msg);
struct stcPcoData *m_pcoData = m_cam->_getPcoData();
......@@ -698,7 +698,7 @@ void _pco_acq_thread_dimax_live(void *argin) {
// dimax xfer time
m_pcoData->msAcqXfer = msXfer = msElapsedTime(tStart);
m_pcoData->msAcqXferTimestamp = getTimestamp();
sprintf_s(_msg, LEN_MSG, "%s> [EXIT] xfer[%ld] (ms) status[%s]\n",
__sprintfSExt(_msg, LEN_MSG, "%s> [EXIT] xfer[%ld] (ms) status[%s]\n",
fnId, msXfer, sPcoAcqStatus[status]);
m_cam->_traceMsg(_msg);
......@@ -718,7 +718,7 @@ void _pco_acq_thread_ringBuffer(void *argin) {
BufferCtrlObj* m_buffer = m_cam->_getBufferCtrlObj();
char _msg[LEN_MSG + 1];
sprintf_s(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
m_cam->_traceMsg(_msg);
m_cam->_sprintComment(true, fnId, "[ENTRY]");
......@@ -787,7 +787,7 @@ void _pco_acq_thread_ringBuffer(void *argin) {
usElapsedTimeSet(usStart);
if(error) {
sprintf_s(_msg, LEN_MSG, "%s> [%d]> ERROR %s", fnId, __LINE__, msg);
__sprintfSExt(_msg, LEN_MSG, "%s> [%d]> ERROR %s", fnId, __LINE__, msg);
m_cam->_traceMsg(_msg);
//throw LIMA_HW_EXC(Error, "_pco_SetRecordingState");
}
......@@ -803,7 +803,7 @@ void _pco_acq_thread_ringBuffer(void *argin) {
m_pcoData->msAcqXferTimestamp =
getTimestamp();
sprintf_s(_msg, LEN_MSG, "%s> EXIT xfer[%ld] (ms) status[%s]",
__sprintfSExt(_msg, LEN_MSG, "%s> EXIT xfer[%ld] (ms) status[%s]",
fnId, msXfer, sPcoAcqStatus[status]);
m_cam->_traceMsg(_msg);
......@@ -857,7 +857,7 @@ void _pco_shutter_thread_edge(void *argin) {
//SyncCtrlObj* m_sync = m_cam->_getSyncCtrlObj();
char _msg[LEN_MSG + 1];
sprintf_s(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [ENTRY]", fnId);
m_cam->_traceMsg(_msg);
m_cam->_sprintComment(true, fnId, "[ENTRY]");
......@@ -865,7 +865,7 @@ void _pco_shutter_thread_edge(void *argin) {
m_cam->_pco_set_shutter_rolling_edge(error);
sprintf_s(_msg, LEN_MSG, "%s> [EXIT]", fnId);
__sprintfSExt(_msg, LEN_MSG, "%s> [EXIT]", fnId);
m_cam->_traceMsg(_msg);
//m_sync->setStarted(false); // to test
......
......@@ -334,7 +334,7 @@ int BufferCtrlObj::_xferImag()
if(m_cam->_getDebug(DBG_WAITOBJ))
{
char msg[512];
sprintf_s(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] recordState[%d] live[%d]", bufIdx, dwFrameFirst2assign, recording, live_mode);
__sprintfSExt(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] recordState[%d] live[%d]", bufIdx, dwFrameFirst2assign, recording, live_mode);
m_cam->m_tmpLog->add(msg); DEB_ALWAYS() << msg;
}
......@@ -356,7 +356,7 @@ int BufferCtrlObj::_xferImag()
m_cam->_pco_GetBufferStatus(sBufNr, &dwStatusDll, &dwStatusDrv,errPco);
char msg[128];
sprintf_s(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
__sprintfSExt(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
DEB_ALWAYS() << "... PCO_GetBufferStatus: " << msg;
}
......@@ -439,7 +439,7 @@ _RETRY:
if(m_cam->_getDebug(DBG_WAITOBJ))
{
char msg[256];
sprintf_s(msg,sizeof(msg),"buffNr[%d] dwBuffFrame[%d] dwFrameIdx[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]",
__sprintfSExt(msg,sizeof(msg),"buffNr[%d] dwBuffFrame[%d] dwFrameIdx[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]",
sBufNr, dwBuffFrame, dwFrameIdx, dwStatusDll, dwStatusDrv, errPco);
DEB_ALWAYS() << "... PCO_GetBufferStatus: " << msg;
}
......@@ -460,7 +460,7 @@ _RETRY:
if(m_cam->_getDebug(DBG_WAITOBJ))
{
char msg[512];
sprintf_s(msg, sizeof(msg), "... PROCESS PCObuff[%d] TO LIMAbuff[%d] frame[%d]", bufIdx, lima_buffer_nb, dwFrameIdx);
__sprintfSExt(msg, sizeof(msg), "... PROCESS PCObuff[%d] TO LIMAbuff[%d] frame[%d]", bufIdx, lima_buffer_nb, dwFrameIdx);
DEB_ALWAYS() << msg;
}
m_pcoData->traceAcq.nrImgAcquired = dwFrameIdx;
......@@ -483,14 +483,14 @@ _RETRY:
if(m_cam->_getDebug(DBG_WAITOBJ))
{
char msg[128];
sprintf_s(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
__sprintfSExt(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
DEB_ALWAYS() << "... PCO_GetBufferStatus: " << msg;
}
// if((dwStatusDll != 0x80000000) || dwStatusDrv || errPco) {
if(0) {
char msg[MSG1K];
sprintf_s(msg,MSG1K,"SDK ERROR got frame[%d / %d] bufIdx[%d] size[%ld] dest[%p] src[%p] \n"
__sprintfSExt(msg,MSG1K,"SDK ERROR got frame[%d / %d] bufIdx[%d] size[%ld] dest[%p] src[%p] \n"
"dwStatusDll[%08x] dwStatusDrv[%08x] errPco[%08x] err[%s]\n",
dwFrameIdx, dwRequestedFrames, bufIdx,
size, ptrDest, ptrSrc,
......@@ -546,7 +546,7 @@ _RETRY:
{
char msg[128];
//ResetEvent(m_allocBuff.bufferAllocEvent[bufIdx]);
sprintf_s(msg, sizeof(msg), "... RESETING BUFFER BUFFER[%d] frame[%d] live[%d]", bufIdx, dwFrameFirst2assign, live_mode);
__sprintfSExt(msg, sizeof(msg), "... RESETING BUFFER BUFFER[%d] frame[%d] live[%d]", bufIdx, dwFrameFirst2assign, live_mode);
DEB_ALWAYS() << msg;
}
else
......@@ -555,7 +555,7 @@ _RETRY:
{
if(m_cam->_getDebug(DBG_WAITOBJ))
{
sprintf_s(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] live[%d]", bufIdx, dwFrameFirst2assign, live_mode);
__sprintfSExt(msg, sizeof(msg), "... ASSIGN BUFFER[%d] frame[%d] live[%d]", bufIdx, dwFrameFirst2assign, live_mode);
m_cam->m_tmpLog->add(msg); DEB_ALWAYS() << msg;
}
......@@ -574,7 +574,7 @@ _RETRY:
m_cam->_pco_GetBufferStatus(sBufNr, &dwStatusDll, &dwStatusDrv,errPco);
char msg[128];
sprintf_s(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
__sprintfSExt(msg,sizeof(msg),"buffNr[%d] dwStatusDll[%08lx] dwStatusDrv[%08lx] err[%x]", sBufNr, dwStatusDll, dwStatusDrv, errPco);
DEB_ALWAYS() << "... PCO_GetBufferStatus: " << msg;
}
......@@ -662,7 +662,7 @@ _RETRY_WAIT:
for(int _id = 0; _id<m_cam->m_pco_buffer_nrevents; _id++)
{
flag = m_allocBuff.bufferAssignedFrameFirst[_id] == dwFrameIdx ? "***" : " ";
ptr += sprintf_s(ptr, ptrMax - ptr,
ptr += __sprintfSExt(ptr, ptrMax - ptr,
"\n%s [%d] pcoBuffNr[%d] ready[%d] limaFrame[%d] limaPtr[%p] pcoPtr[%p] limaSize[%d] pcoSize[%d]",
flag, _id,
m_allocBuff.pcoAllocBufferNr[_id],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment