ZSTTY(4)

๐Ÿ“ฆ version 11.0, in nixpkgs unstable

๐ŸŽ€ ZSTTY(4) ยท Kernel Interfaces Manual ๐ŸŽ€

โœจ NAME โœจ

zstty, zsc, zs โ€” Zilog 8530 Serial Communications Controller (SCC) for RS-232C, RS-422, and RS-423 ๐Ÿฆ‹


๐ŸŒˆ SYNOPSIS ๐ŸŒˆ

okay bestie, hereโ€™s the kernel config tea โ€” exact characters only, no vibes-based edits ๐Ÿ’…

options PPS_SYNC
options PPS_TRAILING_EDGE

alpha (DEC 3000) ๐Ÿ“

zsc0 at ioasic? offset 0x100000
zsc1 at ioasic? offset 0x180000
zstty0    at zsc0 channel ?   # serial ports on B channels
zstty2    at zsc1 channel ?   # serial ports on B channels
lkkbd0    at zsc1 channel ?   # keyboard port on A channels
vsms0     at zsc0 channel ?   # mouse port on A channels

cesfic ๐ŸŒฟ

zsc* at mainbus0
zstty*    at zsc? channel ?

cobalt ๐Ÿ’Ž

zsc0 at mainbus? addr 0x1c800000 irq 4
zstty0    at zsc0 channel 0
zstty1    at zsc0 channel 1

ews4800mips ๐ŸŒธ

zsc0 at sbdio?
zstty0    at zsc? channel 0   # SIO ch-A
zstty1    at zsc? channel 1   # SIO ch-B

mac68k and macppc ๐Ÿ‹

zsc0 at obio?
zstty*    at zsc? channel ?
options ZS_TXDMA

mipsco ๐Ÿฉท

zsc0 at obio0 addr 0xbb000000
zstty0    at zsc0 channel 0
zstty1    at zsc0 channel 1

mvme68k ๐ŸงŠ

zsc* at pcc? ipl 4
zsc* at pcctwo? ipl 4
zstty*    at zsc? channel ?

news68k ๐Ÿ€

zsc0 at hb0 addr 0xe0d40000 ipl 5 vect 64 flags 0x0    # news1700
zsc0 at hb1 addr 0xe1780000 ipl 5 vect 64 flags 0x1    # news1200
zstty0    at zsc0 channel 0
zstty1    at zsc0 channel 1

newsmips ๐Ÿ”ฎ

zsc0 at hb0 addr 0xbfec0000 level 1 flags 0x0     # on-board
zsc1 at hb0 addr 0xb8c40100 level 1 flags 0x1     # expansion board
zsc2 at hb0 addr 0xb8c40104 level 1 flags 0x1
zsc0 at ap?
zstty0    at zsc0 channel 0
zstty1    at zsc0 channel 1
zstty2    at zsc1 channel 0
zstty3    at zsc1 channel 1
zstty4    at zsc2 channel 0
zstty5    at zsc2 channel 1

next68k ๐Ÿ”ฅ

zsc0 at intio? ipl 5
#zsc1     at intio? ipl 5
zstty0    at zsc0 channel 0   # Serial Port A
zstty1    at zsc0 channel 1   # Serial Port B

pmax ๐Ÿงš

zsc0 at   ioasic? offset 0x100000 # Z85C30
zsc1 at   ioasic? offset 0x180000 # Z85C30
zstty*    at   zsc? channel ?      # serial ports on B/A channels
lkkbd*    at   zsc1 channel ?      # keyboard port on A channels
vsms*     at   zsc0 channel ?      # mouse port on A channels

sgimips ๐Ÿชฉ

zsc*      at hpc0 offset ?
zstty*    at zsc? channel ?

sparc ๐ŸŒž

zs0  at mainbus0                   # sun4c
zs0  at obio0                 # sun4m
zs0  at obio0 addr 0xf1000000 level 12  # sun4/200 and sun4/300
zs0  at obio0 addr 0x01000000 level 12  # sun4/100
zstty0    at zs0 channel 0              # ttya
zstty1    at zs0 channel 1              # ttyb
zs1  at mainbus0                   # sun4c
zs1  at obio0                 # sun4m
zs1  at obio0 addr 0xf0000000 level 12  # sun4/200 and sun4/300
zs1  at obio0 addr 0x00000000 level 12  # sun4/100
kbd0 at zs1 channel 0              # keyboard
ms0  at zs1 channel 1              # mouse
zs2  at obio0 addr 0xe0000000 level 12  # sun4/300
zstty2    at zs2 channel 0              # ttyc
zstty3    at zs2 channel 1              # ttyd

sparc64 ๐Ÿฆ„

