Deeploy.Targets.PULPOpen.DataTypes.pi_cl_ram_req_t

class Deeploy.Targets.PULPOpen.DataTypes.pi_cl_ram_req_t(structDict: str | Struct | Dict[str, BaseType], ctxt: _NetworkContext | None = None)

Bases: Struct

Methods

__init__(structDict: str | Struct | Dict[str, BaseType], ctxt: _NetworkContext | None = None)

Initialize a new struct object

Parameters:
  • structDict (Union[str, Struct, Dict[str, BaseType]]) – Either an initialized Deeploy-type struct, a string name refering to an intialized struct registered in the NetworkContext, or a full definition of the struct to-be-initialized

  • ctxt (Optional[_NetworkContext]) – Current NetworkContext

Raises:

Exception – Raises an Exception if structDict cannot be assigned to a struct of layout structTypeDict

__init__(structDict[, ctxt])

Initialize a new struct object

checkPromotion(_other[, ctxt])

Checks whether a given Python-typed or Deeploy-typed value can be represented with the Deeploy type

checkValue(value[, ctxt])

Checks whether a given Python-type value (usually FP64) can be represented with a Deeploy type

Attributes

value

the value of the struct; corresponds to an element with type layout defined in cls.structTypeDict

structTypeDict

The definition of the struct mapping its field names to their associated Deeploy-types

typeName

The C typename of this type

typeWidth

the number of BITS to be assigned to the type

typeName: str = 'pi_cl_ram_req_t'

The C typename of this type

Type:

str

structTypeDict: Dict[str, Type[BaseType]] = {'addr': <class 'Deeploy.AbstractDataTypes.voidPtr'>, 'ext2loc': <class 'Deeploy.CommonExtensions.DataTypes.uint8_t'>, 'is_2d': <class 'Deeploy.CommonExtensions.DataTypes.uint8_t'>, 'length': <class 'Deeploy.CommonExtensions.DataTypes.uint32_t'>, 'pi_ram_addr': <class 'Deeploy.AbstractDataTypes.voidPtr'>, 'size': <class 'Deeploy.CommonExtensions.DataTypes.uint32_t'>, 'stride': <class 'Deeploy.CommonExtensions.DataTypes.uint32_t'>}

The definition of the struct mapping its field names to their associated Deeploy-types

Type:

Dict[str, Type[BaseType]]

value

the value of the struct; corresponds to an element with type layout defined in cls.structTypeDict

Type:

structTypeDict

classmethod checkPromotion(_other: str | Dict[str, BaseType] | Struct, ctxt: _NetworkContext | None = None)

Checks whether a given Python-typed or Deeploy-typed value can be represented with the Deeploy type

Parameters:
  • value (Union[_PythonType, _DeeployType]) – Python-typed or Deeploy-typed value to be checked for promotion to cls

  • ctxt (Optional[_NetworkContext]) – Current NetworkContext

Returns:

Returns true if the value can be promoted to cls

Return type:

bool

classmethod checkValue(value: str | Dict[str, BaseType], ctxt: _NetworkContext | None = None)

Checks whether a given Python-type value (usually FP64) can be represented with a Deeploy type

Parameters:
  • value (_PythonType) – Python-typed value to check

  • ctxt (Optional[_NetworkContext]) – Current NetworkContext

Returns:

Returns true if value can represented by cls

Return type:

bool

typeWidth: int = 176

the number of BITS to be assigned to the type

Type:

int