[Coco] Program won't stay loaded under NitrOS9/OS9

K. Pruitt pruittk at roadrunner.com
Sat Jan 2 11:35:45 EST 2016


Hi Bill,

Executing it from the command line works fine. It's just when it is loaded 
it won't say in memory after execution. There are no external calls from 
this program. I've created a little sandbox so to speak by shutting off 
interrupts. I have tried not turning off interrupts but then the speech gets 
terminated prematurely when I do so. Ultimately to be at all useful it will 
have to work with interrupts enabled - but that's something for down the 
road a bit.

I'm just screwing around with the speech and sound cartridge here and trying 
to learn some more about hardware programming. I've pretty much crashed my 
CoCo every which way imaginable in the process. I am learning in the process 
though.

Here is what I am doing...

The code loads the parameter in to a buffer, turns off the interrupts and 
drops the Coco down to 0.89Mhz.. Passes the parameter to the Speech./Sound 
cartridge a byte at a time, wastes some time while the cartridge is speaking 
and then returns the CoCo to 1.79Mhz, turns the interrupts back on and exits 
the program.

Thanks for the info on the link and load stuff. I will explore that area.

Thank you Bill.

----- Original Message ----- 
From: "Bill Pierce via Coco" <coco at maltedmedia.com>
To: <coco at maltedmedia.com>
Cc: "Bill Pierce" <ooogalapasooo at aol.com>
Sent: Saturday, January 02, 2016 8:10 AM
Subject: Re: [Coco] Program won't stay loaded under NitrOS9/OS9


> Did you "load" the file before executing it? or just 'run' the file?
> Even calling another module from within a program, it must be loaded first 
> to keep it residing in memory and unloaded when finished or it stays in 
> memory even after you exit your program.
> There is also another 'undocumented" method of loading that allows you to 
> load a module without it's data space being assigned and it will only use 
> up the amount of memory equal to the size of the module (as opposed to the 
> 8k OS9 assigns on 'load'). It uses the "NMLoad" call which is used the 
> same as load. This actually a low level call and has been there for a long 
> time, but was never documented in any of the docs. A sister call of 
> "NMLoad" is "NMLink" which does the same, but links the file, again, using 
> less memory.
> I also have "external" versions of these commands "NMLoad" & "NMLink" 
> which are used like "Load" & "Link" from the command line.
>
>
>
>
>
>
> Bill Pierce
> "Charlie stole the handle, and the train it won't stop going, no way to 
> slow down!" - Ian Anderson - Jethro Tull
>
>
>
> My Music from the Tandy/Radio Shack Color Computer 2 & 3
> https://sites.google.com/site/dabarnstudio/
> Co-Contributor, Co-Editor for CocoPedia
> http://www.cocopedia.com/wiki/index.php/Main_Page
> Global Moderator for TRS-80/Tandy Color Computer Forums
> http://www.tandycoco.com/forum/
>
> E-Mail: ooogalapasooo at aol.com
>
>
>
>
>
>
> -----Original Message-----
> From: K. Pruitt <pruittk at roadrunner.com>
> To: Coco <Coco at maltedmedia.com>
> Sent: Sat, Jan 2, 2016 10:59 am
> Subject: [Coco] Program won't stay loaded under NitrOS9/OS9
>
> What conditions would cause a module to not stay loaded but remove itself 
> from memory after it is executed one time? I'm not generating an error of 
> any sort and the system does not destabilize.In my code I am halting the 
> interrupts and turning them back on when I am done. Would that cause such 
> a scenario to occur? -- Coco mailing 
> listCoco at maltedmedia.comhttps://pairlist5.pair.net/mailman/listinfo/coco
>
> -- 
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco
> 



More information about the Coco mailing list