microseq.9 (06fc25611af1106374697b991e281c38d40b1213) | microseq.9 (a04dd7481b80786760f38ff3902e24851fc7ef37) |
---|---|
1.\" Copyright (c) 1998, 1999, Nicolas Souchu 2.\" All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. --- 58 unchanged lines hidden (view full) --- 67setting the direction bit (PCD) in the control register. Reads to this register 68return the value on the data lines. 69.Ss Device status register 70This read-only register reflects the inputs on the parallel port interface. 71.Pp 72.Bl -column "Bit" "Name" "Description" -compact 73.It Em Bit Ta Em Name Ta Em Description 74.It 7 Ta nBUSY Ta "inverted version of parallel port Busy signal" | 1.\" Copyright (c) 1998, 1999, Nicolas Souchu 2.\" All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. --- 58 unchanged lines hidden (view full) --- 67setting the direction bit (PCD) in the control register. Reads to this register 68return the value on the data lines. 69.Ss Device status register 70This read-only register reflects the inputs on the parallel port interface. 71.Pp 72.Bl -column "Bit" "Name" "Description" -compact 73.It Em Bit Ta Em Name Ta Em Description 74.It 7 Ta nBUSY Ta "inverted version of parallel port Busy signal" |
75.It 6 Ta nACK Ta "version of parellel port nAck signal" | 75.It 6 Ta nACK Ta "version of parallel port nAck signal" |
76.It 5 Ta PERROR Ta "version of parallel port PERROR signal" 77.It 4 Ta SELECT Ta "version of parallel port Select signal" 78.It 3 Ta nFAULT Ta "version of parallel port nFault signal" 79.El 80.Pp 81Others are reserved and return undefined result when read. 82.Ss Device control register 83This register directly controls several output signals as well as enabling --- 55 unchanged lines hidden (view full) --- 139.It 140the current value of the internal 141.Em branch register 142.El 143.Pp 144This data is modified by some of the microinstructions, not all. 145.Ss MS_OP_GET and MS_OP_PUT 146are microinstructions used to do either predefined standard IEEE1284-1994 | 76.It 5 Ta PERROR Ta "version of parallel port PERROR signal" 77.It 4 Ta SELECT Ta "version of parallel port Select signal" 78.It 3 Ta nFAULT Ta "version of parallel port nFault signal" 79.El 80.Pp 81Others are reserved and return undefined result when read. 82.Ss Device control register 83This register directly controls several output signals as well as enabling --- 55 unchanged lines hidden (view full) --- 139.It 140the current value of the internal 141.Em branch register 142.El 143.Pp 144This data is modified by some of the microinstructions, not all. 145.Ss MS_OP_GET and MS_OP_PUT 146are microinstructions used to do either predefined standard IEEE1284-1994 |
147transfers or programed non-standard io. | 147transfers or programmed non-standard io. |
148.Ss MS_OP_RFETCH - Register FETCH 149is used to retrieve the current value of a parallel port register, apply a 150mask and save it in a buffer. 151.Pp 152Parameters: 153.Bl -enum -offset indent 154.It 155register --- 100 unchanged lines hidden (view full) --- 256Parameter: 257.Bl -enum -offset ident 258.It 259integer return code 260.El 261.Pp 262Predefined macro: MS_RET(code) 263.Ss MS_OP_C_CALL - C function CALL | 148.Ss MS_OP_RFETCH - Register FETCH 149is used to retrieve the current value of a parallel port register, apply a 150mask and save it in a buffer. 151.Pp 152Parameters: 153.Bl -enum -offset indent 154.It 155register --- 100 unchanged lines hidden (view full) --- 256Parameter: 257.Bl -enum -offset ident 258.It 259integer return code 260.El 261.Pp 262Predefined macro: MS_RET(code) 263.Ss MS_OP_C_CALL - C function CALL |
264is used to call C functions from microsequence execution. This may be usefull | 264is used to call C functions from microsequence execution. This may be useful |
265when a non-standard i/o is performed to retrieve a data character from the 266parallel port. 267.Pp 268Parameter: 269.Bl -enum -offset ident 270.It 271the C function to call 272.It 273the parameter to pass to the function call 274.El 275.Pp 276The C function shall be declared as a 277.Fd int(*)(void *p, char *ptr) 278The ptr parameter is the current position in the buffer currently scanned. 279.Pp 280Predefined macro: MS_C_CALL(func,param) 281.Ss MS_OP_PTR - initialize internal PTR | 265when a non-standard i/o is performed to retrieve a data character from the 266parallel port. 267.Pp 268Parameter: 269.Bl -enum -offset ident 270.It 271the C function to call 272.It 273the parameter to pass to the function call 274.El 275.Pp 276The C function shall be declared as a 277.Fd int(*)(void *p, char *ptr) 278The ptr parameter is the current position in the buffer currently scanned. 279.Pp 280Predefined macro: MS_C_CALL(func,param) 281.Ss MS_OP_PTR - initialize internal PTR |
282is used to initilize the internal pointeur to the currently scanned buffer. | 282is used to initialize the internal pointer to the currently scanned buffer. |
283This pointer is passed to any C call (see above). 284.Pp 285Parameter: 286.Bl -enum -offset ident 287.It 288pointer to the buffer that shall be accessed by xxx_P() microsequence calls. 289Note that this pointer is automatically incremented during xxx_P() calls 290.El 291.Pp 292Predefined macro: MS_PTR(ptr) | 283This pointer is passed to any C call (see above). 284.Pp 285Parameter: 286.Bl -enum -offset ident 287.It 288pointer to the buffer that shall be accessed by xxx_P() microsequence calls. 289Note that this pointer is automatically incremented during xxx_P() calls 290.El 291.Pp 292Predefined macro: MS_PTR(ptr) |
293.Ss MS_OP_ADELAY - do an Asynchroneous DELAY | 293.Ss MS_OP_ADELAY - do an Asynchronous DELAY |
294is used to make a tsleep() during microsequence execution. The tsleep is 295executed at PPBPRI level. 296.Pp 297Parameter: 298.Bl -enum -offset ident 299.It 300delay in ms 301.El --- 120 unchanged lines hidden (view full) --- 422/* loop: */ MS_BRSET(H_ACK, 2 /* ready */), 423 MS_DBRA(-2 /* loop */), 424/* error: */ MS_RET(1), 425/* ready: */ MS_RET(0) 426 }; 427.Ed 428.Pp 429Here, some parameters are undefined and must be filled before executing | 294is used to make a tsleep() during microsequence execution. The tsleep is 295executed at PPBPRI level. 296.Pp 297Parameter: 298.Bl -enum -offset ident 299.It 300delay in ms 301.El --- 120 unchanged lines hidden (view full) --- 422/* loop: */ MS_BRSET(H_ACK, 2 /* ready */), 423 MS_DBRA(-2 /* loop */), 424/* error: */ MS_RET(1), 425/* ready: */ MS_RET(0) 426 }; 427.Ed 428.Pp 429Here, some parameters are undefined and must be filled before executing |
430the microsequence. In order to initialize seach a microsequence, one | 430the microsequence. In order to initialize each microsequence, one |
431should use the ppb_MS_init_msq() function like this: 432.Bd -literal 433 ppb_MS_init_msq(select_microseq, 2, 434 SELECT_TARGET, 1 << target, 435 SELECT_INITIATOR, 1 << initiator); 436.Ed 437.Pp 438and then execute the microsequence. --- 24 unchanged lines hidden --- | 431should use the ppb_MS_init_msq() function like this: 432.Bd -literal 433 ppb_MS_init_msq(select_microseq, 2, 434 SELECT_TARGET, 1 << target, 435 SELECT_INITIATOR, 1 << initiator); 436.Ed 437.Pp 438and then execute the microsequence. --- 24 unchanged lines hidden --- |