ConOpSys V2970  P004.07
ANVILEX control operating system
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes | Static Private Attributes | List of all members
TFPGA_Base Class Referenceabstract

FPGA base class. More...

#include <FPGA_Base.h>

Inheritance diagram for TFPGA_Base:
Inheritance graph
Collaboration diagram for TFPGA_Base:
Collaboration graph

Classes

struct  TFPGA_Module_Descriptor
 Pointer to the application task. More...
 
union  TFPGA_Registers
 FPGA register models. More...
 
struct  TUnit_Registers
 Register structure for generic unit ID access. More...
 

Public Member Functions

 TFPGA_Base ()
 FPGA base class constructor method. More...
 
virtual ~TFPGA_Base ()
 FPGA base class destructor method. More...
 
VOID Interrupt ()
 FPGA interrupt method. More...
 
VOID Init (TFPGA_Registers *struct_Registers_Base_Address)
 FPGA object initialisation method. More...
 
BOOL Get_Internal_Slot_Module_ID (U8 u8_Slot_Index, U32 *u32_Module_ID)
 
BOOL Get_External_Slot_Module_ID (U8 u8_Slot_Index, U32 *u32_Module_ID)
 
VOID Increment_Test_Interconnect_Error_Counter ()
 Increment test interconnect error counter method. More...
 
VOID Test_Interconnect_Interface ()
 Check FPGA interconnection interface method. More...
 
U32 Get_Configurstion_ID ()
 Get FPGA configuration ID method. More...
 
U16 Get_Version ()
 Get FPGA configuration version method. More...
 
U16 Get_Revision ()
 Get FPGA configuration revision method. More...
 
U32 Get_Clock_Frequency ()
 Get FPGA clock frequency in herz method. More...
 
U16 Get_Slot_Size ()
 Get FPGA slot size method. More...
 
F32 Get_Clock_Frequency_In_Hz ()
 Get FPGA internal clock frequency in Hz method. More...
 
U64 Get_Interconnect_Error_Count ()
 Get FPGA interconnect error count method. More...
 
U64 Get_Interconnect_Test_Count ()
 Get FPGA interconnect test count method. More...
 
virtual BOOL Is_Installed ()
 Get FPGA init status method. More...
 
TRIL Is_Configured ()
 Return FPGA configuration status method. More...
 
virtual BOOL Configure ()=0
 Configure FPGA method. More...
 
virtual BOOL FPGA_PROG_Pin_Status ()=0
 Get FPGA PROG pin status method. More...
 
virtual BOOL FPGA_DONE_Pin_Status ()=0
 Get FPGA DONE pin status method. More...
 
VOID Send_General_Information (TProtocol_Base *object_Protocol)
 Send general information about FPGA object. More...
 
VOID Send_Internal_Slot_Information (TProtocol_Base *object_Protocol)
 Send information about internal slots allocation. More...
 
VOID Send_External_Slot_Information (TProtocol_Base *object_Protocol)
 Send information about external slots allocation. More...
 
VOID Reset_Watchdog ()
 Reset FPGA watchdog. More...
 
BOOL Get_Slot_Module_Name_By_ID (U32 u32_Module_ID, C8 **c8_Module_Name)
 
VOID Send_Internal_Module_Information (U8 u8_Slot, TProtocol_Base *object_Protocol)
 
VOID Send_External_Module_Information (U8 u8_Slot, TProtocol_Base *object_Protocol)
 

Protected Member Functions

VOID FPGA_Write_U16 (U16 u16_Address, U16 u16_Value)
 Write U16 value into FPGA using generic access. More...
 
VOID FPGA_Read_U16 (U16 u16_Address, U16 *u16_Value)
 Read U16 value from FPGA using generic access. More...
 
virtual VOID Interrupt_Enable (U32 u32_TickPriority)=0
 Enable FPGA interrupt method. More...
 
virtual VOID Interrupt_Disable ()=0
 Disable FPGA interrupt method. More...
 

Protected Attributes

volatile TFPGA_Registersstruct_Registers = (TFPGA_Registers*)NULL
 Mapped FPGA registers. More...
 
TRIL tril_FPGA_Configured = (TRIL)unset
 FPGA configuration status. More...
 
U64 u64_Test_Interconnect_Test_Counter = (U64)0
 Interconnect test counter. More...
 
