Class ArchXT_Port
Defined in File arch_xt_port.h
Inheritance Relationships
Base Types
public Port(Class Port)public InterruptHandler(Class InterruptHandler)
Class Documentation
-
class ArchXT_Port : public Port, public InterruptHandler
Implementation of a GPIO port controller for XT core series, based on the generic Port class.
The Slewrate limit is unsupported.
Public Functions
-
ArchXT_Port(char name, const ArchXT_PortConfig &config)
-
virtual bool init(Device &device) override
Virtual method called when the device is initialised. This is where the peripheral can allocate its I/O registers, interrupts or connect signals.
- Returns:
boolean indicates the success of all allocations.
-
virtual void reset() override
Virtual method called when the device is reset. Note that resetting I/O registers is only necessary here if their reset value is not zero.
-
virtual uint8_t ioreg_read_handler(reg_addr_t addr, uint8_t value) override
Virtual method called when the CPU is reading a I/O register allocated by this peripheral. The value has not been read yet so the module can modify it before the CPU gets it.
- Parameters:
addr – the register address in I/O space
value – current cached value of the register
- Returns:
actual value of the register
-
virtual void ioreg_write_handler(reg_addr_t addr, const ioreg_write_t &data) override
Virtual method called when the CPU is writing a I/O register allocated by this peripheral. The value has already been written.
- Parameters:
addr – the register address in I/O space
value – the new register content
-
ArchXT_Port(char name, const ArchXT_PortConfig &config)