Jump to content
IGNORED

ColecoVision - 74LS541 for controllers


mayor

Recommended Posts

Hi,

 

if anyone with a ColecoVision could verify something, I'd really appreciate it. For the unit I have, pin 1 of the two controller 74LS541s never go down to 0. They stay at 4.4V, which means that the outputs remain in High-Z. Could anyone verify whether their unit's 541s go to 0 (or at least below 2V) once the controllers are enabled? Seems like they should.

 

Thanks!

Link to comment
Share on other sites

In my experience they can and do get zapped. It's so much fun having to take apart a Colecovision, desolder the old chip, then replace it, oh and don't forget having to order replacement chips first. And a socket, because of course it could happen again.

 

My guess is that the -5 bias that gets put on the controller mode select line (assuming the schematic I have is correct) can eventually zap the LS541 inputs, though it may take a short in the controller cable for it to happen. TTL very much does not like negative voltages on its inputs. This is sort of the hardware equivalent of the WTF in the ROM where they made a subroutine to do the EX HL,DE operation. WTF were they thinking?

Edited by Bruce Tomlin
Link to comment
Share on other sites

1 hour ago, Bruce Tomlin said:

My guess is that the -5 bias that gets put on the controller mode select line (assuming the schematic I have is correct) can eventually zap the LS541 inputs, though it may take a short in the controller cable for it to happen. TTL very much does not like negative voltages on its inputs. This is sort of the hardware equivalent of the WTF in the ROM where they made a subroutine to do the EX HL,DE operation. WTF were they thinking?

The -5V bias affects U24, but it's only connected to the output, and through a 1.5K resistor.  I think its purpose is to pull the "low" voltage to zero instead of the slightly zero that you get from a low output.  Anyway, it shouldn't hurt the final stage of a TTL's output.  And when the output is high, the -5 is completely overpowered by the high.

Link to comment
Share on other sites

I'll capture some scope traces, but it looks like the inputs are pulsed, is that correct? And the output from these looks very strange. Mind you, the chips appear to work, in that shorting the right inputs at the controller port produces the expected result. I am working on a wireless interface and want to make sure I understand the way the ports work.

Link to comment
Share on other sites

11 minutes ago, mayor said:

I'll capture some scope traces, but it looks like the inputs are pulsed, is that correct? And the output from these looks very strange. Mind you, the chips appear to work, in that shorting the right inputs at the controller port produces the expected result. I am working on a wireless interface and want to make sure I understand the way the ports work.

If you're talking about the controllers, pins 5 and 8 are alternated high and low in order to read the joystick vs the keypad.  The other 7 pins are sampled by the ICs in question.  When the proper combination of enable signals arrive, each IC will enable the bus outputs.

Link to comment
Share on other sites

