Hi, A C function tries to call a assembly function via the interfacing way of c programs-to-assemnly interface. Founded it's failed and can't use step-into to watch the status of assembly function. The codes is as follows. Please give some comments for the issue. Tks!
The codes in C.
BYTE show1[3] ={0x0ff,0x02,0x03}; BYTE t_dat[3]; #pragma NOREGPARMS int wrxdata( BYTE *pDs, /* R1-R3*/ BYTE *pSr /*Fixed memory*/ ); main(){ wrxdata(&t_dat[0], &show1[0]); }
The assembly function.
NAME LB_LIBRARY ?PR?_WRXDATA?LB_LIBRARY SEGMENT CODE ?PD?_WRXDATA?LB_LIBRARY SEGMENT DATA OVERLAYABLE PUBLIC _WRXDATA, ?_WRXDATA?BYTE RSEG ?PD?_WRXDATA?LB_LIBRARY ; Segment for local variables ?_WRXDATA?BYTE: ; Start of the parameter passing seg pSr: DS 2 ; byte pointer variable: pSr pDs: DS 2 ; Additional local variables from 'function' RSEG ?PR?_WRXDATA?LB_LIBRARY ; Program segment _wrxdata: MOV DPTR,#?_WRXDATA?BYTE+0 MOVX A,@DPTR MOV DPTR,#?_WRXDATA?BYTE+2 MOVX @DPTR,A RET ; Return END
"A C function tries to call an assembly function via the interfacing way of c programs-to-assemnly interface."
ya, ok, Assembly cud call a c routine, but the required directives need be Included ie to say Connected
ok, now you cud take a tBRreak