Logo SoCRocket

Transaction-Level Modeling Framework for Space Applications

Public Member Functions | Public Attributes | Static Public Attributes | List of all members
APBUART Class Reference

This class is a TLM 2.0 Model of the Aeroflex Gaisler GRLIB APBUART. Further informations to the original VHDL Modle are available in the GRLIB IP Core User's Manual Section 16. More...

#include <apbuart.h>

Inheritance diagram for APBUART:
Collaboration diagram for APBUART:

Public Member Functions

 SC_HAS_PROCESS (APBUART)
 
 SR_HAS_SIGNALS (APBUART)
 
 GC_HAS_CALLBACKS ()
 
 APBUART (ModuleName name, std::string uart_backend="ReporterIO", uint16_t pindex=0, uint16_t paddr=0, uint16_t pmask=4095, int pirq=0, bool console=false, bool powmon=false)
 
 ~APBUART ()
 Free all counter and unregister all callbacks. More...
 
void init_generics ()
 
void init_registers ()
 
void data_read ()
 
void data_write ()
 
void control_read ()
 
void control_write ()
 
void status_read ()
 
void update_level_int ()
 
void send_irq ()
 
void uart_ticks ()
 
void inc_fifo_level (uint32_t *counter)
 
virtual void dorst ()
 
void before_end_of_elaboration ()
 
- Public Member Functions inherited from APBSlave
 APBSlave (ModuleName mn, uint32_t bus_id, uint8_t vendorid, uint16_t deviceid, uint8_t version, uint8_t irq, AMBADeviceType type, uint16_t mask, bool cacheable, bool prefetchable, uint16_t address)
 
 APBSlave (ModuleName mn)
 
 ~APBSlave ()
 
- Public Member Functions inherited from APBDevice< BaseModule< DefaultBase > >
 APBDevice (ModuleName mn, uint32_t bus_id, uint8_t vendorid, uint16_t deviceid, uint8_t version, uint8_t irq, AMBADeviceType type, uint16_t mask, bool cacheable, bool prefetchable, uint16_t address)
 
 APBDevice (ModuleName mn)
 
void init_apb (uint32_t pindex, uint8_t vendorid, uint16_t deviceid, uint8_t version, uint8_t irq, AMBADeviceType type, uint16_t mask, bool cacheable, bool prefetchable, uint16_t address)
 
void init_apb_generics ()
 Initialize the APBDevice generics. More...
 
virtual ~APBDevice ()
 Empty destructor. More...
 
virtual uint16_t get_apb_device_id () const
 Returns the device id. More...
 
virtual uint8_t get_apb_vendor_id () const
 Returns the vendor id. More...
 
virtual const uint32_tget_apb_device_info ()
 
virtual const AMBADeviceType get_apb_type () const
 
virtual uint32_t get_apb_base () const
 
virtual uint32_t get_apb_mask () const
 
virtual sc_dt::uint64 get_apb_base_addr ()
 
virtual uint32_t get_apb_base_addr_ () const
 
virtual sc_dt::uint64 get_apb_size ()
 
virtual uint32_t get_apb_size_ () const
 
virtual uint32_t get_apb_relative_addr (uint32_t addr) const
 
virtual uint32_t get_apb_pindex () const
 Returns the bus id of the module (pindex) More...
 
virtual void print_apb_device_info (char *name) const
 Prints the device info of the device. More...
 
- Public Member Functions inherited from BaseModule< DefaultBase >
 BaseModule (ModuleName mn)
 
virtual ~BaseModule ()
 
virtual void init_counters ()
 
virtual void init_power ()
 
- Public Member Functions inherited from APBDeviceBase
virtual ~APBDeviceBase ()
 Empty destructor. More...
 
- Public Member Functions inherited from CLKDevice
 SR_HAS_SIGNALS (CLKDevice)
 
 CLKDevice ()
 
virtual ~CLKDevice ()
 
virtual void onrst (const bool &value, const sc_core::sc_time &time)
 
virtual void onclk (const sc_core::sc_time &value, const sc_core::sc_time &time)
 
void set_clk (sc_core::sc_clock &clk)
 
void set_clk (sc_core::sc_time period)
 
void set_clk (double period, sc_core::sc_time_unit base)
 
virtual void clkcng ()
 

Public Attributes

signal< std::pair< uint32_t,
bool > >::out 
irq
 
sc_event e_irq
 
sc_event s_irq
 
io_ifm_backend
 
uint32_t g_pirq
 
sr_param< boolg_console
 
sr_param< std::string > g_backend
 
const uint32_t powermon
 
bool overrun
 
bool level_int
 
uint32_t send_buffer
 
uint32_t recv_buffer_level
 
char recv_buffer [32]
 
uint32_t recv_buffer_start
 
uint32_t recv_buffer_end
 
- Public Attributes inherited from APBSlave
sr_register_bank< unsigned int,
unsigned int
r
 
