UNCLE BERNIE'S IMPROVED APPLE-1 CASSETTE INTERFACE

24 posts / 0 new
Last post
Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
UNCLE BERNIE'S IMPROVED APPLE-1 CASSETTE INTERFACE

You probably expected already that something like this must be coming, after you followed me on the bumpy road that lead to this - at the present time -  "final" result of my work on improving the notorious Apple-1 cassette interface, as documented in this thread spanning many months:

 

https://www.applefritter.com/content/which-aci-improvements-do-exist-and-work

 

This new thread is meant for those of you who are not interested in how all this came about, and was developed, but only in the final result, the recipe on how to modify your ACI to get improved functionality and to activate the hidden page in my new ACI PROMs (which have been sold with my more recent IC Kits since early July 2020).

 

The mod addresses three shortcomings of the the original ACI circuit design and its firmware:

 

1) it fixes the volume indicator LED circuit (which in the original form almost never works).

 

2) it adds Apple-II style checksums to the recordings so you can read / write tapes with either Apple-1 or Apple-II and use the same recordings on both machines.

 

3) it adds an "extended" formatting capability to the recordings to make them less awkward to read back.

 

The latter is based on a proprietary format which I had developed a few months ago in my "improved ACI project".This proprietary format is fully forward and backwards compatible with both Apple-1 and Apple-II even if those are unmodified. But if you use my new ACI PROMs on an ACI card modified for them, you don't need to remember or type in any load address ranges or start addresses. All this information is embedded in the "extended format" recordings. So, for instance, if you have made an extended format recording of a machine language game that consists of one data block and one autostart block, to load it, you just give the commands:

 

C500R <return>

RX RX <return>

 

... and the game loads and starts. There is one RX for each block. The number of blocks is all you need to know. The C500R starts the second page in the PROMs which I have added. The first page still contains the original ACI firmware written by Woz back in 1976 (used with his permission). So with the mod you lose nothing. The original, unmodified firmware can be started with the command C100R as usual. This is a bit different from the 512 Bytes PROMs I had developed a few months ago. They were a complete re-write and also had a CRC (cyclic redundancy check) capability. They also know about the number of blocks in a record - only one RX command needed. But they would not work at all in an unmodified ACI card. Which would mean I could not sell those with my famous 100% tested and burned in IC kits on Ebay. Buyers expect to have the real deal, the real firmware as written by Woz. And I agree with that attitude. So when I ran out of 256x4 PROMs and sought a good use for the 2nd page of 512x4 PROMs, I decided to make a stripped down version of my "extended ACI" firmware PROMs to avoid wasting this 2nd page. A few functions had to be thrown out, but finally I could make it fit. This is not a "crippled" version, though. The "extended" format it makes is the real thing but the CRC fields are marked to be invalid and the block count is not used on readback. Everything else is still there, and everything stays forwards and backwards compatible.

 

In the following I will show you how to modify any ACI card to fix the volume indicator LED circuit and to enable the hidden page in my new ACI PROMs. You can implement both or only one of these two mods. My recent kits also include all the small passive components to fully populate an ACI card (except the IC sockets) so I ordered two ACI cards from "Pinguoso" on Ebay ($10 each, great price !) and used one of my parts bags to build a new ACI with the mods from scratch. This of course also was a test to see if everything would work for builders - my older ACI cards are "lab rats" with so many modifications that they don't qualify for that and could not be used to make nice photos of them.

 

Step 1: One cut on the component side (this is for the volume indicator LED circuit fix):

 

 

The best way to cut these traces is to use one of these diamond tipped, battery driven etching pencils you can find at Harbor Fright (pun intended) and elsewhere. You can also use a X-acto knive to cut out a piece of the PCB trace, but I found the etching pencil works much, much more precisely and never cuts too deep - because it does not cut - it's a grinding process.

 

 

Step 2: Three cuts on the solder side (this is to enable the hidden PROM page):

 

 

Note the read arrow. On some ACI PCBs not based on the Russian Open Source Gerbers there is a trace at that location that duplicates the component side trace we just have cut in Step 1. If such a trace is there, it also needs to be cut.

 

 

