Hitachi S10mini Hardware Manual page 51

Option j.net
Hide thumbs Also See for S10mini:
Table of Contents

Advertisement

4 USER GUIDE
J_RSP
Function
Link Procedure
long
(* j_rsp)();
long
rtn;
struct para
j_rsp=0xa00412;
rtn=(*j_rsp)(para);
The assembly language guarantees the contents of registers other than the
DO register that stores return codes. (In C, these registers are transparent to
the user.)
The J_RSP subroutine uses 128 bytes of the user program stack.
Parameters
struct para {
unsigned char mdl;
unsigned char sid;
unsigned char net;
unsigned char svc;
unsigned long adr;
unsigned short len;
} ;
Service code
Captures as many bytes of data as specified into the area specified by
parameters (valid when a response is received from the station as a result of
J_CMD command [READ] issuance).
C
*para;
/* Module No. (= 0 for main module; = 1 for sub-module) */
/* Station ID (/01 to /1F) */
/* Net No. (= 0 for N1; = 1 for N2) */
/* Service code */
/* Starting address of received data */
/* Number of bytes of received data (/01 to /FA) */
/32: Data write service
Assembly language
movea.l
#$a00412,a0
movea.l
#para,-(sp)
jsr
(a0)
addq.l
#4,sp
para:
Parameter
CAUTION
4-24

Advertisement

Table of Contents
loading

Table of Contents