APBSlaveSocket< 32, unsigned
int, unsigned int
apb
 
- Public Attributes inherited from CLKDevice
signal< bool >::in rst
 Reset input signal. More...
 
signal< sc_core::sc_time >::in clk
 Clock input signal. More...
 

Static Public Attributes

static const uint32_t DATA = 0x00000000
 
static const uint32_t STATUS = 0x00000004
 
static const uint32_t CONTROL = 0x00000008
 
static const uint32_t SCALER = 0x0000000C
 
static const uint32_t DATA_DEFAULT = 0x0
 
static const uint32_t STATUS_DEFAULT = 0x00000086
 
static const uint32_t CONTROL_DEFAULT = 0x80000000
 
static const uint32_t SCALER_DEFAULT = 0x0
 
static const uint32_t DATA_MASK = 0x000000FF
 
static const uint32_t STATUS_MASK = 0x00000000
 
static const uint32_t CONTROL_MASK = 0x7FFFFFFF
 
static const uint32_t SCALER_MASK = 0x00000FFF
 
static const uint32_t fifosize = 32
 

Additional Inherited Members

- Protected Attributes inherited from APBDevice< BaseModule< DefaultBase > >
uint32_t m_register [2]
 Impementation of the device register file. More...
 
sr_param< uint32_tg_pindex
 
sr_param< uint8_tg_pvendorid
 
sr_param< uint16_tg_pdeviceid
 
sr_param< uint8_tg_pversion
 
sr_param< uint8_tg_pirq
 
sr_param< uint32_tg_paddr
 
sr_param< uint32_tg_pmask
 
sr_param< uint32_tg_ptype
 
sr_param< boolg_pcacheable
 
sr_param< boolg_pprefetchable
 
- Protected Attributes inherited from BaseModule< DefaultBase >
ParameterAPIm_api
 Internal module gs param api instance. More...
 
ParameterArray m_generics
 Configuration generic container. More...
 
ParameterArray m_counters
 Performance counter container. More...
 
ParameterArray m_power
 Power counters container. More...
 
- Protected Attributes inherited from CLKDevice
sc_core::sc_time clock_cycle
 

Detailed Description

This class is a TLM 2.0 Model of the Aeroflex Gaisler GRLIB APBUART. Further informations to the original VHDL Modle are available in the GRLIB IP Core User's Manual Section 16.

Member Function Documentation

APBUART::GC_HAS_CALLBACKS ( )
APBUART::SC_HAS_PROCESS ( APBUART  )
APBUART::SR_HAS_SIGNALS ( APBUART  )

Member Data Documentation

const uint32_t APBUART::CONTROL = 0x00000008
static
const uint32_t APBUART::CONTROL_DEFAULT = 0x80000000
static

Referenced by init_registers().

const uint32_t APBUART::CONTROL_MASK = 0x7FFFFFFF
static

Referenced by init_registers().

const uint32_t APBUART::DATA = 0x00000000
static
const uint32_t APBUART::DATA_DEFAULT = 0x0
static

Referenced by init_registers().

const uint32_t APBUART::DATA_MASK = 0x000000FF
static

Referenced by init_registers().

sc_event APBUART::e_irq

Referenced by data_read(), send_irq(), and uart_ticks().

const uint32_t APBUART::fifosize = 32
static
sr_param<std::string> APBUART::g_backend
sr_param<bool> APBUART::g_console

Referenced by init_generics().

uint32_t APBUART::g_pirq

Referenced by send_irq(), and update_level_int().

signal<std::pair<uint32_t, bool> >::out APBUART::irq

Referenced by sc_main(), send_irq(), and update_level_int().

bool APBUART::level_int

Referenced by APBUART(), send_irq(), and update_level_int().

io_if* APBUART::m_backend
bool APBUART::overrun

Referenced by APBUART(), data_write(), and status_read().

const uint32_t APBUART::powermon
char APBUART::recv_buffer[32]

Referenced by data_read(), and uart_ticks().

uint32_t APBUART::recv_buffer_end

Referenced by APBUART(), data_read(), and uart_ticks().

uint32_t APBUART::recv_buffer_level
uint32_t APBUART::recv_buffer_start

Referenced by APBUART().

sc_event APBUART::s_irq
const uint32_t APBUART::SCALER = 0x0000000C
static

Referenced by init_registers(), and uart_ticks().

const uint32_t APBUART::SCALER_DEFAULT = 0x0
static

Referenced by init_registers().

const uint32_t APBUART::SCALER_MASK = 0x00000FFF
static

Referenced by init_registers().

uint32_t APBUART::send_buffer
const uint32_t APBUART::STATUS = 0x00000004
static

Referenced by init_registers(), and status_read().

const uint32_t APBUART::STATUS_DEFAULT = 0x00000086
static

Referenced by init_registers().

const uint32_t APBUART::STATUS_MASK = 0x00000000
static

Referenced by init_registers().


The documentation for this class was generated from the following files: