How to get backspace (rubout) working on Apple I clone with SMC KR3600 keyboard encoder

16 posts / 0 new
Last post
Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
How to get backspace (rubout) working on Apple I clone with SMC KR3600 keyboard encoder

I recently built an Apple I clone.
I went through all the key milestones successfully.

1) Video circuit outputting an all "@" screen
2) Processor circuit reset and giving the'/' prompt
3) For the last milestone (running the test program to print all ASCII characters),
I bought an Apple II SMC KR3600 keyboard encoder from eBay and used an old 1984 Macintosh keyboard as my donor keyboard.
I removed the chips and proceed to cut and rewire all the traces as per an Apple II keyboard matrix.
Surprisingly, this worked out very well. All the alphabetic, numeric and special characters work as well as the shift and control keys.
I was able to enter the ASCII test program and run it on my Apple I clone.

I have not been able to get the rubout (<-) key to work.
It is wired as per the Apple II keyboard matrix (two piece keyboard).

Has anyone got their rubout key to work in a similar setup.
I have seen posts with it working for MM57040 based keyboards.

speedyG's picture
Offline
Last seen: 4 years 10 months ago
Joined: Nov 16 2011 - 07:45
Posts: 2493
Re: How to get backspace (rubout) working on Apple I clone ...

KR 3600-ST
or
KR 3600-STD ?

Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
Re: How to get backspace (rubout) working on Apple I clone ...

It is an STD.

speedyG's picture
Offline
Last seen: 4 years 10 months ago
Joined: Nov 16 2011 - 07:45
Posts: 2493
Re: How to get backspace (rubout) working on Apple I clone ...

Hello IEEE-802,
i asume that you recognized why i issued that question....
both chips vary in the way, they decode the BS( backspace )-key and the kind of byte issued to the Databus.
I also guess you performed correct cabeling to the BS-key ?

Assuming that factors there are still some questions:

What kind of Apple-1 clone ? ( That has dependence to the kind of BIOS in the 2 ROM-chips )
and
what kind of Keyboard ROM at the mainboard ? ( 2513 programmed by yourself or factory made chip - which kind of chip )
the Keyboard ROM is the chip to translate the bytecode from the KR-3600-STD to the bytecode used in the clone and the
BIOS-chips contain the code how to deal with that translated bytecode .....

In fact you have to recognize some hurddles in that process:

The KR-3600-STD was designed for later keyboards that also issued "Contol"-key codes and decide
between uppercase or lowercase characters....
in fact the most Apple-1 clones do not make that kind of difference...
They have no code for detecting that kind of keystrokes and therefor don´t decode the entire byte in their BIOS....
therefor the BS-code ( for the backspace key ) must be converted to a byte that is recognized by the BIOS
in the 2 BIOS chips of the mainboard. ( this probably requires to examine the BIOS-source code ) ....
in case you are working with the replica from Mike Willegal ( the MIMEO ) you may ask Mike for that part
of the BIOS code to detect what kind of bytecode is expected from the mainboard for BS-key
and "translate" the code issued from the KR-3600-STD to the kind of bytecode expected by the BIOS....
In fact the Apple-1 expected at the keyboard the Datanetics keyboard and the MM-chip as keyboard encoder and it´s byte-table representing the ASCII byte codes....

that´s for example also done in the PIC-chip distributed from Mike Willegal in the
PS2/Apple II keyboard to Apple 1 keyboard adapter.

At least i hope that i have explained the problem that far enough that it helps you ahead,
to locate the problem and deal with it...

sincerely speedyG

Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
Re: How to get backspace (rubout) working on Apple I clone ...

Hello SpeedG,

Thank you for your detailed reply.

In reply to your questions.
1) The clone board is a Newton
2) The ROM code appears to match with the WOZ monitor listing in the apple manual.
3) My 2513 is 1977 Signetics factory programmed unit.

When I run the ASCII test program,
I do see the _ (underscore character) appear, followed by the @ character which then disappears.
I believe the _ is $5F and the @ is $60 in ASCII.

I am planning to build a second clone and will probably go with a MIMEO board and Mike's PS2 to APPLE 1 keyboard adapter.

Thanks again

IEEE-802

speedyG's picture
Offline
Last seen: 4 years 10 months ago
Joined: Nov 16 2011 - 07:45
Posts: 2493
Re: How to get backspace (rubout) working on Apple I clone ...

Hello IEEE-802,
i have both sorts of clones ( the NewtonNTI, the Newton-1 and the MIMEO ) and the
Adapter from Mike works fine at all 3 of them....
I´ll check the codes within next 2 or 3 days when i pick up the datasheets from my archive....
sincerely speedyG

Offline
Last seen: 1 month 2 days ago
Joined: Jun 5 2008 - 07:26
Posts: 475
Re: How to get backspace (rubout) working on Apple I clone ...

Hi,

The Apple 1 monitor expects an unusual character to be used for rubout/backspace. It needs a 0x5F, which isn't supported on a standard Apple II keyboard. I found that with MM5740 encoder, you could generate it with a shift character, but you need to specially connect a key to the XY matrix. Check out this blog posting.

http://www.willegal.net/blog/?p=3351

You'll have to check out the KR3600 data sheet to see if it supports generating this character with some combination of XY input (possibly with shift or control thrown in).