Step 3: Populate the PCB as usual. Be aware of the option to hide the added 1nF capacitor for the volume indicator LED circuit fix in the IC socket, if it is the kind with precision machined contacts. This requires good fine motor skills and a very precise soldering technique. If you can't do that, you can always put the capacitor on the solder side of the PCB. It just is an eyesore there, see the photo in the above thread, post #13. But yet another alternative is to use a small 1nF SMD capacitor (the "bird feed" type), if you have those, in lieu of the disk capacitor. I chose to hide the latter in the IC socket: I snipped off the pin#9 of the DIL-14 socket just at the point where it gets skinny (this avoids damaging the internal contact fingers, do not snip any further). Then I soldered one leg of the capacitor to the stump of that pin and then I ground it down, again with this marvelous diamond tipped etching pen (but be careful -- only remove the solder bead, and once copper is visible, stop immediately). This procedure increases the clearance of the stump to the PCB, such that a thin insulated wire can go through the pin #9 pad hole of the PCB location #2 into which the pin would go had we not snipped it off. That thin wire is soldered to the other leg of the capacitor. Just prior to that step the IC socket with the hidden capacitor looks like this:

 

 

 

When the socket is being installed, the thin wire is threaded through the hole and then pulled gently from the other side while placing the socket into the PCB. Only solder two diagonal pins (#1 and #8 recommended) of the socket and then adjust its height over the PCB by alternately re-heating these two solder joints while pulling / pushing on the socket. Make sure there still is some small clearance from the stump to the wire going though the hole of the pad, and make sure the IC socket is not tilted in any ugly way. Do not solder any of the other pins of that socket yet. Then put in all the other parts. The component side of the ACI should look like this:

 

 

 

You might note that I used DIL-16 sockets with built-in 100nF bypass capacitors in locations #3 and #4, where the PROMs go. Bipolar PROMs make nasty current spikes and this may be one reason why the ACI is not such a great performer in terms of readback reliability. So I can recommend this measure (although it's hard to prove how much it really brings).

 

 

Step 4: Add the wires on the solder side like this:

 

 

 

Some of the wires tap into a PCB trace. Scrape a little bit of the solder mask away and then polish the exposed copper with a pencil eraser until smooth and shiny. This helps to make a better solder joint. But don't overdo this, use a corner of the pencil eraser to avoid a dull speck on the solder mask that is too large. If your pencil eraser has no sharp corners anymore, cut a piece off and you have four fresh corners to work with. That should be plenty. Solder the insulated wired that comes out of the pin #9 hole of the IC #2 (the socket with the hidden capacitor) first, because if you botch that and cut it off too short, or if there is a mishap with stripping the insulation, you can still get the IC socket out to install a new insulated wire (rinse and repeat).Remember we only soldered two diagonal pins of the IC in location #2 for a reason. Any mishap with stripping insulation can be avoided by using polyurethane insulated wire used for winding inductors. This thin insulation can be stripped by heating it with the tip of the soldering iron (apply some solder in the process). But do not inhale the fumes - they are toxic. I used this type of wire for the photos seen in post #13 of the beforementioned thread. But for the example here in this new thread, I used blueish wire-wrap wire because I think it looks nicer and I wanted to show you the difference. Alas, I have no such wire with an insulation of a color that matches the green solder mask. That would be ideal for better looks.

Make sure the insulated wire that comes out of the pin #9 hole of the IC #2 is long enough to be bent into the final configuration seen here:

 

 

Which looks neater. In the previous photo I just had bent it away again so you can discern all these wires and where they connect to more easily.So many words for just one wire. But is is the most difficult wire to add and it must be done right and completed as the first one. Then add all the other wires and solder only those pins of IC #2 where a wire must be attached. Do not solder any of the other pins of IC #2 until all wires are in, and have been bent into their final positions. You could still break that difficult to replace wire off in the process and if this happens you want to be able to get the IC socket #2 out again to replace it. After all the wiring work is done, solder the remaining pins of IC socket #2.

 

This is how I built a new ACI card with all the currently known mods. It will work with both 256x4 and 512x4 type PROMs, so you can do these mods even if you don't have the new 512x4 PROMs yet. It would be great to have somebody who has the tool to edit Gerbers so these mods could be put right into the PCB itself. If the extra capacitor would be a SMD hidden under the socket of IC #2, then nobody could tell it apart from any unmodified ACI, except for spotting the 5.1 MEGOhm resistor in lieu of the 100K resistor. Alas, the only tool I know which can edit Gerbers with grace is the "FAB2000 Gerber Edit"(or so, my memory is not 100% certain after all these years). Our PCB wizard in the last company I worked for before retirement had it. But it is heinously expensive. Most likely it can't be found outside the electronics industry. But maybe our Russian friend who made these Open Source Gerbers could make that modified PCB for us ? If you read this, dear Misha, please get in contact with me by a private message here at Applefritter.

 

So far today's post on UNCLE BERNIE'S IMPROVED APPLE-1 CASSETTE INTERFACE.

 

We have covered the hardware side.

 

And that is all I could do in this internet session. If anyone is interested in adopting these mods, please write a comment. If there is enough interest, I will make another post explaining the software side and how my proprietary extended format works on both the Apple-1, the Apple-II and how it can be used on any non-modified ACI (same procedure as with using it to read these recordings on an Apple-II, btw.)

 

Comments invited !

macnoyd's picture
Offline
Last seen: 2 hours 52 min ago
Joined: Oct 15 2012 - 08:59
Posts: 753
Really NICE work UncleBernie !!

Easy to understand write-up too.

I have no comment on the technical parts but I would like to suggest that you consider making up an "UncleBernie's" version of the cassette interface PCB with all the mods included in the traces.

I know I'd buy one! :-D 

If PCB making isn't in your bag, maybe someone here would take it on. (?)

 

Very nice work and thanks for posting !!

You've become an excellent source for mods and technical info to the Apple 1 - which is most appreciated by me and I'm sure many others as well.

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

There is a free program for creating and editing PCBs.

 

https://easyeda.com/

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
HOW TO USE UNCLE BERNIE'S EXTENDED FORMATTING PROMs

Hi -

 

I have got word that there is one (ONE !) daring soul out there who has these PROMs and did the mod. So I decided to publish the "manual":

 

Start the 2nd page in the PROMs with C500R <return> and then you have the same cassette commands available as in the original Woz ACI code, except that these have extra functionality. However, since I use the command line parser written by Woz, be aware of the quirk of the original ACI firmware that you better enter ALL four hex digits of any address given to these commands. Otherwise, some leftovers of the previous address may become part of the second address and the address range used by the command will be wrong. I think this is not a "bug" in Woz' code - there is simply no way to avoid this within the mere 256 bytes available. And since I also was very, very tight with the added 2nd page - I struggled for weeks to squeeze the extra functionality in - I could not fix this quirk either. So let's call it a "feature" which can be dodged by proper procedure: always enter four hex digits for each address and all is good !

 

If you use the "standard" cassette commands in the form:

<from>,<to><cmd> where:

 

<from> is the address of the first byte in the recording block

<to>   is the address of the last byte in the recording block

<cmd>  is the command: 'R' for tape read, 'W' for tape write

 

 

... in the extended formatting / 2nd ACI page, the firmware will append (and check) an Apple-II style EOR checksum byte, which is so badly missed in the original ACI firmware. If the check fails, a '?' will be output. These recordings are fully Apple-II and Apple-1 compatible: the original Apple-1 firmware (on page $C100) just ignores the checksum.

 

There also are 'extended' formatting commands, WX and RX, the 'X' meaning 'extended'. These use an 8-byte header which contains the <from> and <to> addresses, or, if those two addresses are equal, they are treated as an autostart address. As an example, consider the commands to write a recording of my 'Codebreaker' game you can find here in this forum:

 

C500R <return> ... to start the extended formatting page. Then:

0800.0FFFWX 0800.0800WX <return>

 

... to write a first record block containing the program and then a second record block with the start address.

 

Having these headers in the recording relieves you from writing down or memorizing the load and start addresses. All you need to note / memorize is the number of blocks. To load and run such a program, use the following commands:

 

C500R <return> ... to start the extended formatting page.

RX RX <return> ... load and execute two record blocks.

 

If you want to avoid the autostart, just use one RX less than the number of blocks in a recording (the autostart always must come last for obvious reasons).

 

To read such an extended format recording on an unmodified Apple-1 ACI or on an Apple-II, you just subtract eight bytes from each <from> address and you skip the autostart block as explained above. So in case of the 'Codebreaker' example the read command would be:

 

07F8.0FFFR

 

and all is good. Be aware, however, that the header still is being read into address range $7F8 to $7FF. It does not matter if any memory is there, as both the Apple-1 and the Apple-II just deposit these eight bytes blindly and never look at them again, but you want to avoid overwriting vital data of the operating system, so choose your address ranges accordingly.

If for some reason you must make multi block recordings with continuous addresses (no gap for the eight header bytes there), record them with descending address ranges. Example:

 

0B00.0FFFWX 0800.0AFFWX 0800.0800WX <return>

 

and on unmodified Apple-1 ACI or the Apple-II use the following read commands:

 

0AF8.0FFFR 07F8.0AFFR <return>

 

So with a little bit of evil math in the hexadecimal number system we can load such extended format recordings on any machine, whether it has my 'extended formatting PROMs' or not, and whether it is an Apple-1 or an Apple-II.

 

What these 'extended formatting PROMs' in the current form don't have anymore: my original work was a complete re-write of the ACI code and it supported cyclic redundancy checks ("CRC"), too. But I never could fit everything I wanted into only 512 bytes of PROM space. With more time to spend on it, maybe it would be possible. But when keeping Woz' code in there, in the first page of 256 bytes, there is absolutely no way to have CRCs. So in the current headers there is a flag to disable the CRC check for these recordings. But (inactive) CRC bytes are there to keep everything forwards and backwards compatible for the future.

 

You could now make the point that CRCs are not absolutely necessary anyways, and the EOR checksum would do, as it was all what the Disk-II system ever had. However, there are certain error conditions in tape systems - which I actually have experienced during my work on the new ACI firmware - where the EOR checksum would NOT catch a readback error. This may happen, for instance, with a premature start of the readback before the actual start bit after the header tone comes along. The header tone itself is read as a string of $FF bytes and as long as the premature start catches an even number of them, the EOR checksum won't notice that fault, despite the read back data is misaligned and wrong. Alas, numerous causations exist which may produce such a premature start. The crappy media player of Windows 7 is one of them. And the cassette readback circuit of the Apple-II tends to treat playbacks with too high a volume setting as a sort of bogus header tone with lots of '1' bits and a few '0' bits sprinked among them, which may cause exactly the dreaded error condition mentioned above.

A CRC would catch that, but even a CRC has weaknesses and I have witnessed a rare case where even the CRC did not catch a fault and the loaded program would hang.

 

But in any case, even a simple EOR checksum is much, much better than having no checksum at all, as is the case with the original Apple-1 ACI.

 

Comments invited !

 

 

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

Finally, I made this mod, though a little bit on my own laying the wires that would not be crossed, as I lay pipes, I'm a plumber. This really works, at least the LED is lit when you boot from a laptop and it is very convenient to determine the level of volume needed. I have the usual unmodified PROMs, so I can't test the other functions yet. This is the third big upgrade for this board with the change of ic sockets, so don't mind the scratches. 

 

Thanks Uncle Bernie, as always your insights were very helpful.

 

 

 

mrtitanic777's picture
Online
Last seen: 39 min 6 sec ago
Joined: Jul 23 2020 - 04:40
Posts: 66
Very Interesting thread! I

Very Interesting thread! I would be VERY interested in editing the PCB to include this mod. But it would require a lot of rerouting traces, mainly because there's bodge wires crossing over multiple PCB traces and that again means everything would have to be moved around.

 

Best,

Logan

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
I'm already working on a modified ACI PCB ...

... based on the Open Source Gerbers. It will include the volume LED mod, the extended PROM mod, and the +5V only mod. It will work with all Apple-1 and all known ACI PROMs. But of course, if you plug the standard 256x4 PROMs in, you will NOT get the extend format functions ;-)

 

I already have a plan and there are not many traces which need to be moved. The mods will be so small that you can't spot the difference to the original ACI layout unless you know exactly where to look. The casual observer will not see the difference. This is important for me.

 

The issue I still have is that I need to learn a new PCB software package to do the work and I don't know if I can follow through with it. I always avoided to use PCB CAD tools because they tried to rewire my brain from Cadence Virtuoso (needed for IC mask layouts) to the PCB way of thinking. All the hot keys also being different. No good ! So I always made sure I had technicians to do the actual work with the PCB CAD tools. This helped me a lot to avoid a Gordian knot in my brain but now for my post retirement hobby I do see the lack of PCB CAD skills. It has been maybe 20 years ago when I used a PCB CAD tool myself.

 

Maybe you would do the work for me if I get too frustrated. Which PCB tool to you have ?

mrtitanic777's picture
Online
Last seen: 39 min 6 sec ago
Joined: Jul 23 2020 - 04:40
Posts: 66
PCB Software

Bernie,

So for me I use CAM350 Pro, it's a very old software version, like 1994 - 2002. But it works beautifully, I can even import newly made gerbers straight into it and edit them. I have already MASSLY edited those open source gerber files to make it look JUST like the original, and all I can say is that it looks WONDERFUL! I have already publicly released the first revision of the modifications to the Apple-1 Enthusiasts group in Facebook, and I will post them here today.

 

Best,

Logan

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
Uncle Bernie's improved ACI --- modified PCBs ready !

As I have mentioned above in post #7, I have been working on putting all the known ACI improvements into the Open Source Gerbers, so no trace cutting and no ugly wires are necessary anymore. Here is the result:

 

 

Can you spot the layout differences to the originals ? If so, are these differences offensive ? (Disregard the  white lot id  which JLCPCB has mindlessly slapped just over the TO TAPE text for this - Sigh ! It was the first prototype run of these PCBs, and this mistake will not be repeated ! I've edited this nasty lot number away as much as I could, but I did not want to erase the TO TAPE text.)

 

Here is  a picture of an original ACI which I found on Mike Willegal's website for comparision purposes:

 

 

Of course we have to ignore the different PCB materials and the different color of the solder mask and the different components.  I did my best to mimic the real thing as much as I could by using carbon composition resistors , but there is a limit of my patience when it comes to browsing through the shelves of electronic surplus stores.

 

Comments invited !

 

 

macnoyd's picture
Offline
Last seen: 2 hours 52 min ago
Joined: Oct 15 2012 - 08:59
Posts: 753
Looks really good UncleBernie

The only differences that are obvious to me are a few traces between a couple of IC's, but you can't make mods/fixes without that!

Nice reproduction IMHO and folks should be very happy with this.  Nice work!

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

Very good work! If it wasn't for the 5.1mohms resistor I wouldn't have noticed the difference. And just a question: what is the name of the LED on the original ACI card, 3mm? The normal one like yours has a diameter of 5mm. Also, in case you didn't know, you can use 7402, 7410 and 7474 without LS, I checked.

 

Thanks in advance!

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
3mm LED in the original ACI picture - it is the original LED ?

In post #11, Macintosh_nik wrote:

 

"And just a question: what is the name of the LED on the original ACI card, 3mm ?"

 

Uncle Bernie answers:

 

Yes, the one in the picture of the original ACI card is a 3mm LED. 

 

I prefer the 5mm ones for three reasons:

 

a) their "red dot" you can see is much larger, area wise, than a 3mm LED. If mounted with bent leads like shown pointing upwards,  then you can look downwards and you can see it very well. A 3mm LED would be just too small and flimsy and be harder to spot. The pulses from the ACI do not light those LEDs up very brightly, so you want a larger, better visible, dot size.

 

