pflib v3.9.0-rc3-11-g2537d8f
Pretty Fine HGCROC Interaction Library
Loading...
Searching...
No Matches
pflib::bittware::AxiLite Class Reference

This class provides access to read and write via the ioctl path to the AXILite targets within the Bittware firwmare. More...

#include <bittware_axilite.h>

Public Member Functions

 AxiLite (const uint32_t base_address, const char *dev, const uint32_t mask_space=0x3FFFFF)
 
const char * dev () const
 get the device path this AxiLite is connected to
 
uint32_t read (uint32_t addr)
 Read a register, throws an exception if bits are set outside the addr mask space (or in the two LSB)
 
void write (uint32_t addr, uint32_t value)
 Write a register, throws an exception if bits are set outside the addr mask space (or in the two LSB)
 
uint32_t readMasked (uint32_t addr, uint32_t mask)
 Read a register, doing shifts as necessary, throws an exception if bits are set outside the addr mask space (or in the two LSB)
 
void writeMasked (uint32_t addr, uint32_t mask, uint32_t value)
 Write a register, doing shifts as necessary, throws an exception if bits are set outside the addr mask space (or in the two LSB)
 
bool isSet (uint32_t addr, int ibit)
 check to see if a given bit is set
 
void setclear (uint32_t addr, int ibit, bool true_for_set=false)
 set or clear a given bit
 
uint32_t get_hardware_type ()
 get the hardware type from the standard register 0
 
uint32_t get_firmware_version ()
 get the firmware version from the standard register 0
 

Private Attributes

const char * dev_
 
uint32_t base_
 path to device
 
uint32_t mask_
 
uint32_t antimask_
 
int handle_
 
bool waswrite_
 

Detailed Description

This class provides access to read and write via the ioctl path to the AXILite targets within the Bittware firwmare.

All addresses are full bus addresses relative to the base_address, including the two LSB which should always be zero.


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