Showing changes from revision #5 to #6:
Added | Removed | Changed
The Operating System makes extensive use of buffers as temporary holding areas for data. For example, when a character is typed on the keyboard, the character is stored in the keyboard input buffer by the keyboard interrupt handler, and remains there until it is ready to be used.
All buffers are handled by the Buffer Manager. This is used by DeviceFS to provide buffers for various devices to perform tasks such as:
Because the purpose of buffers is to store data before they are ready for use, the method of processing the data is First In, First Out (FIFO). This ensures that data loaded into the buffer first is removed first.
Some operations are not explicitly stated, such as when sending a character to the printer port, as this actually inserts the character into a buffer. There are several key buffer operations available:
With the exception of the mouse buffer, the data format is byte-orientated ASCII data. The keyboard buffer is provided in more detail within the Character Input? section.
RISC OS uses buffers to hold areas of files in memory to increase file access efficiency. The buffers are integrated into the Operating System and there is no direct way of accessing their contents. This section does not cover filing system buffers.
Changing buffer sizes is handled by the Buffer_Create and Buffer_Register. The Buffer Manager section documents other SWI calls. The printer buffer can be configured by the use of *Configure PrinterBufferSize.
Several OS_Byte SWI calls are also provided to control buffers: