About dm8127 ISS ISP IPIPE 2D Edge Enhancer,I have two question.
Q1:
IPIPE 2D Edge Enhancer register can be read,but can not be written.
To read and write the iss registers,modify the code as follows.
1、Modify the *ipnc_rdk\ipnc_mcfw\demos\mcfw_api_demos\itt_capture.c to add write command.
The modified code as follows:
#define CMD_REGS_WRITE (20) //define cmd_wirte
Int32 ittServer_run()
{
....
else if (recvData[0] == CMD_REGS_READ)
{
...
break;
}
//add write command
else if (recvData[0] == CMD_REGS_WRITE)
{
cmd = recvData[0];
ittMsg->arg1 = recvData[1];
ittMsg->arg2 = recvData[2];
MessageQ_setMsgId(msg, cmd);
MessageQ_setReplyQueue(hIttMsgQ, msg);
status = MessageQ_put(remoteQ, msg);
ITT_ASSERT(status == MessageQ_S_SUCCESS);
status = MessageQ_get(hIttMsgQ, &msg, MessageQ_FOREVER);
ITT_ASSERT(status == MessageQ_S_SUCCESS);
printf("Response from M3 is : %d\n", ittMsg->response);
recvData[0] = ittMsg->response;
recvData[1] = 0;
recvData[2] = 0;
recvData[3] = 0;
recvData[4] = 0;
status =ittServer_SendData(connectedSocketId, (unsigned char *)recvData, dataSize);
break;
}
//add write command end
......
}
2、Modify the ipnc_rdk/ipnc_mcfw/mcfw/src_bios6/links_m3vpss/camera/alg_itk_link_tsk_tsk.c->Alg_ITK_Link_tskMain
function to add write command.
The modified code as follows:
Void Alg_ITK_Link_tskMain(struct Utils_TskHndl * pTsk, Utils_MsgHndl * pMsg)
{
.....
else if (cmd == CMD_REGS_READ) // ISP reg data
{
''''
}
//add write command
else if (cmd == CMD_REGS_WRITE) // Write reg
{
if ((ittMsg->arg1 >= 0x55050400) &&
((ittMsg->arg1) <= 0x55051480))
{
*(int *) (ittMsg->arg1) = ittMsg->arg2;
ittMsg->response = 1;
}
else
{
ittMsg->response = 0;
}
if(msg != NULL)
{
status = MessageQ_put(sender, (MessageQ_Msg) msg);
UTILS_assert(status == MessageQ_S_SUCCESS);
}
}
////add write command
......
}
3、We use ./tcp_client_x86 to read and write iss registers.
For example:
./tcp_client_x86 192.168.42.84 -r 0x55050ad4 0x1 //read IPIPE_YEE_EN register
./tcp_client_x86 192.168.42.84 -w 0x55050ad4 0x1 //set IPIPE_YEE_EN register to 0x1
We can read all iss registers and write some registers,such as IPIPE_SRC_VSZ、IPIPE_SRC_HSZ etc,
but can not change the 2D Edge Enhancer registers value,
Why?
When the system_server and ipnc_rdk_mcfw.out are running,the 2D Edge Enhancer registers value can not be modified?
Q2:
When set IPIPE_YEE_EN[0] to 0, the camera can not output normal h.264.
Modify the iss_02_00_00_00/packages/ti/psp/iss/hal/iss/isp/ipipe/src/ipipc.c-->ipipe_config_edge_enhancement
function as follows:
ISP_RETURN ipipe_config_edge_enhancement(ipipe_ee_cfg_t * cfg)
{
....
ISP_WRITE32(ipipe_reg->YEE_EN, 0);
return ISP_SUCCESS;
}
The video Image flicker,The camera output H.264 as follows:
or
Anybody have good idea? or give us some advice?