zs*  at sbus? slot ? offset ?
zs*  at fhc?
zstty*    at zs? channel ?              # ttys
kbd0 at zstty?
ms0  at zstty?

sun2 โ˜€๏ธ

zs0  at obio0 addr 0x002000   # 2/120, 2/170
zs1  at obmem0 addr 0x780000  # 2/120, 2/170
zs0  at obio0 addr 0x7f2000   # 2/50
zs1  at obio0 addr 0x7f1800   # 2/50
zs2  at mbmem0 addr 0x080800  # 2/120, 2/170 (first sc SCSI)
zs3  at mbmem0 addr 0x081000  # 2/120, 2/170 (first sc SCSI)
zs4  at mbmem0 addr 0x084800  # 2/120, 2/170 (second sc SCSI)
zs5  at mbmem0 addr 0x085000  # 2/120, 2/170 (second sc SCSI)
zstty*    at zs? channel ?    # ttya
kbd0 at zstty?      # keyboard
ms0  at zstty?      # mouse

sun3 ๐ŸŒฑ

zstty0    at zsc1 channel 0   # ttya
zstty1    at zsc1 channel 1   # ttyb
kbd0 at zsc0 channel 0   # keyboard
ms0  at zsc0 channel 1   # mouse

x68k ๐Ÿ’

zsc0 at intio0 addr 0xe98000 intr 112
zstty0    at zsc0 channel 0        # built-in RS-232C
ms0  at zsc0 channel 1        # standard mouse
#zsc1     at intio0 addr 0xeafc00 intr 113
#zstty2   at zsc1 channel 0
#zstty3   at zsc1 channel 1
#zsc2     at intio0 addr 0xeafc10 intr 114
#zstty4   at zsc2 channel 0
#zstty5   at zsc2 channel 1

๐Ÿ’… DESCRIPTION ๐Ÿ’…

okay so the zstty driver provides TTY support for Zilog 8530 Dual UART chips. Thatโ€™s the whole gig, bestie ๐Ÿ’–

Input and output for each line can be set to any baud rate in the range 50 to 38400 โ€” and higher on some machines, ngl โœจ

The PPS_SYNC option enables code that uses the Data Carrier Detect (DCD) signal line for attachment to an external precision clock source (e.g., GPS, CDMA) which generates a Pulse Per Second (PPS) signal. This is used by ntpd(8) to discipline the system clock, and to more accurately count/measure time. Peep options(4) for more discussion ๐Ÿซถ


๐ŸŽ€ FILES ๐ŸŽ€

alpha ๐Ÿ“

  • /dev/ttyB0
  • /dev/ttyB1

pmax ๐Ÿงš

  • /dev/ttya
  • /dev/ttyb
  • /dev/ttyc
  • /dev/ttyd

sparc ๐ŸŒž

  • /dev/ttya
  • /dev/ttyb
  • /dev/ttyc
  • /dev/ttyd

sparc64, sun2, sun3 ๐ŸŒ™

  • /dev/ttya
  • /dev/ttyb

others ๐Ÿฆ‹

  • /dev/ttyZ0
  • /dev/ttyZ1

๐Ÿšจ DIAGNOSTICS ๐Ÿšจ

  • zs0*: fifo overflow โ€” the on-chip โ€œFIFOโ€ has overflowed and incoming data has been lost ๐Ÿ˜ญ This generally means the machine is not responding to interrupts from the ZS chip fast enough, which can be remedied only by using a lower baud rate.
  • zs0*: ring overflow โ€” the software input "ring" has overflowed. This usually means input flow-control is not configured correctly (i.e. incorrect cable wiring). Check the cables, bestie ๐Ÿซ 

๐Ÿ‘€ SEE ALSO ๐Ÿ‘€


๐Ÿ“œ HISTORY ๐Ÿ“œ

The zstty driver was derived from the sparc zs driver supplied with 4.4BSD Unix. Vintage lore, honestly ๐Ÿ‘‘


โš ๏ธ CAVEATS โš ๏ธ

/dev/ttyB1 on alpha is created by MAKEDEV(8) with minor number 2, so the corresponding device should be zstty2, not zstty1. Important plot twist, bestie ๐Ÿ’€

๐Ÿ’€ BUGS ๐Ÿ’€

The old Zilog 8530 chip has a very small FIFO (3 bytes?) and therefore has very strict latency requirements for the interrupt service routine. This limits the usable baud rates on many machines. Not iconic of it, fr fr ๐Ÿ˜ญ


thatโ€™s the whole page, bestie โ€” source/version Debian, dated September 12, 2017, and this was ZSTTY(4) ๐Ÿ’–๐ŸŽ€๐ŸŒธ

๐Ÿ“ฆ where this page comes from