qdosmsq:traps:trap_3:fbyt

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

qdosmsq:traps:trap_3:fbyt [2009/02/22 10:42] (current)
george.gwilt created
Line 1: Line 1:
 +====== IO_FBYTE/​IOB_FBYT ======
 +
 +This trap fetches a byte from a channel.
 +
 +^Call Parameters^^Return Parameters^^
 +|D0.B|$01|D0.L|Error code.|
 +|D1.L| |D1.B|Byte fetched.|
 +|D3.W|Timeout.|D3.L|Preserved.|
 +|A0.L|Channel ID |A0.L|Preserved.|
 +|A1.L| |A1.L|Corrupted.|
 +
 +===== Errors =====
 +|ERR_NC|Not complete.|
 +|ERR_NO|Channel not open.|
 +|ERR_EF|End of file.|
 +
 +
 +===== Notes =====
 +  * All registers not shown above are not used on entry and are preserved on exit.
 +  * If a byte is fetched from the file it is put into D1.B.
 +
 +===== Example =====
 +The example shows how to cause a delay of up to 100 ticks. It is assumed that the ID of a con channel is in A0.
 +
 +<​code>​
 +delay   ​moveq ​  #​100,​d3 ​        ; Timeout of 100 ticks.
 +        moveq   #​IO_FBYTE,​d0
 +        trap    #3              ; Wait for up to 100 ticks.
 +</​code>​
 +
  
  • qdosmsq/traps/trap_3/fbyt.txt
  • Last modified: 2009/02/22 10:42
  • by george.gwilt