[Coco] noob question

Randy Weaver emceesquared at gmail.com
Wed Nov 8 06:41:40 EST 2017


Thanks Joel!

Very helpful.  I'm not trying to force the CoCo to be anything other than what it is.  Just trying to understand it's nature from a .net perspective.  I only mention c#/.net to inform where my mind is coming from.  I'm ready to embrace the different concepts just trying to figure out what they are.  And reinventing the wheel seems silly with all the smart folks here.

I used to code in ECB when I was a kid.  I dabbled in EDTASM+.. just enough to be dangerous... Used it when BASIC was a bottle neck.  I'd add the assembly via DATA/POKE statements but most of the logic was in ECB.

Now, CMOC has piqued (or PEEKed) my interest... very punny!  Again, I find myself wanting to write most in C and use assembly where it makes sense. 

I'm halfway through the K&R C book and am surprised how similar the language is to C#.  Some things are handled differently but I understand those differences.

Very exciting.

Thanks again.

-Randy  

-----Original Message-----
From: Coco [mailto:coco-bounces at maltedmedia.com] On Behalf Of Joel Rees
Sent: Wednesday, November 8, 2017 12:30 AM
To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
Subject: Re: [Coco] noob question

2017/11/08 6:23 "Randy Weaver" <emceesquared at gmail.com>:
>
> I'm used to coding in c#... an event driven language.

I'd urge you to convince yourself to call C# a language containing grammatical suuport for an event-driven run-time architecture.

Separate the concepts of language and run-time architecture in your mind.

> Actions are hooked to events that "raise" a function I wrote to do 
> something.

In other words, Microsoft gives you their event parsing loop and requires you to interact with it their way.

> I'm trying to wrap my head around how you would achieve similar 
> behavior
on
> a coco.

You would probably prefer not to. Huge waste of resources supporting the C# runtime.

> I suppose a loop that kept polling for statuses that I'm interested in.

Heh. Well, that's one of the things you need, anyway.

> IRQs are interesting too but do they fire 60 times a second?

My memory is that the IRQ timing can be altered a little. (And we won't mention Europe.) And that there are other interrupt sources as well. You'll need to muck around in the hardware docs for the mainboard and the various parts. And ask questions as you see things to ask about.

But, until things become a little more clear, thinking that way can be a good start.

>  And what
> happens when my check doesn't complete in 1/60th of a second. does it 
> fire again?

Heh. If you don't know, nobody knows.

Extended Color Basic defines a rather complex but crude run-time that some here have used (partially) to varying degrees of success. It is not recommended. Do not look for event processing support in ECB.

OS-9/6809 defines a much cleaner run-time, and provides both primitives and higher-level suuport for event processing, but there will still be some assembly required if you need support for a full event model. But you are likely to find you don't need the full model, even if you need parts, and
OS-9/6809 is pretty rich in a slightly different model of multitasking. You also get a C compiler (ancient, ca. K&R version) in OS-9, which may help.

HTH

Joel Rees

--
Coco mailing list
Coco at maltedmedia.com
https://pairlist5.pair.net/mailman/listinfo/coco



More information about the Coco mailing list