Title | Function | Function Name | No |
format void STM_SetTrFunc (StmHn stm, StmTrFunc func, void * obj) Input stm: Stream handle : func: Transfer function (STM_TR_NULLFUNC when canceling) obj: Registered object Output None Function value None Function Registers a transfer function for the specified stream. registration function is called during stream transfer processing. Remarks (a) The registration function has the following format. Sint32 (* StmTrFunc) (void * obj, StmHn stm, Sint32 nsct) obj: Registered object : : stm: stream handle nsct: Number of sectors that can be transferred (b) The registration object is passed to the first argument of the registration function. (c) The transfer function can transfer data of up to nsct sectors. : (d) Returns the number of sectors actually transferred in the function value. : If transfer is in progress at the end of the transfer function, such as DMA, (-1) must be returned.
Title | Function | Function Name | No |
format Uint32 * STM_StartTrans (StmHn stm, Sint32 * dadr) Input stm: Stream handle Output dadr: Change in source address for each longword transfer Function value Transfer source address Function Starts data transfer processing in the transfer function.
File type | Transfer source address change value |
|---|---|
CD-ROM file | 0 |
Memory file, SCSI file | 1 |
Remarks This function is used when STM_SctToWord and STM_WordToSct are used in the transfer function. Please call before executing .Example volatile Uint32 * src;
src = STM_StartTrans (stm, & dadr); for (i = 0; i < n; i ++) { * dst = * src; src + = dadr; dst ++;