U64 u64_Test_Interconnect_Error_Counter = (U64)0
 Interconnect error counter for diagnose. More...
 
U16 u16_Write_Pattern_1
 Write pattern #1 for testng. More...
 
U16 u16_Write_Pattern_2
 Write pattern #2 for testng. More...
 
U16 u16_Write_Pattern_3
 Write pattern #3 for testng. More...
 
U16 u16_Write_Pattern_4
 Write pattern #4 for testng. More...
 
U16 u16_Read_Pattern_1
 Reading pattern #1 for testng. More...
 
U16 u16_Read_Pattern_2
 Reading pattern #2 for testng. More...
 
U16 u16_Read_Pattern_3
 Reading pattern #3 for testng. More...
 
U16 u16_Read_Pattern_4
 Reading pattern #4 for testng. More...
 

Private Attributes

U32 u32_Clock_Frequency = (U32)50000000
 FPGA internal clock frequency in herz as integer value. More...
 
F32 f32_Clock_Frequency = (F32)50000000.0f
 FPGA internal clock frequency in herz as float point value. More...
 

Static Private Attributes

static const TFPGA_Module_Descriptor struct_FPGA_Module_Descriptor_Database []
 FPAG module descriptior database storage. More...
 

Detailed Description

FPGA base class.

Constructor & Destructor Documentation

◆ TFPGA_Base()

TFPGA_Base::TFPGA_Base ( )

FPGA base class constructor method.


Note
None
Override
Not allowed
Attention
Don't call this method directly.

◆ ~TFPGA_Base()

TFPGA_Base::~TFPGA_Base ( )
virtual

FPGA base class destructor method.


Note
None
Override
Not allowed
Attention
Don't call this method directly.

Member Function Documentation

◆ Configure()

virtual BOOL TFPGA_Base::Configure ( )
pure virtual

Configure FPGA method.


Note
None
Returns
BOOL - Return FPGA present status
Return values
false- FPGA does not present
true- FPGA present
Override
Requered
Attention
None

Implemented in TFPGA_STM32F429, TFPGA_P017_39_KG3_CB, TFPGA_P015_09_CB, and TFPGA.

◆ FPGA_DONE_Pin_Status()

virtual BOOL TFPGA_Base::FPGA_DONE_Pin_Status ( )
pure virtual

Get FPGA DONE pin status method.


Note
None
Returns
BOOL - Return FPGA DONE pin status
Return values
false- FPGA DONE pin is low
true- FPGA DONE pin is high
Override
Requered
Attention
None

Implemented in TFPGA_STM32F429, TFPGA_P017_39_KG3_CB, and TFPGA_P015_09_CB.

Referenced by Send_General_Information().

Here is the caller graph for this function:

◆ FPGA_PROG_Pin_Status()

virtual BOOL TFPGA_Base::FPGA_PROG_Pin_Status ( )
pure virtual

Get FPGA PROG pin status method.


Note
None
Returns
BOOL - Return FPGA PROG pin status
Return values
false- FPGA PROG pin is low
true- FPGA PROG pin is high
Override
Requered
Attention
None

Implemented in TFPGA_STM32F429, TFPGA_P017_39_KG3_CB, and TFPGA_P015_09_CB.

Referenced by Send_General_Information().

Here is the caller graph for this function:

◆ FPGA_Read_U16()

VOID TFPGA_Base::FPGA_Read_U16 ( U16  u16_Address,
U16 u16_Value 
)
protected

Read U16 value from FPGA using generic access.


Note
None
Parameters
[in]u16_Address- Logical address for read operation
[out]*u16_Value- Readed U16 value from FPGA
Returns
None
Override
Requered
Attention
None

References struct_Registers, and TFPGA_Base::TFPGA_Registers::u16_Data.

◆ FPGA_Write_U16()

VOID TFPGA_Base::FPGA_Write_U16 ( U16  u16_Address,
U16  u16_Value 
)
protected

Write U16 value into FPGA using generic access.


Note
None
Parameters
[in]u16_Address- Logical address for read operation
[in]u16_Value- U16 value for write into FPGA
Returns
None
Override
Requered
Attention
None

References struct_Registers, and TFPGA_Base::TFPGA_Registers::u16_Data.

◆ Get_Clock_Frequency()

U32 TFPGA_Base::Get_Clock_Frequency ( )

Get FPGA clock frequency in herz method.


Note
None
Returns
U16 - Return FPGA clock frequency in herz
Override
Not allowed
Attention
None

References TFPGA_Base::TFPGA_Registers::struct_Data, struct_Registers, TFPGA_Base::TFPGA_Registers::u16_FPGA_Clock_Frequency_High, and TFPGA_Base::TFPGA_Registers::u16_FPGA_Clock_Frequency_Low.

◆ Get_Clock_Frequency_In_Hz()

F32 TFPGA_Base::Get_Clock_Frequency_In_Hz ( )

Get FPGA internal clock frequency in Hz method.


Note
None
Returns
F32 - Return Clock frequency
Override
Not allowed
Attention
None

References f32_Clock_Frequency.

◆ Get_Configurstion_ID()

U32 TFPGA_Base::Get_Configurstion_ID ( )

Get FPGA configuration ID method.


Note
None
Returns
U32 - Return configurstion ID
Override
Not allowed
Attention
None

References TFPGA_Base::TFPGA_Registers::struct_Data, struct_Registers, TFPGA_Base::TFPGA_Registers::u16_FPGA_Configuration_ID_High, and TFPGA_Base::TFPGA_Registers::u16_FPGA_Configuration_ID_Low.

◆ Get_External_Slot_Module_ID()

BOOL TFPGA_Base::Get_External_Slot_Module_ID ( U8  u8_Slot_Index,
U32 u32_Module_ID 
)

References Compose_U32(), and struct_Registers.

Referenced by Send_External_Module_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Get_Interconnect_Error_Count()

U64 TFPGA_Base::Get_Interconnect_Error_Count ( )

Get FPGA interconnect error count method.


Note
None
Returns
U64 - FPGA interconnect error count
Override
Not allowed
Attention
None

References u64_Test_Interconnect_Error_Counter.

◆ Get_Interconnect_Test_Count()

U64 TFPGA_Base::Get_Interconnect_Test_Count ( )

Get FPGA interconnect test count method.


Note
None
Returns
U64 - FPGA interconnect test count
Override
Not allowed
Attention
None

References u64_Test_Interconnect_Test_Counter.

◆ Get_Internal_Slot_Module_ID()

BOOL TFPGA_Base::Get_Internal_Slot_Module_ID ( U8  u8_Slot_Index,
U32 u32_Module_ID 
)

References Compose_U32(), and struct_Registers.

Referenced by Send_Internal_Module_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Get_Revision()

U16 TFPGA_Base::Get_Revision ( )

Get FPGA configuration revision method.


Note
None
Returns
U16 - Return FPGA revision
Override
Not allowed
Attention
None

References TFPGA_Base::TFPGA_Registers::struct_Data, struct_Registers, and TFPGA_Base::TFPGA_Registers::u16_FPGA_Revision.

◆ Get_Slot_Module_Name_By_ID()

BOOL TFPGA_Base::Get_Slot_Module_Name_By_ID ( U32  u32_Module_ID,
C8 **  c8_Module_Name 
)

◆ Get_Slot_Size()

U16 TFPGA_Base::Get_Slot_Size ( )

Get FPGA slot size method.


Note
None
Returns
U16 - Return FPGA slot size
Override
Not allowed
Attention
None

References TFPGA_Base::TFPGA_Registers::struct_Data, struct_Registers, and TFPGA_Base::TFPGA_Registers::u16_FPGA_Slot_Size.

◆ Get_Version()

U16 TFPGA_Base::Get_Version ( )

Get FPGA configuration version method.


Note
None
Returns
U16 - Return FPGA version
Override
Not allowed
Attention
None

References TFPGA_Base::TFPGA_Registers::struct_Data, struct_Registers, and TFPGA_Base::TFPGA_Registers::u16_FPGA_Version.

◆ Increment_Test_Interconnect_Error_Counter()

VOID TFPGA_Base::Increment_Test_Interconnect_Error_Counter ( )

Increment test interconnect error counter method.


Note
None
Returns
None
Override
Not allowed
Attention
None

References u64_Test_Interconnect_Error_Counter.

Referenced by Test_Interconnect_Interface().

Here is the caller graph for this function:

◆ Init()

VOID TFPGA_Base::Init ( TFPGA_Registers struct_Registers_Base_Address)

FPGA object initialisation method.


Note
None
Parameters
[in]*struct_Registers_Base_Address- Pointer to registers base address
Returns
None
Override
Requered
Attention
None

References struct_Registers.

Referenced by TFPGA::Init().

Here is the caller graph for this function:

◆ Interrupt()

VOID TFPGA_Base::Interrupt ( )

FPGA interrupt method.


Note
None
Returns
None
Override
Requered
Attention
None

References object_Application.

Referenced by TFPGA_P015_09_CB::Interrupt(), TFPGA_P017_39_KG3_CB::Interrupt(), and TFPGA_STM32F429::Interrupt().

Here is the caller graph for this function:

◆ Interrupt_Disable()

virtual VOID TFPGA_Base::Interrupt_Disable ( )
protectedpure virtual

Disable FPGA interrupt method.


Note
None
Parameters
[in]u32_TickPriority- Priority
Returns
None
Override
Requered
Attention
None

Implemented in TFPGA_STM32F429, TFPGA_P017_39_KG3_CB, TFPGA_P015_09_CB, and TFPGA.

◆ Interrupt_Enable()

virtual VOID TFPGA_Base::Interrupt_Enable ( U32  u32_TickPriority)
protectedpure virtual

Enable FPGA interrupt method.


Note
None
Parameters
[in]u32_TickPriority- Priority
Returns
None
Override
Requered
Attention
None

Implemented in TFPGA_STM32F429, TFPGA_P017_39_KG3_CB, TFPGA_P015_09_CB, and TFPGA.

◆ Is_Configured()

TRIL TFPGA_Base::Is_Configured ( )

Return FPGA configuration status method.


Note
None
Returns
TRIL - Return FPGA init status
Return values
false- FPFA not configured
true- FPGA successful configured
unset- FPGA did not start configured
Override
Not allowed
Attention
None

References tril_FPGA_Configured.

Referenced by Send_General_Information().

Here is the caller graph for this function:

◆ Is_Installed()

BOOL TFPGA_Base::Is_Installed ( )
virtual

Get FPGA init status method.


Note
None
Returns
BOOL - Return FPGA init status
Return values
false- FPGA not installed
true- FPGA installed
Override
Requered
Attention
None

Referenced by Send_General_Information().

Here is the caller graph for this function:

◆ Reset_Watchdog()

VOID TFPGA_Base::Reset_Watchdog ( )

Reset FPGA watchdog.


Note
None
Returns
None
Override
Requered
Attention
None

References TFPGA_Base::TFPGA_Registers::struct_Data, struct_Registers, and TFPGA_Base::TFPGA_Registers::u16_Watchdog_CSR.

◆ Send_External_Module_Information()

VOID TFPGA_Base::Send_External_Module_Information ( U8  u8_Slot,
TProtocol_Base object_Protocol 
)

References Get_External_Slot_Module_ID(), Get_Slot_Module_Name_By_ID(), TProtocol_Base::Transmit_String(), and TProtocol_Base::Transmit_U32_Value_As_Hex().

Referenced by Send_External_Slot_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Send_External_Slot_Information()

VOID TFPGA_Base::Send_External_Slot_Information ( TProtocol_Base object_Protocol)

Send information about external slots allocation.


Note
None
Parameters
[in]*object_ProtocolPointer to the communication protocol object
Returns
None
Override
Optional
Attention
None

References Send_External_Module_Information(), TProtocol_Base::Transmit_String(), and TProtocol_Base::Transmit_U32_Value_As_Hex().

Referenced by TFPGA_P015_09_CB::Send_Boot_Information(), and TFPGA_P017_39_KG3_CB::Send_Boot_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Send_General_Information()

VOID TFPGA_Base::Send_General_Information ( TProtocol_Base object_Protocol)

Send general information about FPGA object.


Note
None
Parameters
[in]*object_ProtocolPointer to the communication protocol object
Returns
None
Override
Optional
Attention
None

