千兆网相机软触发程序自动退出

在使用千兆网相机进行软触发时遇到程序自动退出的问题,错误提示为“segment error”或“double free or corruption”。环境配置为iPORT SDK 2.4.1、Pro1000-2.6.9-55.EL.ko驱动及Red Hat Enterprise Linux (2.6.9-55.EL)系统。通过在ReceiveAnswer函数前增加20ms延时可暂时规避问题。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

千兆网相机软触发程序自动退出,并有如下提示:
segment error
或者
“*** glibc detected *** double free or corruption (fasttop): 0xb7d00678 ***
目前原因定位在连续读写串口时,程序会出现段错误。

测试千兆网软触发时出现以下问题:
My environment is following:
iPORT SDK version is 2.4.1
driver is Pro1000-2.6.9-55.EL.ko
OS is Red Hat Enterprise Linux (2.6.9-55.EL)

Problem is following:
After connect IP engine,I only execute the following loop:
CyDevice *lDevice = &(lGrabber.GetDevice());
While(1)
{
    unsigned char lData[14];
    unsigned char lReceiveData[14];
    unsigned int lDataSize = 14;
    lDevice->ResetAnswerQueue( CyDevice::PORT_SERIAL_0 );
    lDevice->SendCommand( CyDevice::PORT_SERIAL_0, lData, sizeof( lData ) )
    lDevice->ReceiveAnswer( CyDevice::PORT_SERIAL_0, &lReceiveData, &lDataSize );
}
After circle thousands of times, “segment error”  or “*** glibc detected *** double free or corruption (fasttop): 0xb7d00678 ***” will occur in function lDevice->ResetAnswerQueue.But this error does not occur in windows XP.

解决千兆网相机软触发程序自动退出:
在ReceiveAnswer函数前加20ms延时。但还需要长时间的测试。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值