[Coco] Basic09/disabling processes/saving CPU time

Gene Heskett gene.heskett at verizon.net
Thu Oct 9 06:30:40 EDT 2008


On Thursday 09 October 2008, George Ramsower wrote:
>----- Original Message -----
>From: "Robert Gault"
>
>> George Ramsower wrote:
>>> I could use a little more CPU time in my CNC effort with a CC3.
>>>
>>> I was wondering if it's possible to issue a BO9 statement that could
>>> disable any non-critical interruptions in OS9 to give maximum CPU time to
>>> the routine inside a B09 program, such as when I'm stepping the motors in
>>> my Coco CNC machine. After the stepping is done, then I wish to issue a
>>> statement to put things back like they were.
>>>
>>>
>>> Please. This needs to be done in Basic 09. A SYSCALL is okay. I like
>>> those, but don't undstand them.
>>>
>>> Current progress in this project is that I can now engrave an aluminum
>>> plate with the name of the company I work for  and the equipment number
>>> below the name. I need to get a photo of that onto my Coco site.
>>> http://coco.thetinbox.com
>>>
>>> Engraving can be done FAST with a dremmel. Speed would help.
>>>
>>> George
>>
>> As stated by Dave Kelly, about the only thing you can do is use syscall
>> first to find the process ID of either runB or your specific Basic09
>> program and then use syscall to change the priority to 255 (highest).
>>
>> Saying this is simple but actually doing it may be confusing. That it can
>> be done is demonstrated by the OS-9 program procs. That displays process
>> IDs for running programs.
>>
>> You will need to use the two system calls Get ID and Set Priority, OS9
>> F$ID and OS9 D$SPrior. The first call from your Basic09 program with
>> syscall OS9 F$ID will get the process ID. The second call with syscall OS9
>> F$SPrior should set your priority to 255 (highest).
>>
>> Whether this will achieve anything you'll have to test. Whether the method
>> will be sufficient without changing the priority of runB or Basic09 is not
>> known by me.
>
> I was thinking more like disabling stuff like the keyboard scan

That I believe is IRQ driven, isn't done unless a key is pressed.

> or the 
>system clock

The system clock is the timer, and the machine is dead without it.  I would 
guess that it also represents an upper speed limit, but a free-standing 
routine in machine code, an expansion of the tone generators several of us 
have made over the years might be able to be modified for use, possibly even 
driving in ratios, 2 axis's to move at angles?  And probably fast enough to 
lose steps which would be a disaster.  Look at the src code for the SS.tone 
system call for ideas.

>or something to do with the system in general. 
> I'm not running any other tasks that would result in improvements in speed
>by changing the priorities.
> Been there, done that, got the T-shirt.
>
>George
>
>
>
>
>
>
>--
>Coco mailing list
>Coco at maltedmedia.com
>http://five.pairlist.net/mailman/listinfo/coco



-- 
Cheers, Gene
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
<JALH> regex are more than some crappy posix thing
<JALH> they are an art form

	- Marc Zealey on #kernelnewbies



More information about the Coco mailing list