b)  you can still find  5mm LEDs which have the darker red plastic seen in the very first vintage LEDs from the early 1970s. This helps with the vintage look. More modern LEDs tend to have a plastic encapsulation that has a lighter red. I think the vintage ones have a little bit of blueish tint mixed into the red (of the plastic), but I'm not sure.

 

c) 5mm LEDs are much cheaper than 3mm LEDs, if you buy 1000 of them at once. Why pay 8x the price for  smaller and flimsier ones. I think I paid $12 for one thousand of the red 5mm LEDs.

 

But this was before I saw the photo of the original ACI card. I am old enough to remember the first LED I ever saw, in 1973 or so, it was like magic. It was 5mm. One of them did cost as much as a nice lunch in a roadside restaurant: some roasted pork, and some dumplings, and  one beer. I don't remember if they had 3mm LEDs back in the early/mid 1970s. I would like to know for certain if that 3mm LED in that ACI card was in it when they made the ACI in the year 1976.

 

Comments invited !

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

Thank you for your very comprehensive answer to my question, you are a treasure trove of valuable information as always.

 

It looks like all the original ACI cards had a 3mm LED, I will attach a photo of the board produced by SCC and NTI.

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
Tests of the "improved ACI" PCBs are finished !

Dears fans,

 

I've finished all the tests of the new PCBs which incorporate all the improvements and changes known today and as I have published on Applefritter. So in the end it's nothing new, except that with the new PCBs there are no trace cuts and no added wires to implement "Uncle Bernie's improved ACI", leading to a much neater solution.

 

It works reasonable well as long as you use a good cassette recorder and a quality tape. These are the good news.

 

