CYNQ  0.3.0
Framework to develop FPGA applications in C++ with the easiness of PYNQ
cynq::Status Struct Reference

Structure to define the return characteristics of each function. More...

#include <status.hpp>

Collaboration diagram for cynq::Status:

Public Types

enum  {
  OK = 0 , FILE_ERROR , INVALID_PARAMETER , INCOMPATIBLE_PARAMETER ,
  CONFIGURATION_ERROR , REGISTER_IO_ERROR , NOT_IMPLEMENTED , MEMBER_ABSENT ,
  RESOURCE_BUSY , EXECUTION_FAILED , REGISTER_NOT_ALIGNED
}
 

Public Member Functions

 Status () noexcept
 Construct a new Status object. More...
 
 Status (const int code, const std::string &msg) noexcept
 Construct a new Status object. More...
 
 Status (const int code, const int retval, const std::string &msg) noexcept
 Construct a new Status object. More...
 

Data Fields

int code
 
int retval
 
std::string msg
 

Detailed Description

Structure to define the return characteristics of each function.

It includes a code and a description that works to track errors

Examples
structures/execution-stream.cpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Error codes

Enumerator
FILE_ERROR 

OK Status

INVALID_PARAMETER 

File error that can be read or write

INCOMPATIBLE_PARAMETER 

Invalid argument or parameter. i.e. nullptr Incompatible parameter that it is not supported by a function

REGISTER_IO_ERROR 

Configuration error

NOT_IMPLEMENTED 

Register MMIO error

MEMBER_ABSENT 

Not implemented error

RESOURCE_BUSY 

Missing member

EXECUTION_FAILED 

Busy

REGISTER_NOT_ALIGNED 

Cannot execute the IP

Constructor & Destructor Documentation

◆ Status() [1/3]

cynq::Status::Status ( )
inlinenoexcept

Construct a new Status object.

Description of the error

It default the error to be 0 or OK

◆ Status() [2/3]

cynq::Status::Status ( const int  code,
const std::string &  msg 
)
inlinenoexcept

Construct a new Status object.

It defines the constructor to define a custom code and description

Parameters
codecode of the error
msgdescription

◆ Status() [3/3]

cynq::Status::Status ( const int  code,
const int  retval,
const std::string &  msg 
)
inlinenoexcept

Construct a new Status object.

It defines the constructor to define a custom code and description

Parameters
codecode of the error
retvalreturn value in case of integer
msgdescription

Field Documentation

◆ msg

std::string cynq::Status::msg

Auxiliar data coming from user

◆ retval

int cynq::Status::retval

Code of the error


The documentation for this struct was generated from the following file: