i_r_on wrote:
What I want to store is around 43 bytes of 6502 code. It would be requiring 6 inputs and needs only 8 outputs.
One approach is to treat each of the 8 outputs driving the 65xx bus (d7 - d0) as its own combinatorial equation. The datasheet says,
"In combinatorial mode the pin associated with an individual OLMC is driven by the output of the sum term gate. Logic polarity of the output signal at the pin may be selected by specifying that the output buffer drive either true (active high) or inverted (active low)."
So, taking d0 for an example, and considering the code you intend to store, you assign a product term for every address in which d0 must equal one. And you're allowed about ten product terms -- these are the inputs to the sum term gate.
Assuming a 50:50 distribution of ones and zeroes, a 20-byte EPROM can be simulated. That is, ten addresses trigger a product term and thus the sum term gate, sending d0 high. The other ten addresses produce no response (defaulting to zero on d0).
It's to your advantage if the distribution of ones and zeroes deviates from 50:50. For example if you wanted to raise the capacity to 64 address locations, and your code is such that only ten locations contain a one, it will fit (because ten is how many terms we can afford). If the distribution bias is in the other direction, and only ten locations contain a
zero, again it will fit. As noted, Logic polarity of the output signal can be inverted, changing the default to one.
Other approaches could offer other opportunities, for example by exploiting relations between the d7 - d0 bits rather than treating each one individually.
cheers,
Jeff
_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html