The bad news is that it's not yet at the same performance level as the cassette interface in the Apple II, despite the Apple II uses the same basic concept of both the TAPE IN and the TAPE OUT circuits and the firmware also is much the same as far as the method is concerned. A checksum was added in the Apple II (which my "extended format PROMs" for the ACI also have, so you can make tapes on the Apple-1 and read them into the Apple II). Normal ACI firmware PROMs just ignore the extra checksum byte, so everything stays fully forwards and backwards compatible.

 

However, the Apple II TAPE IN circuit has a slightly different circuit topology and it uses a 741 opamp in lieu of the LM311 comparator used in the ACI.

I don't know why they used the 741 (cheaper ? less temperamental in a lousy layout ?) as the theoretical performance of both circuits should be much the same (if everything is ideal). This can be proven by SPICE simulations and on the bench when using laboratory grade power supplies and signal generators.

 

Some new insights learned / discovered !

 

The only significant difference in the designed parameters for both circuits is the hysteresis: the Apple II circuit has a input referred hysteresis that is 2.9 times smaller than in the ACI circuit (input referred = TAPE IN). The Apple II circuit also attenuates the TAPE IN signal by a factor of 1/2, while the ACI circuit using a 100nF input coupling capacitor does not attenuate the signal in any significant way. The original ACI used 10nF which caused a lot of attenuation, requiring a higher signal amplitude which most cassette recorders and also typical media players can't provide.

 

My conjecture is that the cassette recorder which Woz used to develop the ACI must have had a much higher output amplitude than what we can get today, so high that it could light up the volume indicator LED circuit in its original form.

 

Had it been otherwise, the LED circuit could have been omitted because it would not have worked. Many people believe it's a botched design, and I also thought that initially, but now having all the facts on the table, I am inclined to think that it did work, back in the day, and with that particular cassette recorder Woz had used to develop it. Which may have had a different ear phone / head phone impedance. Not 8 Ohms as usual today, but higher. So, consequently, the signal amplitude available at the EAR OUT jack of that recorder must have been higher, too.

 

This conjecture brings another interesting insight: due to the much higher TAPE IN signal amplitude available with that cassette recorder, Woz was able to use a relatively large hysteresis in the comparator of the ACI. And this relatively large hysteresis is what we are fighting with today when we complain about insufficient volume of WAV or AIFF files or cassette recordings.

 

Now note that in the Apple II, the hysteresis on TAPE IN was significantly decreased over the ACI. This was certainly done for a reason. The most likely reason is that Woz had learned a lesson from Apple-1 users complaining about the ACI not working well enough with their own cassette recorders. I was told by insiders that Lisa Loop complained more about the cassette read troubles than about the random crashes of her Apple-1. So even back in the mid 1970s, there must have been cassette recorders with 8 Ohm outputs that could not produce a sufficiently high signal amplitude to make the ACI work well enough.

 

One idea that now comes in mind is to decrease the hysteresis of the ACI to the level seen in the Apple II, and all will be fine, and it would work without needing excessive volume settings. After all, the Apple II cassette interface worked well enough to keep Apple (the company) alive. Early Apple II users had to live with that cassette interface as the only available mass storage for the Apple II until the Disk II system came out in 1978. Apple (the company) would not exist today if the Apple II cassette interface has been as bad as the ACI was.

 

So why not reduce the hysteresis of the ACI to the level seen in the Apple II to have essentially the same performance as far as the tape read reliability is concerned ?

 

Well, I tried, and it does not work. The +5V power supply in the ACI is so badly polluted / noisy that all the high side resistors spit a lot of crud into the differential inputs of the comparator. Assuming that this is common mode noise that the comparator's differential input stage would reject is a fallacy, of course. Common mode rejection works only when the differential pair is balanced and sees exactly the same parasitic signal at both inputs. Since the positive feedback making the hysteresis imbalances the differential pair, its intrinsic common mode rejection is lost except for the case where it is at the trip point, and this does not help much. To make matters worse (you may want to look at the ACI schematic to understand the following), the impedance at the two differential inputs of the LM311 is not the same. The hysteresis setting resistor of 47K causes about 10% different impedance at the "+" input by itself, but what is much worse, the 100 nF input coupling capacitor causes a massive impedance mismatch at the "-" input (compared to the "+" input where there is no such capacitor). The ill effect of that input coupling capacitor becomes evident the instant you plug in the cassette recorder cable: in an ACI with reduced hysteresis, the LED lights up (a little bit at least) even if the cassette playback is off. This is the crud from the polluted +5V supply which spits into the comparator differential inputs via the high side 10 kOhm resistors, and sees a different impedance at these inputs, so the common mode disturbance at the +5V rail morphs into a differential signal, and the comparator trips erratically, if that parasitic differential signal gets larger than the hysteresis. So,  you can't reduce the hysteresis of the ACI to the Apple II level without additional changes in the circuit to remedy this ill effect.

 

