Microsoft open sources GWBASIC

Jim Brain brain at jbrain.com
Tue May 26 11:50:31 CDT 2020


On 5/26/2020 9:50 AM, Liam Proven via cctalk wrote:
> On Mon, 25 May 2020 at 20:53, Jim Brain via cctalk
> <cctalk at classiccmp.org> wrote:
>
>>    Too late to fix silicon, the 6522 issue surfaced.
> What 6522 issue?

TO help save a few bits in everyone's mailbox, I will link to some docs:

http://forum.6502.org/viewtopic.php?f=4&t=1514

The forum post gives some commentary on the bugs.

http://archive.6502.org/datasheets/synertek_sy6522.pdf

However, the TLDR version is that there are bugs in the shift register 
implementation that cause too many clock pulses to be sent (mode 010) 
and missing IRQ after 8 clock pulses (mode 011/111).  Page 8 of the PDF 
gives more detail (Section 5.1).

>
> This is way more depth about a machine I never owned than I personally
> ever knew, I have to admit...
I am sure all the home computers have these interesting stories, though 
most of the world only knows about variations on the 5150 design and the 
Mac.
>
> Still, that degree of backwards-compatibility helps adoption of a new
> model. ZX Spectrum owners could keep their ZX Printer from their ZX81,
> for instance, and BASIC programs would still run. (Although I think
> you had to re-enter them all -- not sure about tape storage
> compatibility.)
I agree and can't fault the logic.  We who bought a VIC-20 and then 
upgraded and were penniless kids were ecstatic.
>
>>    Done, except Japan
>> didn't see any need for it, so they deleted it.  Argh!
> But I thought the Japanese model didn't sell?

I may have miscommunicated.  CBM did their design work in PA, but final 
layout and such was done at the Japan office.  And, they also tended to 
use the Japanese market as a test for US and Europe intros, to iron out 
issues.  Thus, the VIC-20 final layout was done at the Japan office, and 
it was introduced there first (as the VIC-1001).