Yep, got that part down. But pin 1 appears to only go low at roughly 60Hz for two short pulses, making it seem like the controllers are being sampled rather than being interrupt-driven (I admit I haven't yet read anything about the Z80). Do you observe the same in your CV? 

Link to comment
Share on other sites

Yes, the sampling is purely under software control, and most people do it each frame, which means about 60Hz.  The interrupt line is only for the roller on the SAC or the trackball, which signals that there is a sample to read.  This allows games to immediately sample the roller inputs to see if the roll was left or right, before the data becomes invalid.

Link to comment
Share on other sites

On 10/7/2019 at 11:29 PM, ChildOfCv said:

The -5V bias affects U24, but it's only connected to the output

And where does that output go? To the controller port, where not only can it be fed back through the controller, but through accidental shorts with input pins/wires. That's a male connector, all it takes is something metal brushing against two pins. It could also possibly happen with non-standard controllers. (what happens if you plug in a 2600 paddle controller?) But this is all speculation about a dubious design decision.

On 10/7/2019 at 11:29 PM, ChildOfCv said:

Anyway, it shouldn't hurt the final stage of a TTL's output.

It's not the outputs that are in danger, it's the inputs. (otherwise it wouldn't be the '541 that gets damaged) TTL has protection diodes on its inputs that are reverse-biased, and can be very easily blown with negative voltages.
 

What is not speculation is that I have actually encountered (and replaced) '541s with blown inputs. It is a real problem with the Colecovision that these chips can get damaged, in spite of being TTL.

Edited by Bruce Tomlin
Link to comment
Share on other sites

5 hours ago, Bruce Tomlin said:

And where does that output go? To the controller port, where not only can it be fed back through the controller, but through accidental shorts with input pins/wires.

It's typically the input clamping diodes in a TTL circuit that fail first, since they have a direct feed from ground.  Their very purpose is that the input voltage is expected to ring negative from connected outputs, and they limit that ringing.  They only begin clamping about -1.5V though.  So they have to handle -5-(-1.5)V through 1.6K of resistance, around 2mA, and that's if the 5V pullups on the inputs fail.

 

controller.PNG.8a1fe28c27914fe81b037b75eb59d0bc.PNGHere's a condensed version of the controller schematic.  Between the +5V and the -5V runs around 0.39mA.  Tracing the voltage levels up to the input at A0, we get -4.3V when a direction is down, discounting the input clamp diode.  The clamp diode only cares about anything below -1.5V, so it only needs to pull (4.3-1.5)/1.6K = 1.7mA.  Quite doable for a TTL chip.

 

5 hours ago, Bruce Tomlin said:

 

It could also possibly happen with non-standard controllers. (what happens if you plug in a 2600 paddle controller?) But this is all speculation about a dubious design decision.

Well, the only one that matters is pin 7 to 5, which will also be through at least a few K and up to a megaohm of resistance, which further lessens the impact.  The other paddle of the pair connects pin 7 to 9, which is innocuous.

5 hours ago, Bruce Tomlin said:

What is not speculation is that I have actually encountered (and replaced) '541s with blown inputs. It is a real problem with the Colecovision that these chips can get damaged, in spite of being TTL.

People have also blown the 6532 and TIA inputs in their Ataris, which have no negative voltages.  The issue is not a few negative milliamps, but huge jolts of static electricity as people on the living room carpet grab the joystick plug or touch the pins directly.  Atari, for their part, added to the field service manual that when a unit goes in for service, they solder on a network of zener diodes to take the shock in place of the expensive chips.  And at least one CV I've seen has been modified the same way.

 

Link to comment
Share on other sites

@ChildOfCv : I'm trying to understand why they chose -5V instead of going to ground. Right now, the best range for this arrangement is roughly -0.3V to +0.1V, which seems an odd choice, given it would have been easy to get, say, 0 to 3V, and be sure to trigger the output of the 541. Do you know what motivates this choice? 

 

In my circuit, I was hoping to avoid the diode from the controller, and just short the inputs with green/grey/blue, but this results in a range from -0.6V to -0.2V. Seems to work when I just short the inputs, but I'm not too sure about the longer-term impact.

Link to comment
Share on other sites

I think it's due to the use of the 7400 flipflop circuit, then going through diodes in the controller.  TTL requires a "low" to be less than 0.8V, so a diode with a theoretical 0.7V forward voltage drop is already pushing it.  Then output transistors can't pull all the way to 0, so add another fraction of a volt for the 7400.  Now you're too close to the no-mans-land where output voltages for the 541 cannot be guaranteed.  So they probably made the decision to apply a negative bias to make sure the controller can do the job.

Link to comment
Share on other sites

OK so I've done a bit of digging. As far as I can tell:

* Joystick is sampled roughly 60 times / second

* During the sample interval, two samples are taken (~30 us apart)

   - One sample for joystick + left button

   - One sample for keypad + right button

   - Goes low 4 times, but pin 19 of 74LS541 is high for 2nd and 4th, so these samples are not used

NewFile12.thumb.png.df63a2ffe9eea8d7ca9f23a48ed49743.png

 

 

* The 74LS00

   - drives joystick pin 8 (grey wire) low for the first sample

   - drives joystick pin 5 (green wire) low for the second sample

   - scope channel 2 is output of 74LS00:6 / joystick/left button sampling (goes high on 2nd sample to avoid sampling pad/right button, pin 3 is reverse that)

NewFile15.thumb.png.80c537b4d69e477b2318b0c5f3c61b64.png

 

 

* Inputs to 74LS541 are normally pulled up (~3V during sample window)

* Scope channel 1 shows open joystick contact at output of 74LS541 during first sample:

NewFile13.thumb.png.800986649eb910fe4067720969724f0c.png

 

 

...closed joystick contact brings 74LS541 output low, thanks to the 74LS00 being low at that time:

NewFile14.thumb.png.c5aa1c8a11a0107244724cfd75ebf025.png

 

I think this clarifies how the joysticks are sampled. Not too sure about the extra two samples, but they appear inconsequential to me. This can hopefully help someone else in the future.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...