snowsh
Well-known member
OK, start at the start....
I have a mixing console that was built in the 80s and uses a z80 to control switching of audio routing, leds and detect button presses.
The console consists of 7 motherboards, each board supports 8 channels. Each channel has 4 CS lines...
I have successfully reversed engineered the data architecture and now have control of this console using for now an arduino Mega 2560 rev3 (i had one here , its 5v pins, lots of pins.)
I will eventually use a teensy, most likely with shift registers to control the 24 5v address/data/control lines.
for now though I have a problem that has been baffling me for a week already. Last night I may have found some clues as to my issue....
Each motherboard, on the data, address, control lines has 3* 74LS245 octal bus tranceivers to buffer the bus to each motherboard. The data bus is different to the address and control bus lines in that it can operate bi-directionally and its dir pin is connected to the RD line. All of this is in place, has been since the 80s and just works fine - with the clunky z80.
The data bus then leads to 3X PIA chip PD71055 Parallel Interface Unit. these give 3X 8bit ports. by default on reset these are set to input so this is why I can read buttons. The setup routine sets some ports to output to enable data to be sent to them. The PIA acts as a latch and holds the values sent to it which then control a whole bunc of 4053s digital switches.
Using the Mega connected directly to the motherboard via a ribbon connector and jumper wires, I can read button events fine. It seems reading from this LS245 is fine. I should note at this point the "Channel" side of the LS245 (b side) all lines are pulled high via a 22k resistor package. Pressing any of the "digital" momentary switches grounds the line and the Mega reads the new value and calculates the button press event. This is all good and works well. Very well. In fact, with my current delay() routines when manipulating the console, 7 motherboards * channels * 16-20 switches are all scanned and read in about 100 milliseconds. Im very happy with that.
The problem I have is when I need to reverse the direction of the LS245 to write data to the bus. When I scope voltage on the Mega side (a) of the LS245 I see the expected +5v or 0v depending on the bit set. However when I scope its corresponding pin on the b side (channel side), it is allways high.
I did allot of reading last night and am starting to buid a picture of what the problem might be. It seems the logic family might be important here. Of course I am changing from a z80 to currently a Mega, eventually a teensy - most likely a 4.1 becuase I want it to do many other things. In fact I may well stick with the mega to read and write to the console, and control that via the teensy.
One post I read last night which was slightly off the topic, but gave me some insight has suggested that the Arduino may not be able to pull the logic of the b side low because of the resistors pulling it high. It might not have enough "grunt"....
I dont want to have to modify the circuit or any components in the existing console.
Does anyone have any insight into this? Looking at the schematics for the Z80 board I am hoping to replace, it connects to the bus using a 74HTC245. I wonder if a simmilar approach for my replacement is a good solution. It will protect the new microcontroller and associated circuit from the rest of the console to a degree.
So the question ultimately is this:
Why wont a mega 2560 rev3 pull the b pins low on a 74LS245 ?
Why do I want to do this? I want to be able to reprogram the console, add midi and a load of new features. I dont want to mess around with a 40 year old microcontroller or try to learn assembly!
I have a mixing console that was built in the 80s and uses a z80 to control switching of audio routing, leds and detect button presses.
The console consists of 7 motherboards, each board supports 8 channels. Each channel has 4 CS lines...
I have successfully reversed engineered the data architecture and now have control of this console using for now an arduino Mega 2560 rev3 (i had one here , its 5v pins, lots of pins.)
I will eventually use a teensy, most likely with shift registers to control the 24 5v address/data/control lines.
for now though I have a problem that has been baffling me for a week already. Last night I may have found some clues as to my issue....
Each motherboard, on the data, address, control lines has 3* 74LS245 octal bus tranceivers to buffer the bus to each motherboard. The data bus is different to the address and control bus lines in that it can operate bi-directionally and its dir pin is connected to the RD line. All of this is in place, has been since the 80s and just works fine - with the clunky z80.
The data bus then leads to 3X PIA chip PD71055 Parallel Interface Unit. these give 3X 8bit ports. by default on reset these are set to input so this is why I can read buttons. The setup routine sets some ports to output to enable data to be sent to them. The PIA acts as a latch and holds the values sent to it which then control a whole bunc of 4053s digital switches.
Using the Mega connected directly to the motherboard via a ribbon connector and jumper wires, I can read button events fine. It seems reading from this LS245 is fine. I should note at this point the "Channel" side of the LS245 (b side) all lines are pulled high via a 22k resistor package. Pressing any of the "digital" momentary switches grounds the line and the Mega reads the new value and calculates the button press event. This is all good and works well. Very well. In fact, with my current delay() routines when manipulating the console, 7 motherboards * channels * 16-20 switches are all scanned and read in about 100 milliseconds. Im very happy with that.
The problem I have is when I need to reverse the direction of the LS245 to write data to the bus. When I scope voltage on the Mega side (a) of the LS245 I see the expected +5v or 0v depending on the bit set. However when I scope its corresponding pin on the b side (channel side), it is allways high.
I did allot of reading last night and am starting to buid a picture of what the problem might be. It seems the logic family might be important here. Of course I am changing from a z80 to currently a Mega, eventually a teensy - most likely a 4.1 becuase I want it to do many other things. In fact I may well stick with the mega to read and write to the console, and control that via the teensy.
One post I read last night which was slightly off the topic, but gave me some insight has suggested that the Arduino may not be able to pull the logic of the b side low because of the resistors pulling it high. It might not have enough "grunt"....
I dont want to have to modify the circuit or any components in the existing console.
Does anyone have any insight into this? Looking at the schematics for the Z80 board I am hoping to replace, it connects to the bus using a 74HTC245. I wonder if a simmilar approach for my replacement is a good solution. It will protect the new microcontroller and associated circuit from the rest of the console to a degree.
So the question ultimately is this:
Why wont a mega 2560 rev3 pull the b pins low on a 74LS245 ?
Why do I want to do this? I want to be able to reprogram the console, add midi and a load of new features. I dont want to mess around with a 40 year old microcontroller or try to learn assembly!