8302 pinout help request...

Nagging hardware related question? Post here!
User avatar
tofro
Font of All Knowledge
Posts: 2685
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: 8302 pinout help request...

Post by tofro »

janbredenbeek wrote: On the other hand, the network is a simple CSMA/CD half-duplex circuit (unlike the SER ports) and the software has to sense its state while transmitting - I guess using a hardware shift register would make things much more complex.
Calling the QL Network CSMA/CD is maybe not doing much justice to its simplicity. :D

Actually, the network is a bit-banged serial port as well, and collision detection is limited to the first ten bits (the bit-reversed station #, what Sinclair calls "the scout") of 255+ or 1024+ (TK2) bytes packets. Collisions within packets are only caught by the packet checksum.

Tobias


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
Nasta
Gold Card
Posts: 443
Joined: Sun Feb 12, 2012 2:02 am
Location: Zapresic, Croatia

Re: 8302 pinout help request...

Post by Nasta »

Though, collisions could be detected on any bit considering that it happens when the transmitted and received bit is not the same (the system is high-dominant, a high on the line from any transmitter over-rides the low state).


User avatar
tofro
Font of All Knowledge
Posts: 2685
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: 8302 pinout help request...

Post by tofro »

Theoretically yes, but that was most probably considered unnecessary - As the network listens for "silence" for a considerable time before actually starting a transmission, a collision is only likely at the beginning of a packet (or a misbehaving network station). Network timing is pretty tight anyhow, with the QL bit-banging bits at 87.5kbps, even without single-bit in-packet verification.

Tobias


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
Dave
SandySuperQDave
Posts: 2765
Joined: Sat Jan 22, 2011 6:52 am
Location: Austin, TX
Contact:

Re: 8302 pinout help request...

Post by Dave »

If that is using the same hardware in the ULA, why is the QL serial port so terrible?


User avatar
janbredenbeek
Super Gold Card
Posts: 629
Joined: Wed Jan 21, 2015 4:54 pm
Location: Hilversum, The Netherlands

Re: 8302 pinout help request...

Post by janbredenbeek »

Dave wrote:If that is using the same hardware in the ULA, why is the QL serial port so terrible?
IMHO the transmit side is OK but the receive side (handled by the 8049) is terrible.

Jan.


Nasta
Gold Card
Posts: 443
Joined: Sun Feb 12, 2012 2:02 am
Location: Zapresic, Croatia

Re: 8302 pinout help request...

Post by Nasta »

Jan,
You seem to have studied that code quite a lot - would it be possible for you to write a small expanation on the 8302 internal registers and their use?
Interesting that the same serial hardware is used for MDV, this would open some interesting possibilities but as far as I know it's half duplex (either read OR write, given the same pin is input and output)...
In theory it has 8 registers, given that A0,1 and 5 are used to address the internals...


User avatar
janbredenbeek
Super Gold Card
Posts: 629
Joined: Wed Jan 21, 2015 4:54 pm
Location: Hilversum, The Netherlands

Re: 8302 pinout help request...

Post by janbredenbeek »

Nasta wrote:Jan,
You seem to have studied that code quite a lot - would it be possible for you to write a small expanation on the 8302 internal registers and their use?
Interesting that the same serial hardware is used for MDV, this would open some interesting possibilities but as far as I know it's half duplex (either read OR write, given the same pin is input and output)...
In theory it has 8 registers, given that A0,1 and 5 are used to address the internals...
Hi Nasta,

There is an excellent explanation in section 18.13 of the QDOS/SMS Reference Manual.
The 8302 indeed has 8 registers (at $18000-$18003 and $18020-$18023). On reading, $18000-$18003 are the clock longword and $18022-$18023 the MDV read data registers (one for each track). $18020 is the MDV/serial/IPC status register.
On writing, $18000-$18001 are used to set the clock, $18002 is the transmit control register, $18003 the IPC write register, $18020 is for MDV control, $18022 the transmit data register.
Register $18021 is the interrupt register (read status and write for acknowledge or mask interrupts).

When looking at the circuit diagram it appears that the 8302 sends and receives the MDV data on the RAW1 and RAW2 lines (pin 19 and 21). I doubt if these are usable for a high-speed serial interface. First of all the rate is fixed, it's half duplex and (most important) there is no buffering at all of the serial data in the 8302 itself. This means that you have to read the incoming byte as soon as possible when the 'read buffer ready' bit goes on, else it gets overwritten by the next byte.

Given the above fact, it was a clever decision to use the 8049 IPC as serial input device, if only they would have implemented it properly...

Jan.


Post Reply