Fitting 'star' commands inside a Module
Colin Ferris (399) 1814 posts |
Is there a simple way of fitting ‘star’ commands / utils inside a ROM module – so they can be simply loaded at startup in one go? And then called from say – !Boot !Run Library Dir – inside Resources:$ maybe. |
Chris Mahoney (1684) 2165 posts |
You can have star commands in a “normal” (disc) module so I don’t see any reason why they couldn’t go in a ROM module. In fact, I think there’s already one called BootCommands with some things in it. Edit: “I don’t see any reason why not” indeed. Virtually every star command on a “clean” system will be coming from a ROM module of some sort! |
nemo (145) 2546 posts |
Star commands are an integral part of RISC OS Modules. Look at the Help and Command Keyword Table on this page |
Jon Abbott (1421) 2651 posts |
ResourceFS is probably what you’re after. Many ROM Modules will register resources during their Init so they’re available at boot. I believe several of the ROM based applications work that way as well, such as Edit, Draw etc |
Colin Ferris (399) 1814 posts |
Hmm – will have a look at that. Have tried to load ‘BootCmds’ ver 1.48 from ‘VirtualRPC-DL/Plugins/hostservices/Chunks’ but no go – some of the cmd’s give a error on !boot running. Like ‘IfThere’ gives an error. The one in RO5 rom – when saved – does’t like being softload again. Have various modules working ok from ‘Chunks’ like ‘26b CLib’ etc. (when using RO4.02) |
nemo (145) 2546 posts |
Ugggh. Well, if the ‘star commands’ you’re talking about are Utilities that someone else wrote, then yes you could at a push do that, but it’s deeply unpleasant because as well as registering them as part of resFS you’d have to modify Run$Path so that HOWEVER if we’re talking about ‘star commands’ that you’ve written then absolutely do not do that. |
John Williams (567) 768 posts |
No, just bung them in the Library directory! That’s what it’s for, isn’t it? Well, isn’t it? Mine’s full of utilities, BASIC routines, App files, Obey files – anything the OS can run! Even stuff to be typed blind in the case of loss of video feedback, like my Restore obeyfile which just says: Make of that what you will! |