我用DM642提供的PDF文件里的那些API
试图将一个磁盘上的图象文件读入RAM后,再将图象的二维数组内容通过PCI写入DM642的SDRAM中
但是运行的时候,PC机就死机了,并且DSP板子上的指示灯也不再闪烁
请问是什么问题造成的呢?会不会是写入的格式不一样?
我是用的8位的写入方式,即调用SI_TI_PassThroughWrite8(...)函数
void PassThroughWrite() { int i; INT32 error; UINT32 region = 0; UINT32 offset = 0; UINT32 count = IMAGEWIDTH;//*sizeof(IMAGEDATA_TYPE); for(i=0;i<IMAGEHEIGHT;i++) { error = SI_TI_PassThroughWrite8 ( pTIDev, region, count, offset, IrL ); if (e_Err_NoError != error) printf("ERROR MESSAGE = %s
",error); offset += count; }
for(i=0;i<IMAGEHEIGHT;i++) { error = SI_TI_PassThroughWrite8 ( pTIDev, region, count, offset, IgL ); if (e_Err_NoError != error) printf("ERROR MESSAGE = %s
",error); offset += count; }
for(i=0;i<IMAGEHEIGHT;i++) { error = SI_TI_PassThroughWrite8 ( pTIDev, region, count, offset, IbL ); if (e_Err_NoError != error) printf("ERROR MESSAGE = %s
",error); offset += count; }
for(i=0;i<IMAGEHEIGHT;i++) { error = SI_TI_PassThroughWrite8 ( pTIDev, region, count, offset, IrR ); if (e_Err_NoError != error) printf("ERROR MESSAGE = %s
",error); offset += count; }
for(i=0;i<IMAGEHEIGHT;i++) { error = SI_TI_PassThroughWrite8 ( pTIDev, region, count, offset, IgR ); if (e_Err_NoError != error) printf("ERROR MESSAGE = %s
",error); offset += count; }
for(i=0;i<IMAGEHEIGHT;i++) { error = SI_TI_PassThroughWrite8 ( pTIDev, region, count, offset, IbR ); if (e_Err_NoError != error) printf("ERROR MESSAGE = %s
",error); offset += count; } printf("TEST WRITE COMPLETE!
"); printf("
Press enter to continue:"); getchar();
} |