| Title: | MRU Internal Bug Reports |
| Moderator: | COOKIE::STMARTIN |
| Created: | Wed Sep 20 1995 |
| Last Modified: | Wed Jun 04 1997 |
| Last Successful Update: | Fri Jun 06 1997 |
| Number of topics: | 346 |
| Total number of notes: | 1175 |
There is a section of the MRD.3mrd manual page that had the mrd_eject.c example. Unfortunately, this example wasn't appropriate in the context of the text. I have been promising Steve an example for entirely too long...
| T.R | Title | User | Personal Name | Date | Lines |
|---|---|---|---|---|---|
| 322.1 | Close this when Steve uses it. | NABETH::alan | Dr. File System's Home for Wayward Inodes. | Thu Apr 10 1997 20:03 | 24 |
The section needing the example is the description of the
Operating System interface routines using absolute element
addresses.
/*
* Given an robot_info_t initialized with mrd_startup(3mrd)
* or mrd_show(3mrd), an element type and a relative element
* address, convert it to an absolute address.
*/
convert_relative(robot_info_t *robot_info, int type, int element)
{
switch( type )
case SLOT:
return element + robot_info->slot_start ;
case TRANSPORT:
return element + robot_info->transport_start ;
case DRIVE:
return element + robot_info->device_start ;
case PORT:
return element + robot_info->port_start ;
default:
return -1 ;
}
}
| |||||