18.08.2013 Views

(SYSLIB) Programming Reference Manual - Public Support Login ...

(SYSLIB) Programming Reference Manual - Public Support Login ...

(SYSLIB) Programming Reference Manual - Public Support Login ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

9.1.2. ASCII to Fieldata Conversion<br />

FDASC$–Fieldata/ASCII Data Conversion<br />

FDASC$ converts ASCII character strings to Fieldata when the ASCFD$ entry point is<br />

called.<br />

The following table lists the calling sequences.<br />

Auto Switch Common Bank or Relocatable Relocatable<br />

L,U A0,input-buffer-word- count<br />

L,U A1,input-buffer-address<br />

L,U A2,output-buffer-address<br />

LMJ X11,CBASCFD$-1<br />

normal return<br />

L,U A0,input-buffer-word- count<br />

L,U A1,input-buffer-address<br />

L,U A2,output-buffer-address<br />

I$BJ X11,CBASCFD$<br />

normal return<br />

L,U A0,input-buffer-word- count<br />

L,U A1,input-buffer-address<br />

L,U A2,output-buffer-address<br />

LMJ X11,ASCFD$<br />

normal return<br />

ASCFD$ converts the ASCII characters in the input buffer (four characters per word) to<br />

Fieldata and places them in the output buffer (six characters per word, with trailing<br />

space-fill if necessary). The length of the output buffer in words must be at least twothirds<br />

the length of the input buffer. The input buffer and the output buffer may specify<br />

the same buffer, since the string is converted head to tail to prevent overwriting.<br />

ASCFD$ returns the word length of the converted Fieldata image in register A0.<br />

9.2. TABLE$–Fieldata/ASCII Conversion Table<br />

TABLE$ contains the conversion codes for each ASCII and Fieldata character. Each<br />

word of TABLE$ has the ASCII to Fieldata code in H1 and the Fieldata to ASCII code in<br />

H2. The H2 portion of TABLE$ is used when the FDASC$ entry point is called; the H1<br />

portion is used when the ASCFD$ entry point is called.<br />

TABLE$ is 256 words long and has an entry point of ASCFDASC$. The H2 portion of the<br />

last 192 words (Fieldata to ASCII codes) is unused.<br />

TABLE$ is a relocatable element in the file SYS$LIB$*<strong>SYSLIB</strong> and is also collected in the<br />

<strong>SYSLIB</strong> common bank <strong>SYSLIB</strong>$3.<br />

7833 1733–004 9–3

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!