h6. [[OS SWI Calls]] h6(. » [[OS_Module]] h6((. » OS_Module 19 h2. OS_ Module 19 h5. (SWI &1E) |_<^{width:4em}. Entry | | |<^. R0 |<^. 19 (&13) | |<^. R1 |<^. Module number, or 0 to start | |<^. R2 |<^. [[ROM Sections|ROM section]] | |_<^{width:4em}. Exit | | |<^. R0 |<^. Preserved | |<^. R1 |<^. Module number of found module +1 | |<^. R2 |<^. [[ROM Sections|ROM section]] | |<^. R3 |<^. Pointer to module name | |<^. R4 |<^. [[OS_Module Status|Status]]| |<^. R5 |<^. Chunk number of expansion card module | h4. Use The purpose of this call is to enumerate ROM modules. h4. Notes This call returns information on one module that is currently in ROM along with its status. The module found is the given number of modules on from start of the given ROM section. If there are insufficient modules in the ROM section then the search continues with the next section; so the fifth module in a four module section would in fact be the first module of the next section. The ROM sections are scanned in order. The values in R0-R2 are the correct ones to use this call to enumerate the next module; hence repeated calls will give a full enumeration of all ROM modules. The PRM states that when the end of the list an 'No more modules' will be returned with error number &107. This is incorrect; error number &108 will be returned. (&107 relates to the module prefix). [[OS_Module 20]] is provides the same functionality, but in addition returns the version information (in R6). h4. See also * [[OS_Module]] * [[OS_Module 20]] * [[OS_Module Status]] * [[ROM Sections]]