Collen wrote:
Ah, thx that makes more sense to me..
so basicly i can use the via ports (j3) on the W65C02SXB and W65C816SXB for GPIO
but how about the W65C134SXB and W65C265SXB (and not to forget the mensch computer) ?
they don't have a VIA w65c22... but they do have I/O ports (j3/j4/j5)
The W65C265SXB (I can't speak to the 134) has a LOT of ports available. 7, I think.
HOWEVER, depending on how you configure the CPU, many of those ports get used up for other things. The Pi does the same thing.
For example, some of the ports on the 256 are used for the on board UART. Also, if you wish to address external memory, a bunch of the ports get used for the Address and Data bus. It's actually a shame the 256 can't be configure to use a 16 bit address bus instead of the full 24 bit one to free up a port.
In the end, if you're using external memory, and the serial ports, there's only 1 full port, and parts of another I think, available for generic applications. It's another shame that the 256 doesn't have any on board flash, but was designed to have a ROM masked in to it at production for your "custom code". Great if that's your application, not so much for one off uses like hobbyists.
Quote:
also isn't the via only 0 or 1 ?!
you can't read (lets say) a temperature from a sensor that way...
Correct. If you have access to an analog temperature sensor, you would need an Analog to Digital (A/D) Converter. These take analog values (voltages) and turn them in to bits for something like a VIA/GPIO. Speaking of SPI, there are A/D converters that you can interface with via SPI.
We have
this thread semi-dedicated to W65C265SXB.