Delta Tau GEO BRICK LV User Manual

Page of 440
Turbo PMAC User Manual 
Writing a Host Communications Program
 
393
 
We will keep the same base address of Turbo PMAC from our previous example.  The following tables 
show the contents of the mailbox registers as we do this: 
Address 
$7FA001 $7FA003 $7FA005 $7FA007 $7FA009 $7FA00B 
Mailbox # 
0 1 2 3 4 5 
Character 
 
--- 
 
 
 
 
Address 
$7FA001 $7FA003 $7FA005 $7FA007 $7FA009 $7FA00B 
Mailbox # 
0 1 2 3 4 5 
Character 
 
--- 
1 J   
 
 
Address 
$7FA001 $7FA003 $7FA005 $7FA007 $7FA009 $7FA00B 
Mailbox # 
0 1 2 3 4 5 
Character 
 
--- 
1 J +   
 
Address 
$7FA001 $7FA003 $7FA005 $7FA007 $7FA009 $7FA00B 
Mailbox # 
0 1 2 3 4 5 
Character 
 
--- 
1 J + 
<CR> 
 
Address 
$7FA001 $7FA003 $7FA005 $7FA007 $7FA009 $7FA00B 
Mailbox # 
0 1 2 3 4 5 
Character 
--- 
1 J + 
<CR> 
We first write an ASCII 1 to location $7FA005, then a J to $7FA007, then a + to $7FA009, then a 
carriage return (ASCII code 13) to $7FA010, and finally a # to $7FA001. 
Example: 
The above example works just fine for a command line of 15 characters or less (including the <CR> 
added to terminate the line), but what if the command line contains more than 15 characters?  Remember 
there are only 15 mailbox registers that can be written to (do not forget that mailbox #1 cannot be used 
when sending data to Turbo PMAC.).   
Send the first 15 characters (do not send a <CR> yet!), followed by the remaining characters in succession 
until all characters have been written.  And after the last character, send the <CR>, which tells Turbo 
PMAC to act upon the command.  If downloading a motion program and one of the statements in the 
program happens to be the following line:  
IF(P1=1)DISPLAY"DELTA TAU"<CR> 
There are 27 characters here to send, and thus 27 VME write commands must be performed.  The 
following tables again show the contents of the mailbox registers.  After writing the first group of 14 
characters (the characters F through Y in the above command line), the mailbox registers look something 
like this: 
Address 
$7FA001 $7FA003 $7FA005 ... $7FA01D  $7FA01F 
Mailbox # 
0 1 2 
... 
14 15 
Character 
 
--- 
A Y 
Now, write the first character I
Address 
$7FA001 $7FA003 $7FA005 ... $7FA01D  $7FA01F 
Mailbox # 
0 1 2 
... 
14 15 
Character 
--- 
A Y