References FPGA_BASE, FPGA_DONE_Pin_Status(), FPGA_PROG_Pin_Status(), Is_Configured(), Is_Installed(), TProtocol_Base::Transmit_BOOL_Value_As_Decimal(), TProtocol_Base::Transmit_String(), TProtocol_Base::Transmit_TRIL_Value_As_Decimal(), TProtocol_Base::Transmit_U16_Value_As_Hex(), TProtocol_Base::Transmit_U32_Value_As_Decimal(), and TProtocol_Base::Transmit_U32_Value_As_Hex().

Referenced by TFPGA_P015_09_CB::Send_Boot_Information(), and TFPGA_P017_39_KG3_CB::Send_Boot_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Send_Internal_Module_Information()

VOID TFPGA_Base::Send_Internal_Module_Information ( U8  u8_Slot,
TProtocol_Base object_Protocol 
)

References Get_Internal_Slot_Module_ID(), Get_Slot_Module_Name_By_ID(), TProtocol_Base::Transmit_String(), and TProtocol_Base::Transmit_U32_Value_As_Hex().

Referenced by Send_Internal_Slot_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Send_Internal_Slot_Information()

VOID TFPGA_Base::Send_Internal_Slot_Information ( TProtocol_Base object_Protocol)

Send information about internal slots allocation.


Note
None
Parameters
[in]*object_ProtocolPointer to the communication protocol object
Returns
None
Override
Optional
Attention
None

References Send_Internal_Module_Information(), TProtocol_Base::Transmit_String(), and TProtocol_Base::Transmit_U32_Value_As_Hex().

Referenced by TFPGA_P015_09_CB::Send_Boot_Information(), and TFPGA_P017_39_KG3_CB::Send_Boot_Information().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Test_Interconnect_Interface()

VOID TFPGA_Base::Test_Interconnect_Interface ( )

Member Data Documentation

◆ f32_Clock_Frequency

F32 TFPGA_Base::f32_Clock_Frequency = (F32)50000000.0f
private

FPGA internal clock frequency in herz as float point value.

Referenced by Get_Clock_Frequency_In_Hz().

◆ struct_FPGA_Module_Descriptor_Database

const TFPGA_Base::TFPGA_Module_Descriptor TFPGA_Base::struct_FPGA_Module_Descriptor_Database
staticprivate

FPAG module descriptior database storage.

Referenced by Get_Slot_Module_Name_By_ID().

◆ struct_Registers

volatile TFPGA_Registers* TFPGA_Base::struct_Registers = (TFPGA_Registers*)NULL
protected

◆ tril_FPGA_Configured

TRIL TFPGA_Base::tril_FPGA_Configured = (TRIL)unset
protected

◆ u16_Read_Pattern_1

U16 TFPGA_Base::u16_Read_Pattern_1
protected

Reading pattern #1 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Read_Pattern_2

U16 TFPGA_Base::u16_Read_Pattern_2
protected

Reading pattern #2 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Read_Pattern_3

U16 TFPGA_Base::u16_Read_Pattern_3
protected

Reading pattern #3 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Read_Pattern_4

U16 TFPGA_Base::u16_Read_Pattern_4
protected

Reading pattern #4 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Write_Pattern_1

U16 TFPGA_Base::u16_Write_Pattern_1
protected

Write pattern #1 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Write_Pattern_2

U16 TFPGA_Base::u16_Write_Pattern_2
protected

Write pattern #2 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Write_Pattern_3

U16 TFPGA_Base::u16_Write_Pattern_3
protected

Write pattern #3 for testng.

Referenced by Test_Interconnect_Interface().

◆ u16_Write_Pattern_4

U16 TFPGA_Base::u16_Write_Pattern_4
protected

Write pattern #4 for testng.

Referenced by Test_Interconnect_Interface().

◆ u32_Clock_Frequency

U32 TFPGA_Base::u32_Clock_Frequency = (U32)50000000
private

FPGA internal clock frequency in herz as integer value.

◆ u64_Test_Interconnect_Error_Counter

U64 TFPGA_Base::u64_Test_Interconnect_Error_Counter = (U64)0
protected

Interconnect error counter for diagnose.

Referenced by Get_Interconnect_Error_Count(), and Increment_Test_Interconnect_Error_Counter().

◆ u64_Test_Interconnect_Test_Counter

U64 TFPGA_Base::u64_Test_Interconnect_Test_Counter = (U64)0
protected

Interconnect test counter.

Referenced by Get_Interconnect_Test_Count(), and Test_Interconnect_Interface().


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