Hi Sir, I install keil c7.10. and choose device dr80c390,and check arithmetic accelerator. compile pass. But the div and shift operate result is wrong. something like DWORD i,j,k; k = i / j; k = i << 4; I check assembly code . found that C?ULDIVDA: C:0x000E8B B80021 CJNE R0,#SectorCount(0x00),C:0EAF C:0x000E8E B9005A CJNE R1,#SectorCount(0x00),C:0EEB C:0x000E91 8FD3 MOV MA(0xD3),R7 C:0x000E93 8ED3 MOV MA(0xD3),R6 C:0x000E95 8DD3 MOV MA(0xD3),R5 C:0x000E97 8CD3 MOV MA(0xD3),R4 C:0x000E99 8BD4 MOV MB(0xD4),R3 C:0x000E9B 8AD4 MOV MB(0xD4),R2 C:0x000E9D E5D2 MOV A,MCNT1(0xD2) C:0x000E9F 20E7FB JB 0xE0.7,C:0E9D C:0x000EA2 ACD3 MOV R4,MA(0xD3) C:0x000EA4 ADD3 MOV R5,MA(0xD3) C:0x000EA6 AED3 MOV R6,MA(0xD3) C:0x000EA8 AFD3 MOV R7,MA(0xD3) C:0x000EAA ABD4 MOV R3,MB(0xD4) C:0x000EAC AAD4 MOV R2,MB(0xD4) C:0x000EAE 22 RET And I check dr80390 spec the multiplication and Divisioin unit is MD0 0XF9 MD1 0XFA MD2 0XFB MD3 0XFC MD4 0XFD MD5 0XFE ARCON 0XFF Am I wrong or there have some way to solve the problem? Thanks. Ding
So this means that this softcore is not Dallas 390 compatible. Can you move the MA register to the correct SFR address?
Does the soft core offer by keil. I don't know where to change the SFR address define. would you please tell me how? Thank you very much!
The softcore comes from Digital Core Design. See http://www.keil.com/dd.