So far the background. I could develop another mod to weed out this problem once and for all, to allow an Apple II style reduced hysteresis in the ACI, but I'm not sure if that is needed. I'm currently testing the improved ACI with a multitude of cassette recorders I bought on Ebay during the last months, and so far it works fine, except for one particularly bad cassette recorder that is still sold on Ebay in unopened plastic bubble shells. "Made in China", of course. It is absolutely terrible, a piece of junk, not worth even the $20-$30 they want for it. It will go to the landfill once my work on the ACI is complete. But maybe it deserves a medal of honor as this was the first cassette recorder I tried with the ACI and because it did not work to my satisfaction, I started the mission to improve the ACI. Without that crappy little recorder, there would be no "improved ACI".

 

I will post more on the ongoing work in the coming weeks and present some of the cassette recorders in a different thread, so people can see which ones are good and which ones are bad and which ones are ugly ("The Good, The Bad, and The Ugly", one of the greatest Italo Westerns of all time, it was the breakthrough for  Clint Eastwood's acting career).

 

Comments invited !Oh, I intend to make these improved ACI PCBs available for $10 including shipping within the USA, and for $25 in total I'll also add a set of "improved ACI" PROMs with my "extended format page". You could use regular ACI PROMs, though, they plug right in, no mods needed, but then your benefit is only that the volume indicator LED finally works. Send me a PM if you are interested to buy one (or more). I won't sell those on Ebay. It's just to get rid of the prototype PCB batch. My future kits will come with these "improved ACI" PCBs as a free bonus as long as supply lasts. This is not driven by greed for profit, I just want to avoid throwing them away - ordering 30 pcs from JLCPCB did cost not much more than just making a few, so I have too many left (essentially for the same money).

 

macnoyd's picture
Offline
Last seen: 2 hours 52 min ago
Joined: Oct 15 2012 - 08:59
Posts: 753
UncleBernie, put me down for 2 ...

UncleBernie, put me down for 2 ...  and I'm in the USA.  Thank you!

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

I built your board, it looks great and works even better. I really liked the quick load feature with the C500R command!

Thanks Uncle Bernie for your hard work!

Offline
Last seen: 4 days 8 hours ago
Joined: Oct 28 2021 - 09:48
Posts: 22
Macintosh_nik wrote:I built
Macintosh_nik wrote:

I built your board, it looks great and works even better. I really liked the quick load feature with the C500R command!

 

I'm a bit puzzled about the orientation of those transistors... I guess that are different PNP/NPN types?

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
In post #17, pfuentes69 wrote

In post #17, pfuentes69 wrote:

 

I'm a bit puzzled about the orientation of those transistors... I guess that are different PNP/NPN types?

 

Uncle Bernie answers:

 

My "improved ACI" uses exactly the same visible electronic components as the  original ACI, except for the 5.1 MEG-Ohm resistor replacing the 100 kOhm resistor, so these are still NPN transistors. But what you see in macintosh_niks photo is what happens when you use typical European NPNs like the BC548C  which have the CBE sequence reversed from the MPS3704 (or the 2N3904 I provide with my kits).

 

I know that for certain because I've built one ACI with BC548C and then the orientation is turned 180 degrees, like in macinstosh_niks photo.

 

As a general rule, in the Apple-1 and in the ACI you can use any NPN small signal transitor except for the low beta high voltage types (advertised as "CRT cathode driver transistor" and such). As long as this rule is followed, the video output stage of the Apple-1 works fine. The ACI prefers to have NPNs with a beta better than 200, but 100 also works. You can select transistors with the "hfe" setting on any cheap digital multimeter having a transistor test socket. If you get the CBE sequence right, then your beta ("hfe") is good,  but if you reverse C and E then the transistor works in reverse mode and the beta will be poor, typically single digit. This happens because now the collector tub works as the emitter, and the tiny emitter dot tries to catch the electrons, but most elude it and escape via the base connection, so the current gain is very poor).

 

Other than the 180 degree orientation difference, European transistors work just fine in the ACI. There is no reason to hunt for the long extinct and expensive MPS3704. These still do exist and a specialized company still makes them in small batches but they cost more than 50 cents each, 10 x more than what a typical small signal NPN should cost.

