h6. [[Programmer's Reference Manuals]] h6(. » [[List of modules]] h6((. » Portable h4. Introduction The Portable module was first introduced in the version of RISC OS 3 that ran on the A4 laptop. The module had three main functions: * "Power management":#power_management_features * "Display support":#display_support_features * "Responding to the extra keyboard hotkeys":#hotkey_features Although the A4 is the only native RISC OS portable machine to be released to date, the legacy of the Portable module lives on. Several key components of RISC OS (e.g. the Wimp) still contain active code that will attempt to interface with the Portable module if it is present. This has enabled developers to use the original Portable APIs as a framework upon which to implement their own versions of the module, to deal with the power management requirements of their own hardware. h4. Versions There are at least 8 variants of the Portable module in existence: * The A4 version, for the A4 portable * The Stork version, for the ill-fated Stork portable * ‘Portable75’, for ARM7500-based machines. The Portable75 source can also be used to build ‘PortableCX’, for CX24430-based machines. * ‘PortableHAL’, for HAL-based machines * The A9 version, for the A9/A9Home * The VirtualRPC and RPCEmu emulators each have their own versions of the module For an overview of which features are available in which version, see the [[Portable Feature Matrix|feature matrix]] h4(#power_management_features). Power Management Features The combined APIs and implementations of the different Portable modules offer the following power management features: * Battery charger control and battery monitoring. This includes emulators, where the module may report the battery status of the host machine. * CPU speed controls, to help reduce power consumption when the CPU is idle. * Hardware subsystem power controls, to turn off power to devices which aren’t currently needed. * Suspend-to-RAM functionality, to place the machine into a deep sleep state at the request of the user or after a certain period of inactivity. h4(#display_support_features). Display Support Features The A4 portable featured both a builtin greyscale LCD panel and a VGA connector for the attachment of an external monitor. For the LCD panel to function correctly the correct mode timings have to be used, along with a custom palette. Therefore the original Portable module had the job of ensuring that a suitable video mode is in use whenever the LCD panel is enabled, along with providing a method for the user to control whether the machine used the internal LCD panel or an external VGA monitor. The version of the Portable module used in the Stork portable fulfilled a similar role. h4(#hotkey_features). Hotkey Features The A4 and Stork both featured extra keys on the machine, which would generate key events when pressed. The purpose of these keys was to control hardware features such as adjusting the screen contrast and backlight; therefore in order for the keys to work the Portable module had to listen out for them, and take the appropriate action when each key was pressed. h4. Details * [[Portable Feature Matrix|Feature Matrix]] * [[Battery Management Unit status flags]] * [[Battery Management Unit variables]] * [[Portable Service Calls|Service Calls]] * [[Portable SWI Calls|SWI Calls]] * [[Portable *Commands|*Commands]] h4. See also [[Events]]