If you find that it will, I might suggest repurposing the Apple II's back arrow key, which can serve no other purpose on an Apple 1.

regards,
Mike W.

speedyG's picture
Offline
Last seen: 4 years 10 months ago
Joined: Nov 16 2011 - 07:45
Posts: 2493
Re: How to get backspace (rubout) working on Apple I clone ...

Hi,

The Apple 1 monitor expects an unusual character to be used for rubout/backspace. It needs a 0x5F, which isn't supported on a standard Apple II keyboard. I found that with MM5740 encoder, you could generate it with a shift character, but you need to specially connect a key to the XY matrix. Check out this blog posting.

http://www.willegal.net/blog/?p=3351

You'll have to check out the KR3600 data sheet to see if it supports generating this character with some combination of XY input (possibly with shift or control thrown in).

If you find that it will, I might suggest repurposing the Apple II's back arrow key, which can serve no other purpose on an Apple 1.

regards,
Mike W.

Hello Mike,

Thanks a lot for unrevealing that datail !
That saves me a lot of time searching my archives.....
and of course this will serve the request of IEEE-802 ........

up till now i just knew that you have solved that issue with the adaptor
by setting up the "translation code" within the PIC-chip.

sincerely
SpeedyG

Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
Re: How to get backspace (rubout) working on Apple I clone ...

SpeedyG and Mike,

Thanks for the excellent suggestions.

I looked at the WOZ monitor more closely and noticed it does check for "<-" character(i.e $5F keystroke (actually $DF because dataline 7 is set to +5 volts)).

I will, as Mike suggested, look at the spec sheet for my encoder and see if there is a XY combination in the matrix (maybe with a shift or shift control) that generates the $5F character.

speedyG's picture
Offline
Last seen: 4 years 10 months ago
Joined: Nov 16 2011 - 07:45
Posts: 2493
Re: How to get backspace (rubout) working on Apple I clone ...

Hello IEEE-802,
if you leave pm with email i can mail you the datasheet of the KR-3600 all versions
and it contains the matrixsheets and the datacode tables of all versions.....
sincerely speedyG

Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
Re: How to get backspace (rubout) working on Apple I clone ...

Thanks SpeedyG for the kind offer.

I found a simple way to troubleshoot the keyboard. I noticed the output of the keyboard encoder is persistent.
With a simple logic probe you can read the ASCII output of the keyboard
for the last character typed in from pins 2 to 9 on the 6820 PIA.

I found out that my supposed underscore character was only a backspace ($08), not the underscore ($5F) I was hoping for.

Offline
Last seen: 3 weeks 2 days ago
Joined: Oct 9 2011 - 12:54
Posts: 1352
Re: How to get backspace (rubout) working on Apple I clone ...

The best way for you to obtain an underscore is to use remap the backspace character to rubout. Use some logic gates.

FYI: I think Woz made a mistake here. He mistook the rubout character which shows up as an underscore on most terminals for an actual underscore. They are different. You can notice this on an Apple-1 if you have a Datanetics keyboard. If you press the rubout key you get a "_" but it's not a real underscore that the monitor is looking for. It's the del or rubout character (7F if my memory is correct)

Cheers,
Corey

Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
Re: How to get backspace (rubout) working on Apple I clone ...

I finally got the rubout to work. Smile
Unfortunately, I was not able to do it via the keyboard matrix.

I used a 4066 quad analog switch and 3 x resistors.
I created some simple logic that closes the "O" key (i.e. $4F or 01001111) which is very close to the rubout "_" ($5F or 01011111), while holding keyboard dataline A5 = 1. $4F + $10 ==> $5F

I was able to do it with one key, no shift nor control key in parallel is necessary.

The behavior is not what I am used to. (i.e. where you press the delete or backspace key and it visually erases the previous character.)
Previous character is not removed from the screen, but is only removed from the keyboard character buffer.

For example, 4 x "A"s followed by 2 x "_"s

AAAA__ (Return)

The monitor displays the memory contents for corrected location 00AA not AAAA.

Offline
Last seen: 1 month 2 days ago
Joined: Jun 5 2008 - 07:26
Posts: 475
Re: How to get backspace (rubout) working on Apple I clone ...

There is no way to move the cursor backwards with the Apple 1 video circuit which is why the rubout doesn't move the cursor backwards. The only cursor control available is the carriage return function which clears to end of line and advances the cursor to the beginning of the next line.

regards,
Mike W.

Offline
Last seen: 3 years 2 months ago
Joined: Oct 3 2014 - 22:06
Posts: 70
Re: How to get backspace (rubout) working on Apple I clone ...

Thanks Mike, SpeedyG and Corey896 for all your help.

Finally getting the rubout key to work on the Apple 1 has really made me appreciate the delete key on modern day computers Smile

speedyG's picture
Offline
Last seen: 4 years 10 months ago
Joined: Nov 16 2011 - 07:45
Posts: 2493
Re: How to get backspace (rubout) working on Apple I clone ...

Hello IEEE-802,

it´s common nowadays to forget one fact:
that old "monsters" had a BIOS that fitted in 2 small 256 Bit chips....
even the Apple II allready had a BIOS 8 times that large !
More code permits more "luxury" ( or to say better: more features ).....
starting with the handling at the keyboard and ending with the treatment of the monitor output....
and the BIOS of the Apple - 1 was really very "Basic".....
speedyG

Log in or register to post comments