Offline
Last seen: 4 days 8 hours ago
Joined: Oct 28 2021 - 09:48
Posts: 22
Wow, I didn't know that this

Wow, I didn't know that this wasn't standardized... I understand now why sometime ago a went crazy with an small project...2

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

I have the Nation 3704, I just screwed up and put them backwards in a hurry. But everything works! Does it make sense to turn them around?

Offline
Last seen: 4 days 8 hours ago
Joined: Oct 28 2021 - 09:48
Posts: 22
Oh! now this took an

Oh! now this took an "interesting twist" (pun intended) :)

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
About reversing transistors.

In post #20, macintosh_nik wrote:

 

"I have the Nation 3704, I just screwed up and put them backwards in a hurry. But everything works! Does it make sense to turn them around?"

 

Uncle Bernie answers:

 

Does "everything works" mean that the volume indicator LED also works as intended ? Shining nice and bright when there is a signal of sufficient volume on TAPE IN, and going dark when there is no such signal ?

 

I did not investigate this (no time for that) but for a reverse operation beta of 6...7 the Darlington configuration should have a compounded beta of 36...49 which is still very low, but might light up a (sensitive, low current) LED a little bit in some cases. Just a conjecture of mine.

 

In any case, before you change anything, try your transistors out in the transistor test socket of a multimeter. Maybe these transistors you have came from China and they are counterfeit and they were made from European style NPNs which have the reverse CBE sequence. Who knows. Nowadays we must expect that each and every electronic component you can buy is counterfeit. This applies to brake discs used in airliners, too. And all other "yellow tag" parts used in aviation, where such a counterfeit part can easily kill a few hundred people. There are counterfeit "high strength" bolts, too, which are just the usual weaker bolts, and these may end up in your car. I have the suspicion that most of the premature deaths of electronics PCBs in cars or household appliances - which plague the whole nation - are caused by counterfeit electronic components the crafty Chinese have substituted for the real ones, and then they sold the real ones on alibaba and other places. I know about this problem first hand - if you produce anything electronic in China, you must have at least two quality inspectors 24/7 on the manufacturing floor, otherwise the Chinese will change the reels with the valuable genuine parts against reels with counterfeit / crappy parts behind your back. And they try every trick in the book to disable your quality inspectors, such as invitation to dinners with a lot of alcoholic beverages etc., so the inspector is unable to do the job the next morning. This is when they change the reels.

 

BTW,  there are WORSE transistor pinouts where the base is not in the middle position. These must be avoided for the Apple-1 because despite you can bend the pins into the right sequence, the outcome always looks not quite right.

 

Macintosh_nik's picture
Offline
Last seen: 3 hours 29 min ago
Joined: Jan 8 2021 - 05:18
Posts: 168
Hi Uncle Bernie!

I moved my Nation 3704, the LED now burns noticeably brighter! I took a picture of everything, the first picture with the wrong oriented transistors, the second picture with the correct one. I bought them in the USA, not in China.

Offline
Last seen: 20 hours 36 min ago
Joined: Apr 1 2020 - 16:46
Posts: 400
Transistors in reverse mode still have gain !

In post #23, macintosh_nik wrote:

 

"I moved my Nation 3704, the LED now burns noticeably brighter ! "

 

Uncle Bernie comments:

 

You see, that with a sensitive LED even transistors in reverse mode can produce enough gain to light the LED up, although not as bright as it could be. As I have predicted in post #22.  Actually, there exist trick circuits within some analog ICs where this reverse mode operation is used to do certain work under certain conditions. There is still some current gain in reverse mode, although not much. But enough to do tricks.

 

Darlington operation is a very powerful concept. The current gain multiplies. So if you put three NPNs in Darlington configuration and each has a beta of 300, you get 300 x 300 x 300 = 27,000,000 (twenty seven million) in current gain.  Add a LED, a current limiting resistor for the LED, a 9V battery, and a 20" long stick antenna (i.e. from an old clothes hanger) and you have a "ghost detector" for your kids (if any). If a "ghost" is near, this device will detect it and the LED will light up. A lot of fun ! Because it's "magic".

 

(Actually, the "ghosts" being detected by this device are a few small charged particles which occur randomly and float around in the house, think dust etc. The circuit is closed to earth. So make sure to build the ghost detector such that the operator touches the circuit ground = minus pin of the 9V battery with his hand / fingers).

 

Log in or register to post comments