[][src]Module spectrusty::peripherals::serial

Serial port related API and emulation of ZX Spectrum's peripheral devices using serial communication.

The terminology regarding serial port pins/lines being used in ZX Spectrum's technical documentation:

  • RxD (Receive Data) Transmitted data from Spectrum to the remote device.
  • CTS (Clear to Send) Tells remote station that Spectrum wishes to send data.
  • TxD (Transmit Data) Received data from the remote device.
  • DTR (Data Terminal Ready) Tells Spectrum that the remote station wishes to send data.

Structs

KeypadKeys

Every key's state is encoded as a single bit on this 20-bit flag type.

NullSerialPort

A serial port device that does nothing and provides a constant ControlState::Inactive signal on the DTR line and a DataState::Mark signal on the TxD line.

Rs232Io

The RS-232 serial port remote device.

SerialKeypad

The ZX Spectrum 128 extension keypad.

Enums

ControlState

A type representing a state on one of the CONTROL lines: CTS or DTR.

DataState

A type representing a state on one of the DATA lines: RxD or TxD.

Constants

BAUD_RATES

Spectrum's BAUD RATES.

DEFAULT_BAUD_RATE

A default BAUD RATE used by Spectrum.

Traits

SerialPortDevice

An interface for emulating communication between a ZX Spectrum's hardware port and remote devices.