When designing the C64, the PA design team snuck in a new trace from the 
6526 shift register (and bridged one of the IEC lines in place at the 
6526 CIA over to the shift register CLK line (most likely the unused SRQ 
line on the IEC connector) and then sent the designs to Japan for final 
layout.

My theory is that the PA design team didn't dare talk about the extra 
traces with leadership, for fear of retribution.  I am sure managers 
would have been concerned about possible compatibility issues of adding 
a trace and demanded it be removed.  Jack may have yelled (he was 
legendary for that) at the engineer for "adding no value".  Or, the 
management team might have been actually concerned about the issue, 
raised it to Jack, and demanded they fix it but not add the trace.  I 
think the engineer thought this was a way to add this in for the future, 
but not delay the current project and hit show and intro dates.  But, 
that's my theory.

The Japanese team, not having any knowledge about this "secret" plan to 
fix slow IEC speeds, simply optimized the extra traces our of the 
design, and since it was final layout, there was no recourse.

To your point, the C116 intro in Japan did indeed bomb.

> I must admit, even in 1983 or something, that seemed extravagant to
> me. I know that the Apple LaserWriter was a more powerful computer
> than the Mac that drove it, but there were sound engineering reasons
> for that -- but most 8-bit machines' standard floppy drives didn't
> have CPUs, so why did the Commodore ones need them?

Well, I do think Peddle had a great idea.  Most drives of the day were 
tightly coupled to the machine, which was low cost, but tightly coupled 
the hardware.  He was familiar with the HP Interface Bus (HPIB), which 
is IEEE-488, and the value it created (lots of peripherals, lots of 
interconnectedness, etc.).  I think he championed the PET have that as 
opposed to a direct drive connection.  Though IEEE-488 gave way to IEC, 
it and related peripheral connects (the Atari SIO bus) actually were a 
great design choice, as it makes it that much easier today to interface 
contemporary peripheral options to these old machines.  While some 
systems have to emulate an actual floppy format (80kB or 160kB or 
something) when trying to move from spinning disk to SD cards and such, 
one can hang a huge FAT32 formatted SD card off the CBM serial bus and 
the computer doesn't hardly even know.  Most apps just merrily go along.

But, 2 CPUs? That was overkill, in most folks opinions.

> Well, for all that it didn't appeal to me, I think it was a decent
> design and it sold well.
Can't argue that.  Some of us were so desperate for color computing, and 
it quickly fell to a reasonable price.
>
>> I guess your point is that you don't agree with Jack's priorities. The
>> VIC was a rush job, costs had to be low.  BASIC v2 just fit in an 8kB
>> ROM, and KERNAL fit in another 8kB.  8kB ROM was easy to make in house.
>> Notice they used 2 ROMs instead of 1 16kB one.  It was all about low NRE
>> costs, using stuff off the shelf.  Putting a third 8kB ROM in there for
>> better BASIC was just an unneeded IC, plus someone would need to write
>> the A/V code (CBM did not have a A/V capable BASIC at that time).
> But CBM didn't write it in the first place, did they? It's MS BASIC.
MS wrote it, and CBM modified it as needed. BASIC 4.0 I think was wholly 
modified from v2 by CBM.  Something changed at some point, because none 
of the CBM BASIC up to v7 in the C128 had a MS copyright, but v7 (all 
changes done by CBM internally) did have the copyright.  Not sure if MS 
threatened, it was some concession given in licensing a BASIC for Amiga 
(I forget it AMigaBASIC was MS-based...), etc.
>
> In the Spectrum, there's no split between OS and BASIC -- they're the
> same chunk of code, and it all fits in 16 KB leaving 48 KB of memory
> map free for RAM. The initial models of Spectrum (16KB & 48KB) had no
> bank switching support at all, AFAIK.
Now, this is a good question.  I've seen MS BASIC v2 and VIC and 64 
KERNAL (same except for some fixups to fit the 64) and they take up all 
of that 16kB.  Maybe Z80 code is more compact, or maybe Sinclair was 
just better at stuffing code into ROMs.  Not sure.  But, it is obvious 
the Speccy packed more into 16kB than Commodore.
> Anyway, back to 6502 machines: the BBC Micro split the OS (MOS) and
> BASIC (BBC BASIC) into different ROMs, just as the Commie 64 did.
> However, Acorn's ROMs were 16 KB each not 8 KB each. That meant that
> with both MOS and BBC BASIC paged in, the base model BBC Micro had
> only 32 KB of memory map left for RAM, and that really wasn't enough.
> Its highest-res graphics mode took ±20 KB of RAM, leaving a paltry
> 11KB for programs.
>
> But I guess all this is unknown and irrelevant in the USA, where Acorn
> barely sold at all and Sinclair did poorly.
I think the Sinclair options just were not marketed well in US.  I 
remember considering the ZX81, but really wanted color.  I don't 
remember seeing the 2068 back in the day.  I also don't remember seeing 
the Micro, and what was the cost of it in 1984, for example? In '82, the 
VIC was 332USD, and in 1984, the 64 was $149.  I doubt the other models 
could hit those prices.  Schools here got the Apple IIs (Apple had some 
education program), but lots of us went the cheap route.
>
> Given that the functionality of the Commodore OS and BASIC seemed so
> feeble compared to that of the Beeb, I remain surprised to this day
> that CBM couldn't squeeze all that into 16KB.
I heartily agree with you there.
> Also fair. It's all most British schoolkids wanted, yes.
>
> I collected games like some kids collected stamps: it was fun to have
> a good collection, swap and trade, to have the latest or rarities --
> but you don't actually _use_ the stamps in your collection, do you? I
> didn't actually _play_ all the games. Most I loaded once, had a look
> and then never opened again.
We are exactly alike in that.  I have boxes of games I collected from 
back in the day and I don't think I even loaded some of them up one 
time.  So much youthful effort squandered on such a useless task :-)
>
>
>> I can appreciate your advocacy of BASIC.  I cannot agree with it, and I
>> liked BASIC (on many machines) growing up.  Once I entered software
>> development as a vocation, I found BASIC had set up bad habits that it
>> took years to unwind.  I still have a fondness for the language, but I
>> don't think it was all that educational.  It was brute force, overly
>> verbose at times, hard to follow in programs of anything above trivial
>> sizes, etc.  But, it must have it's sheering section, and so I defer to you.
> I do not know what a "sheering section" means.
Typo: "cheering".  :-)
>
>
>
> BASIC made learning programming easy. The result was a whole
> generation of kids in the 1980s learned to program and started tech
> companies, and many became wealthy or changed whole national
> economies.
I will absolutely agree with this.  BASIC was the gateway drug. Perhaps 
I quibble because easy and good may not be equivalent. Maybe there is a 
mutual exclusivity at play.  BASIC was easy to learn (kudos to the 
designers) and powerful, no argument there. But, I think it scaled badly 
and created bad habits (global vars, spaghetti code, etc.) and it put me 
a bit behind when I needed to turn my enjoyment of programming into a 
vocation.  But, if you just wanted to whip up a solution to your 
specific problem, and you were not trying to be a professional 
programmer, BASIC was awesome (I still use it when I test hardware 
designs, since it's so much easier than sitting down to write a machine 
language test app.).  But, when the adult drops by the introduction to 
programming class, you just don't know what category that person is in.  
Still, I will agree that it made programming fun, and none of the bad 
habits it fostered were all that difficult to unlearn.
>
> Yet you or your family paid in real terms between 4× to 8× as much and
> you didn't mind that it had some very serious drawbacks which you
> discuss in great detail?
>
> That's astonishing to me.
Well, to be fair to my 10 year old self, living in a rural community, I 
probably didn't do very good research.  I *wanted* an Atari 2600 (yes, 
it's ironic, since I don't play games and really never did), but 
everyone had one, and peer pressure is strong.  My father, who was a 
farmer and mechanic, put his foot down and vetoed the idea, stating that 
for that kind of money, the device should do more than play games (I 
think the 2600 was $199 or something, maybe was a bit more, memory is 
fuzzy).  But we lived in the country, so we did our shopping via the 
Sears/JC Penny/Montgomery Ward paper catalogs, and all of the units 
offered were just as unapproachable as your comments state about the 
options in your youth, save the VIC-20.  Thus, in comparison, it was 
awesome, even though it had issues.  I don't remember seeing the 
Sinclair or the BBC in those catalogs, and that was probably the extent 
of my research.
>
> If I or my parents were spending this very significant sum, perhaps a
> month's income for the whole family, then I want something as rounded,
> as balanced, as capable in every aspect as can possibly be done for
> the price.
My family didn't really care at the time.  Maybe in Europe folks took 
computers more seriously earlier, but my family saw it as just another 
toy the boy wanted.  And, it was all my savings I had accumulated.  Of 
course, I now know we were (and are) privileged concerning income in the 
US (and I think my family would be considered lower middle class at the 
time), but I didn't know that then.  Unlike with food, there was no 
"Jim, there are less fortunate children in other countries who cannot 
afford this kind of computer, so you better pay a lot of attention to 
selecting a valuable option" discussions.  I had the cash, I bought the 
machine, I enjoyed it.
>
> Yet you say "yeah, well, the BASIC was crappy and the disk drives were
> kinda crappy but I didn't care."
>
> This is really quite profoundly shocking to me.
Well, I didn't know they were at first.  Initially, I played games on 
the VIC, and then tired of it and put it away.  A year later, the school 
had some, so I dug it out and really started coding on it. We were not 
in a large metropolis, and computers were so new around here, no one was 
comparing.  Later, when things become more well known, we were all 
trading games, BASIC was never mentioned, and C64 games used the disk 
drive CPU to enable fast disk access, so the slow drive issue just 
magically disappeared. I read magazine articles about better BASIC 
options and A/V commands in other units, and I think I did lament that, 
but I'd made my investment, and the eco-system around here was Atari and 
Commodore.
>> If you mean putting the Z80 in there? Bil agrees with you.  He hated the
>> entire idea, and the engineering effort he expended to do it.  But, when
>> Marketing has promised it, evidently at Commodore, you made it happen.
>> Hats off the engineers at CSG/MOS/CBM.
> Again, I guess we are looking at this in very different ways.
>
> For you, these seem to be small, unimportant issues. For me, at the
> time, given the amount of money involved, they would be deal-breakers.
I'd ask for more clarity here.  I do think compatibility with 2 obscure 
carts was overblown, and maybe you think that was super important. But 
maybe you mean the choice of putting the Z80 in there.  I can't believe 
CBM let him do it, since that piece was so expensive, compared to MOS 
parts.  But, it happened.  Still, I' m not sure your context here.


Jim



More information about the cctalk mailing list