![]() |
ParaLib 2.0.28-master SHA: b4a0dafd73
|
Parameter-Interface for connection with a PC. More...
Go to the source code of this file.
Data Structures | |
| struct | ParameterRequest |
| Request information passed to the callbacks OnRead, OnWrite and SetToDefault of a parameter and to IsValidForRead, IsValidForWrite and IsValidForSetToDefault. More... | |
| struct | Group |
| Parameter-group. More... | |
| struct | Parameter_InfoHeader |
| Information structure to identify one parameter in some functions. More... | |
| struct | ParaData_I8 |
| Parameter-data structure for signed char (8-Bit) More... | |
| struct | ParaData_U8 |
| Parameter-data structure for unsigned char (8-Bit) More... | |
| struct | ParaData_I16 |
| Parameter-data structure for signed word (16-Bit) More... | |
| struct | ParaData_U16 |
| Parameter-data structure for unsigned word (16-Bit) More... | |
| struct | ParaData_I32 |
| Parameter-data structure for signed int (32-Bit) More... | |
| struct | ParaData_U32 |
| Parameter-data structure for unsigned int (32-Bit) More... | |
| struct | ParaData_I64 |
| Parameter-data structure for signed long (64-Bit) More... | |
| struct | ParaData_U64 |
| Parameter-data structure for unsigned long (64-Bit) More... | |
| struct | ParaData_F32 |
| Parameter-data structure for float (32-Bit) More... | |
| struct | ParaData_F64 |
| Parameter-data structure for double (64-Bit) More... | |
| struct | ParaData_STR |
| Parameter-data structure for string. More... | |
Macros | |
| #define | static_assert _Static_assert |
| #define | DEFINE_VAL(s) DEFINE_STR(s) |
| Macro to reference a defined value in helptexts. More... | |
| #define | PARA(s) PARA_STR(s) |
| Macro to reference a parameter in helptexts. More... | |
| #define | ERROR(s) ERROR_STR(s) |
| Macro to reference an error in helptexts. More... | |
| #define | ParameterF32(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 32 bit floating point parameter. More... | |
| #define | ParameterU32(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 32 bit unsigned integer parameter. More... | |
| #define | ParameterI32(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 32 bit signed integer parameter. More... | |
| #define | ParameterU16(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 16 bit unsigned integer parameter. More... | |
| #define | ParameterI16(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 16 bit signed integer parameter. More... | |
| #define | ParameterU8(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 8 bit unsigned integer parameter. More... | |
| #define | ParameterI8(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MIN, MAX, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an 8 bit signed integer parameter. More... | |
| #define | ParameterSTR(VARIABLE_NAME, PARA_ID, GROUP_ID, NAME, UNIT, DESCRIPTION, HELP_EN, HELP_DE, SUBSTITUTION, COUNT, MAX_LENGTH, DEFAULT, ON_READ, ON_WRITE, SET_TO_DEFAULT, ACCESS, STORE_LOCATION, FLAGS) |
| Defines an string parameter. More... | |
| #define | Parameter(PARA_ID) g_tParameter##PARA_ID |
| Use to declare an Parameter as external. More... | |
| #define | ParameterWriteF32(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 4, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a 32Bit float Parameter within the source code. More... | |
| #define | ParameterWriteU32(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 4, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a 32Bit unsigned Parameter within the source code. More... | |
| #define | ParameterWriteI32(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 4, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a 32Bit signed Parameter within the source code. More... | |
| #define | ParameterWriteU16(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 2, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a 16Bit unsigned Parameter within the source code. More... | |
| #define | ParameterWriteI16(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 2, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a 16Bit signed Parameter within the source code. More... | |
| #define | ParameterWriteU8(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 1, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a 8Bit unsigned Parameter within the source code. More... | |
| #define | ParameterWriteI8(PARA_ID, SUB_ID, DATA, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 1, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
| Use to write to a Bit signed Parameter within the source code. More... | |
| #define | ParameterSetToDefaultF32(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 32Bit floating point Parameter within the source code to the default value. More... | |
| #define | ParameterSetToDefaultU32(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 32Bit unsigned Parameter within the source code to the default value. More... | |
| #define | ParameterSetToDefaultI32(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 32Bit signed Parameter within the source code to the default value. More... | |
| #define | ParameterSetToDefaultU16(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 16Bit unsigned Parameter within the source code to the default value. More... | |
| #define | ParameterSetToDefaultI16(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 16Bit signed Parameter within the source code to the default value. More... | |
| #define | ParameterSetToDefaultU8(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 8Bit unsigned Parameter within the source code to the default value. More... | |
| #define | ParameterSetToDefaultI8(PARA_ID, SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
| Use to set a 8Bit signed Parameter within the source code to the default value. More... | |
| #define | GetStorageLocation(Parameter) (((Parameter)->Flags >> 24) & 0x0F) |
| Get Storage Location from Parameter This macro is used to extract the storage location out of a parameter structure. More... | |
| #define | GetDataType(Parameter) ((Parameter)->Flags >> 28) |
| Get Datatype from Parameter This macro is used to extract the datatype out of a parameter structure. More... | |
| #define | PARA_REQUEST(SUB_ID, DATA, MAX_COUNT, OFFSET, ACCESS_SOURCE, ACCESS_LEVEL) (&(ParameterRequest){ (SUB_ID), (void*)(DATA), (MAX_COUNT), (OFFSET), (ACCESS_SOURCE), (ACCESS_LEVEL) }) |
| Creates a temporary ParameterRequest and returns its address, for calling a callback with single values: More... | |
| #define | PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL) PARA_REQUEST(SUB_ID, 0, 0, 0, ACCESS_SOURCE, ACCESS_LEVEL) |
| Like PARA_REQUEST for SetToDefault, which does not use a data buffer. More... | |
| #define | PARA_HAS_READ_ACCESS(P, LEVEL) (((LEVEL) == 0) || (((P)->Access & (1u << (((LEVEL) - 1u) * 2u))) != 0)) |
| Checks the read right of a parameter for an access level (see ACCESS_LEVEL). More... | |
| #define | PARA_HAS_WRITE_ACCESS(P, LEVEL) (((LEVEL) == 0) || (((P)->Access & (1u << (((LEVEL) * 2u) - 1u))) != 0)) |
| Checks the write right of a parameter for an access level (see ACCESS_LEVEL). More... | |
Enumerations | |
| enum | ParameterAccessSource { PARA_ACCESS_FROM_CODE , PARA_ACCESS_FROM_GUEST , PARA_ACCESS_FROM_USB , PARA_ACCESS_FROM_ETHERNET , PARA_ACCESS_FROM_HESP , PARA_ACCESS_FROM_CAN } |
| List of sources for parameter-access. Every parameter can limit access to these sources. (see Access restrictions). More... | |
| enum | ACCESS_LEVEL { ACCESS_NONE = 0x00 , ACCESS_VIEWER = 0x01 , ACCESS_USER = 0x02 , ACCESS_PROFESSIONAL = 0x03 , ACCESS_DEVELOPER = 0x04 , ACCESS_PLC = 0x05 , ACCESS_SPECIAL1 = 0x06 , ACCESS_SPECIAL2 = 0x07 , ACCESS_SPECIAL3 = 0x08 } |
| List of access-levels for parameters. Every parameter can limit read and write access according to these levels. (see Access restrictions). More... | |
| enum | ZUGRIFF { VIEWER_READ = 0x0001 , VIEWER_WRITE = 0x0002 , USER_READ = 0x0004 , USER_WRITE = 0x0008 , PROFESSIONAL_READ = 0x0010 , PROFESSIONAL_WRITE = 0x0020 , DEVELOPER_READ = 0x0040 , DEVELOPER_WRITE = 0x0080 , PLC_READ = 0x0100 , PLC_WRITE = 0x0200 , SPECIAL1_READ = 0x0400 , SPECIAL1_WRITE = 0x0800 , SPECIAL2_READ = 0x1000 , SPECIAL2_WRITE = 0x2000 , SPECIAL3_READ = 0x4000 , SPECIAL3_WRITE = 0x8000 } |
| List of access restrictions for parameters. Every parameter can limit read and write access according to these levels. (see Access restrictions). More... | |
| enum | STORE_LOCATION { NOT_STORED = 0 , PARA_FLASH = 1 , NVRAM = 2 , EEPROM = 3 , EXT_FLASH = 4 , SD_BASE = 5 , FACTORY_FLASH = 6 , SD = 7 , FACTORY_EEPROM = 8 } |
| List of storage locations for parameters. More... | |
| enum | GET_VALUES { GET_MIN = 1 , GET_MAX = 2 , GET_DEFAULT = 3 } |
| List of values, that can be retrived with the GetParaDataAsObject function. More... | |
| enum | FLAGS { FLAG_NONE = 0x00000000 , FLAG_SYSTEM = 0x00000001 , FLAG_HIDDEN = 0x00000002 , FLAG_SCOPEABLE = 0x00000004 , FLAG_VOLATILE = 0x00000008 , FLAG_NO_FILE_OVERWRITE = 0x00000010 , FLAG_SPECIAL_WRITE_ENABLE = 0x00000020 , FLAG_WRITE_APPROVE_REQUEST = FLAG_SPECIAL_WRITE_ENABLE } |
| List of Flags, which can be set for every single parameter First 8 Bits cannot be used, they are occupied by Storage Location and Datatype. More... | |
Functions | |
| uint32_t | GetParameterCount (void) |
| Get the number of the existent parameters. More... | |
| uint32_t | GetGroupCount (void) |
| Get the number of the existent parameter-groups. More... | |
| Parameter * | GetParameter (uint32_t ParaID) |
| Get the parameter of the given ID. More... | |
| Group * | GetGroup (uint32_t GroupID) |
| Get the parameter-Group of the given ID. More... | |
| int32_t | GetDataTypeSize (uint8_t Type) |
| Calculate the Size of a parameter-type. More... | |
| uint32_t | GetStringParameterLength (Parameter *p, uint16_t subID) |
| Get the length of the string data of the given parameter. More... | |
| int32_t | StreamReadParameterData_Value (Parameter_InfoHeader *ptInfo, uint8_t *pui8Destination, int32_t i32MaxCount, uint32_t ui32Offset, ParameterAccessSource tAccessSource, uint8_t ui8AccessLevel) |
| Read Parameter-data into buffer (Variant 1) The Data of the selected parameter is read and stored into a given buffer address. More... | |
| int32_t | StreamReadParameterData_Value2 (Parameter *p, const ParameterRequest *ptRequest) |
| Read Parameter-data into buffer (Variant 2) The Data of the selected parameter is read and stored into a given buffer address. More... | |
| int32_t | StreamWriteParameterData_Value (Parameter_InfoHeader *ptInfo, uint8_t *pui8Source, uint32_t ui32Offset, ParameterAccessSource tAccessSource, uint8_t ui8AccessLevel) |
| Write Parameter-data from buffer (Variant 1) The Data of the given buffer is written to parameter. More... | |
| int32_t | StreamWriteParameterData_Value2 (Parameter *p, const ParameterRequest *ptRequest, uint16_t ui16Count) |
| Write Parameter-data from buffer (Variant 2) The Data of the given buffer is written to parameter. More... | |
| int32_t | StreamWriteStringParameter (Parameter *p, uint16_t ui16StartSubId, uint16_t ui16Count, uint8_t *pui8Destination, uint32_t *pui32MaxCount, ParameterAccessSource tAccessSource, uint8_t ui8AccessLevel) |
| Read String Parameter-data into buffer (Variant 1) The Data of the selected string-parameter is read and stored into a given buffer address. More... | |
| int32_t | StreamWriteStringParameter2 (Parameter *p, uint16_t ui16StartSubId, uint16_t ui16Count, uint8_t *pui8Destination, uint32_t *pui32MaxCount, ParameterAccessSource tAccessSource, uint8_t ui8AccessLevel, uint32_t *pui32StrPos) |
| Read String Parameter-data into buffer (Variant 2) The Data of the selected string-parameter is read and stored into a given buffer address. More... | |
| int32_t | PARA_ValAsString (Parameter *p, int32_t SubId, char *dest, int32_t MaxLength, uint8_t AccessLevel) |
| Output the parameter value as formatted string. More... | |
| int32_t | PARA_ObjectToString (Parameter *p, object *data, char *dest, int32_t MaxLength) |
| Parse Parameter-data out of an object. More... | |
| int32_t | PARA_ParseString (Parameter *p, int32_t SubId, char *input, uint8_t AccessLevel) |
| Parse Parameter-data out of an input string. More... | |
| bool | IsValidForRead (void *pvThis, const ParameterRequest *ptRequest) |
| Check if the actual access-right is sufficient to read the parameter. More... | |
| bool | IsValidForWrite (void *pvThis, const ParameterRequest *ptRequest) |
| Check if the actual access-right is sufficient to write the parameter. More... | |
| bool | IsValidForSetToDefault (void *pvThis, const ParameterRequest *ptRequest) |
| Check if the actual access-right is sufficient to set to default the parameter. More... | |
| void | GetParaDataAsObject (Parameter *p, uint32_t data, object *ob, uint8_t AccessLevel) |
| Get Parameter-data as object type. More... | |
| void | GetParaValueAsObject (Parameter *p, uint16_t SubId, object *ob, uint8_t AccessLevel) |
| Get Parameter-value as object type. More... | |
| float | ObjToFloat32 (object *ob) |
| Convertrs a given object to float. More... | |
Variables | |
| ReadFunction_I8 | ReadFunction_STD_I8 |
| ReadFunction_I16 | ReadFunction_STD_I16 |
| ReadFunction_I32 | ReadFunction_STD_I32 |
| ReadFunction_I64 | ReadFunction_STD_I64 |
| ReadFunction_U8 | ReadFunction_STD_U8 |
| ReadFunction_U8 | ReadFunction_STD_U8_BitWise |
| ReadFunction_U16 | ReadFunction_STD_U16 |
| ReadFunction_U32 | ReadFunction_STD_U32 |
| ReadFunction_U64 | ReadFunction_STD_U64 |
| ReadFunction_F32 | ReadFunction_STD_F32 |
| ReadFunction_STR | ReadFunction_STD_STR |
| WriteFunction_I8 | WriteFunction_STD_I8 |
| WriteFunction_I16 | WriteFunction_STD_I16 |
| WriteFunction_I32 | WriteFunction_STD_I32 |
| WriteFunction_I64 | WriteFunction_STD_I64 |
| WriteFunction_U8 | WriteFunction_STD_U8 |
| WriteFunction_U8 | WriteFunction_STD_U8_BitWise |
| WriteFunction_U16 | WriteFunction_STD_U16 |
| WriteFunction_U32 | WriteFunction_STD_U32 |
| WriteFunction_U64 | WriteFunction_STD_U64 |
| WriteFunction_F32 | WriteFunction_STD_F32 |
| WriteFunction_STR | WriteFunction_STD_STR |
| WriteFunction_Generic | WriteFunction_STD_Const |
| RestoreDefaultFunction_I8 | SetToDefaultFunction_STD_I8 |
| RestoreDefaultFunction_I16 | SetToDefaultFunction_STD_I16 |
| RestoreDefaultFunction_I32 | SetToDefaultFunction_STD_I32 |
| RestoreDefaultFunction_I64 | SetToDefaultFunction_STD_I64 |
| RestoreDefaultFunction_U8 | SetToDefaultFunction_STD_U8 |
| RestoreDefaultFunction_U8 | SetToDefaultFunction_STD_U8_BitWise |
| RestoreDefaultFunction_U16 | SetToDefaultFunction_STD_U16 |
| RestoreDefaultFunction_U32 | SetToDefaultFunction_STD_U32 |
| RestoreDefaultFunction_U64 | SetToDefaultFunction_STD_U64 |
| RestoreDefaultFunction_F32 | SetToDefaultFunction_STD_F32 |
| RestoreDefaultFunction_STR | SetToDefaultFunction_STD_STR |
| RestoreDefaultFunction_Generic | SetToDefaultFunction_STD_Const |
| ReadFunction_F32 | ReadFunction_STD_I32Q16 |
| WriteFunction_F32 | WriteFunction_STD_I32Q16 |
| RestoreDefaultFunction_F32 | SetToDefaultFunction_STD_I32Q16 |
| int32_t | ANZAHL_PARAMETER |
| Number of existent parameters. Must be defined in main program. More... | |
| const int32_t | ANZAHL_GRUPPEN |
| Number of existent parameter-groups. Must be defined in main program. More... | |
| Parameter * | ParaListe |
| List of all existent parameters in device. The list is filled by the linker automatically. More... | |
| const Group * | GruppenListe [] |
| List of all existent parameter-groups in device. The list is filled by the paraInit function. More... | |
| uint8_t | g_ui8ActualAccessLevel |
| Actual access-level (see Access restrictions). More... | |
| uint8_t * | g_pui8ActualAccessLevelPointer |
| Pointer to the Actual access-level (see Access restrictions). More... | |
| uint16_t | g_ui16FlashModified |
| Flag to show if the remanent storage is modified. More... | |
Parameter-Interface for connection with a PC.
Headerfile with all Prototypes.
© Copyright 2017-2022 Copyright: Retostronik GmbH Stütingstraße 30 58285 Gevelsberg
| #define DEFINE_VAL | ( | s | ) | DEFINE_STR(s) |
Macro to reference a defined value in helptexts.
| #define ERROR | ( | s | ) | ERROR_STR(s) |
Macro to reference an error in helptexts.
| #define PARA | ( | s | ) | PARA_STR(s) |
Macro to reference a parameter in helptexts.
| #define PARA_HAS_READ_ACCESS | ( | P, | |
| LEVEL | |||
| ) | (((LEVEL) == 0) || (((P)->Access & (1u << (((LEVEL) - 1u) * 2u))) != 0)) |
Checks the read right of a parameter for an access level (see ACCESS_LEVEL).
Access level 0 has no restriction. The read bit of level n is bit 2*(n-1) of Access (see ZUGRIFF).
| P | Pointer to the parameter (Parameter or any Parameter_<T>) |
| LEVEL | Actual access level |
| #define PARA_HAS_WRITE_ACCESS | ( | P, | |
| LEVEL | |||
| ) | (((LEVEL) == 0) || (((P)->Access & (1u << (((LEVEL) * 2u) - 1u))) != 0)) |
Checks the write right of a parameter for an access level (see ACCESS_LEVEL).
Access level 0 has no restriction. The write bit of level n is bit 2*n-1 of Access (see ZUGRIFF).
| P | Pointer to the parameter (Parameter or any Parameter_<T>) |
| LEVEL | Actual access level |
| #define PARA_REQUEST | ( | SUB_ID, | |
| DATA, | |||
| MAX_COUNT, | |||
| OFFSET, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | (&(ParameterRequest){ (SUB_ID), (void*)(DATA), (MAX_COUNT), (OFFSET), (ACCESS_SOURCE), (ACCESS_LEVEL) }) |
Creates a temporary ParameterRequest and returns its address, for calling a callback with single values:
| #define PARA_REQUEST_DEFAULT | ( | SUB_ID, | |
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | PARA_REQUEST(SUB_ID, 0, 0, 0, ACCESS_SOURCE, ACCESS_LEVEL) |
Like PARA_REQUEST for SetToDefault, which does not use a data buffer.
| #define Parameter | ( | PARA_ID | ) | g_tParameter##PARA_ID |
| #define ParameterF32 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 32 bit floating point parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterI16 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 16 bit signed integer parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterI32 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 32 bit signed integer parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterI8 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 8 bit signed integer parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterSetToDefaultF32 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 32Bit floating point Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSetToDefaultI16 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 16Bit signed Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSetToDefaultI32 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 32Bit signed Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSetToDefaultI8 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 8Bit signed Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSetToDefaultU16 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 16Bit unsigned Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSetToDefaultU32 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 32Bit unsigned Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSetToDefaultU8 | ( | PARA_ID, | |
| SUB_ID, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.SetToDefault((void*)&g_tParameter##PARA_ID, PARA_REQUEST_DEFAULT(SUB_ID, ACCESS_SOURCE, ACCESS_LEVEL)); |
Use to set a 8Bit unsigned Parameter within the source code to the default value.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be set to default |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterSTR | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MAX_LENGTH, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an string parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MAX_LENGTH | Maximum string length |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterU16 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 16 bit unsigned integer parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterU32 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 32 bit unsigned integer parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterU8 | ( | VARIABLE_NAME, | |
| PARA_ID, | |||
| GROUP_ID, | |||
| NAME, | |||
| UNIT, | |||
| DESCRIPTION, | |||
| HELP_EN, | |||
| HELP_DE, | |||
| SUBSTITUTION, | |||
| COUNT, | |||
| MIN, | |||
| MAX, | |||
| DEFAULT, | |||
| ON_READ, | |||
| ON_WRITE, | |||
| SET_TO_DEFAULT, | |||
| ACCESS, | |||
| STORE_LOCATION, | |||
| FLAGS | |||
| ) |
Defines an 8 bit unsigned integer parameter.
| VARIABLE_NAME | Pointer to Data value |
| PARA_ID | Unique identifier of the parameter |
| GROUP_ID | Identifier of a parameter group. See page Grouping of parameters |
| NAME | Name of the parameter. It is shown in the list of parameters |
| UNIT | Format of the parameter-value. See page Customized format of parameter values. |
| DESCRIPTION | Description. It is shown in the list of parameters |
| HELP_EN | English Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| HELP_DE | German Help-text of the parameter. It is shown in the bottom left corner of the parameter editor. See page Help-page for a parameter |
| SUBSTITUTION | Substitutional-texts to replace value with textx. See page Substitution of parameter values with texts. |
| COUNT | Number of entries in case of a data-field |
| MIN | Minimum value |
| MAX | Maximum value |
| DEFAULT | Factory default value |
| ON_READ | user-defined read-function, see page User defined onRead and onWrite functions. |
| ON_WRITE | user-defined write-function, see page User defined onRead and onWrite functions. |
| SET_TO_DEFAULT | user-defined restore-function, see page User defined onRead and onWrite functions. |
| ACCESS | Access restriction, or-concatenated elements of the enum ZUGRIFF. See page Access restrictions |
| STORE_LOCATION | location if the parameter value is stored to nv-ram, see page Storage of parameter-values in a non volatile memory. |
| FLAGS | special flag, see page Special flags for parameters. |
| #define ParameterWriteF32 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 4, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a 32Bit float Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterWriteI16 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 2, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a 16Bit signed Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterWriteI32 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 4, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a 32Bit signed Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterWriteI8 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 1, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a Bit signed Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterWriteU16 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 2, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a 16Bit unsigned Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterWriteU32 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 4, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a 32Bit unsigned Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define ParameterWriteU8 | ( | PARA_ID, | |
| SUB_ID, | |||
| DATA, | |||
| ACCESS_SOURCE, | |||
| ACCESS_LEVEL | |||
| ) | g_tParameter##PARA_ID.OnWrite((void*)&g_tParameter##PARA_ID, PARA_REQUEST(SUB_ID, DATA, 1, 0, ACCESS_SOURCE, ACCESS_LEVEL)) |
Use to write to a 8Bit unsigned Parameter within the source code.
| PARA_ID | Identifier of the defined parameter. |
| SUB_ID | SubId the sould be written |
| DATA | Pointer to the data source |
| ACCESS_SOURCE | One of a ParameterAccessSource |
| ACCESS_LEVEL | One of a ACCESS_LEVEL |
| #define static_assert _Static_assert |
| enum ACCESS_LEVEL |
List of access-levels for parameters. Every parameter can limit read and write access according to these levels. (see Access restrictions).
| Enumerator | |
|---|---|
| ACCESS_NONE | |
| ACCESS_VIEWER | |
| ACCESS_USER | |
| ACCESS_PROFESSIONAL | |
| ACCESS_DEVELOPER | |
| ACCESS_PLC | |
| ACCESS_SPECIAL1 | |
| ACCESS_SPECIAL2 | |
| ACCESS_SPECIAL3 | |
| enum FLAGS |
List of Flags, which can be set for every single parameter First 8 Bits cannot be used, they are occupied by Storage Location and Datatype.
| Enumerator | |
|---|---|
| FLAG_NONE | No special flags. |
| FLAG_SYSTEM | Parameter is added to Parametereditor and only necessary for parametereditor to work properly. |
| FLAG_HIDDEN | Parameter is not shown by default. Can be activated with option in Parametereditor. |
| FLAG_SCOPEABLE | Parameter can be scoped. |
| FLAG_VOLATILE | Value is modified by uC, must be polled regularly. |
| FLAG_NO_FILE_OVERWRITE | Value is not written on write from Parameterfile Operation. It can only modified manually by user. |
| FLAG_SPECIAL_WRITE_ENABLE | The value can only be written in case a special option in the Parameter editor is activated. |
| FLAG_WRITE_APPROVE_REQUEST |
|
| enum GET_VALUES |
List of sources for parameter-access. Every parameter can limit access to these sources. (see Access restrictions).
| Enumerator | |
|---|---|
| PARA_ACCESS_FROM_CODE | |
| PARA_ACCESS_FROM_GUEST | |
| PARA_ACCESS_FROM_USB | |
| PARA_ACCESS_FROM_ETHERNET | |
| PARA_ACCESS_FROM_HESP | |
| PARA_ACCESS_FROM_CAN | |
| enum STORE_LOCATION |
List of storage locations for parameters.
Every parameter can set one of these flags to store the parameter value in a non volatile memory (see Storage of parameter-values in a non volatile memory). Maximum Value = 15
| Enumerator | |
|---|---|
| NOT_STORED | |
| PARA_FLASH | |
| NVRAM | |
| EEPROM | |
| EXT_FLASH | |
| SD_BASE | |
| FACTORY_FLASH | |
| SD | |
| FACTORY_EEPROM | |
| enum ZUGRIFF |
List of access restrictions for parameters. Every parameter can limit read and write access according to these levels. (see Access restrictions).
| int32_t GetDataTypeSize | ( | uint8_t | Type | ) |
Calculate the Size of a parameter-type.
| Type | Parameter-Type |
| Group * GetGroup | ( | uint32_t | GroupID | ) |
| uint32_t GetGroupCount | ( | void | ) |
Get the number of the existent parameter-groups.
The number of groups must be defined in main progframm in the constant ANZAHL_GRUPPEN
Get Parameter-data as object type.
Dependant of the parameter pData, the Data of the given parameter is returned into object ob.
| p | Pointer to the Parameter. | |
| pData | Type of data. element of enum GET_VALUES | |
| [out] | ob | Object to be written |
| ui8AccessLevel | Actual AccessLevel (see Access restrictions). |
| Parameter * GetParameter | ( | uint32_t | ParaID | ) |
| uint32_t GetParameterCount | ( | void | ) |
Get the number of the existent parameters.
The number of parameters must be defined in main progframm in the constant ANZAHL_PARAMETER
Get Parameter-value as object type.
The vlaue of the given parameter is returned into object ob.
| p | Pointer to the Parameter. | |
| SubId | SubId of the parameter | |
| [out] | ob | Object to be written |
| ui8AccessLevel | Actual AccessLevel (see Access restrictions). |
| uint32_t GetStringParameterLength | ( | Parameter * | p, |
| uint16_t | subID | ||
| ) |
Get the length of the string data of the given parameter.
If the parameter is not a string-type, the output value is nonsense!
| p | actual Parameter. |
| subID | Sub-ID of the parameter |
| bool IsValidForRead | ( | void * | pvThis, |
| const ParameterRequest * | ptRequest | ||
| ) |
Check if the actual access-right is sufficient to read the parameter.
| pvThis | Pointer to the Parameter (Parameter or any Parameter_<T>). |
| ptRequest | Request information (SubId, data buffer, access source and level), see ParameterRequest. |
| bool IsValidForSetToDefault | ( | void * | pvThis, |
| const ParameterRequest * | ptRequest | ||
| ) |
Check if the actual access-right is sufficient to set to default the parameter.
| pvThis | Pointer to the Parameter (Parameter or any Parameter_<T>). |
| ptRequest | Request information (SubId, data buffer, access source and level), see ParameterRequest. |
| bool IsValidForWrite | ( | void * | pvThis, |
| const ParameterRequest * | ptRequest | ||
| ) |
Check if the actual access-right is sufficient to write the parameter.
| pvThis | Pointer to the Parameter (Parameter or any Parameter_<T>). |
| ptRequest | Request information (SubId, data buffer, access source and level), see ParameterRequest. |
| float ObjToFloat32 | ( | object * | ob | ) |
Convertrs a given object to float.
| ob | Object to be converted |
Parse Parameter-data out of an object.
This function is used to print the formatted string out of an object. The object is parsed considering the data-type of the parameter.
| p | Pointer to the parameter. |
| data | Object to be processed. |
| dest | Output buffer |
| MaxLength | Size of the output buffer |
| int32_t PARA_ParseString | ( | Parameter * | p, |
| int32_t | SubId, | ||
| char * | input, | ||
| uint8_t | AccessLevel | ||
| ) |
Parse Parameter-data out of an input string.
This function is used to store the binary parameter-value out of a string-value. The string is parsed considering the data-type of the parameter. Only used in serial parameter-interface.
| p | Pointer to the parameter. |
| SubId | SubID to be processed. |
| input | Input string |
| AccessLevel | Actual AccessLevel (see Access restrictions). |
| int32_t PARA_ValAsString | ( | Parameter * | p, |
| int32_t | SubId, | ||
| char * | dest, | ||
| int32_t | MaxLength, | ||
| uint8_t | AccessLevel | ||
| ) |
Output the parameter value as formatted string.
The Parameter-data is given as a formatted string considering the datatype of the parameter.
| p | Pointer to the parameter. |
| SubId | SubID to be processed. |
| dest | POutput buffer |
| MaxLength | Size of the output buffer |
| AccessLevel | Actual AccessLevel (see Access restrictions). |
| int32_t StreamReadParameterData_Value | ( | Parameter_InfoHeader * | ptInfo, |
| uint8_t * | pui8Destination, | ||
| int32_t | i32MaxCount, | ||
| uint32_t | ui32Offset, | ||
| ParameterAccessSource | tAccessSource, | ||
| uint8_t | ui8AccessLevel | ||
| ) |
Read Parameter-data into buffer (Variant 1) The Data of the selected parameter is read and stored into a given buffer address.
The buffer must be in device memory. The size of the buffer must be at least MaxCount bytes. The data-size can be limited and an offset (start) can be set. with these parameters it is possible to split the data into several smaller buffer portions to transmit data with an interface with smaller pacjet size than parameter-data size. If access is not permitted, data size 0 is returned. In this variant the Parameter-id and sub-id is given, the parameter is searched in memory with these vaules.
| ptInfo | Parameter_InfoHeader which contains Parameter-id and Sub-id of the processed parameter. |
| pui8Destination | Buffer to store the data. |
| i32MaxCount | Buffer size of the output buffer / maximum stpored data size into output buffer. |
| ui32Offset | Start position of the data. |
| tAccessSource | Source of access (see Access restrictions). |
| ui8AccessLevel | Actual AccessLevel (see Access restrictions). |
| int32_t StreamReadParameterData_Value2 | ( | Parameter * | p, |
| const ParameterRequest * | ptRequest | ||
| ) |
Read Parameter-data into buffer (Variant 2) The Data of the selected parameter is read and stored into a given buffer address.
The buffer must be in device memory. The size of the buffer must be at least MaxCount bytes. The data-size can be limited and an offset (start) can be set. with these parameters it is possible to split the data into several smaller buffer portions to transmit data with an interface with smaller pacjet size than parameter-data size. If access is not permitted, data size 0 is returned. In this variant a pointer to the Parameter is given, the parameter has not to be searched in memory withparameter-id and therefore it is faster than variant 1.
| p | Pointer to the Parameter. |
| ptRequest | Request information: start SubId, output buffer, buffer size, offset (strings only), access source and level, see ParameterRequest. |
| int32_t StreamWriteParameterData_Value | ( | Parameter_InfoHeader * | ptInfo, |
| uint8_t * | pui8Source, | ||
| uint32_t | ui32Offset, | ||
| ParameterAccessSource | tAccessSource, | ||
| uint8_t | ui8AccessLevel | ||
| ) |
Write Parameter-data from buffer (Variant 1) The Data of the given buffer is written to parameter.
The buffer must be in device memory. The buffer may not contain the complete parameter data, even portions are possible. Due to this, the start offset and the data size can be given with parameters. If access is not permitted, data size 0 is returned. In this variant the Parameter-id and sub-id is given, the parameter is searched in memory with these vaules.
| ptInfo | Parameter_InfoHeader which contains Parameter-id and Sub-id of the processed parameter. |
| pui8Source | Buffer containing the parameter data to be written |
| ui32Offset | Start position of the data. |
| tAccessSource | Source of access (see Access restrictions). |
| ui8AccessLevel | Actual AccessLevel (see Access restrictions). |
| int32_t StreamWriteParameterData_Value2 | ( | Parameter * | p, |
| const ParameterRequest * | ptRequest, | ||
| uint16_t | ui16Count | ||
| ) |
Write Parameter-data from buffer (Variant 2) The Data of the given buffer is written to parameter.
The buffer must be in device memory. The buffer may not contain the complete parameter data, even portions are possible. Due to this, the start offset and the data size can be given with parameters. If access is not permitted, data size 0 is returned. In this variant a pointer to the Parameter is given, the parameter has not to be searched in memory withparameter-id and therefore it is faster than variant 1.
| p | Pointer to the Parameter. |
| ptRequest | Request information: start SubId, input buffer, offset (strings only), access source and level, see ParameterRequest. i32MaxCount is not used, the size is given by the datatype. |
| ui16Count | Number of SubIDs to process |
| int32_t StreamWriteStringParameter | ( | Parameter * | p, |
| uint16_t | ui16StartSubId, | ||
| uint16_t | ui16Count, | ||
| uint8_t * | pui8Destination, | ||
| uint32_t * | pui32MaxCount, | ||
| ParameterAccessSource | tAccessSource, | ||
| uint8_t | ui8AccessLevel | ||
| ) |
Read String Parameter-data into buffer (Variant 1) The Data of the selected string-parameter is read and stored into a given buffer address.
In this function not only one sub-id is read, but the complete data of all sub-ids. The data of one sub-id is not cut -> the length of the buffer mist be larger of every sub-id length. If the next sub-id datalength is larger, than remaining buffer size, the functions returns. It is mainly used by an ethernet-interface, bacause one ethernet-frame can be store normally much more data that one sub-id and therefore it is more efficient to process all sub-ids at once. The buffer must be in device memory. The size of the buffer must be at least MaxCount bytes. The data-size can be limited and an offset (start) can be set. with these parameters it is possible to split the data into several smaller buffer portions to transmit data with an interface with smaller packet size than parameter-data size. If access is not permitted, data size 0 is returned.
| p | Pointer to the Parameter. |
| ui16StartSubId | Sub-ID to start the data read. |
| ui16Count | Number of sub-ids to process. |
| pui8Destination | Buffer to store the data. |
| pui32MaxCount | Pointer to the Buffer size of the output buffer / maximum stpored data size into output buffer. After processing this function the pointer haleds the data size of the destination-buffer which is used. |
| tAccessSource | Source of access (see Access restrictions). |
| ui8AccessLevel | Actual AccessLevel (see Access restrictions). |
| int32_t StreamWriteStringParameter2 | ( | Parameter * | p, |
| uint16_t | ui16StartSubId, | ||
| uint16_t | ui16Count, | ||
| uint8_t * | pui8Destination, | ||
| uint32_t * | pui32MaxCount, | ||
| ParameterAccessSource | tAccessSource, | ||
| uint8_t | ui8AccessLevel, | ||
| uint32_t * | pui32StrPos | ||
| ) |
Read String Parameter-data into buffer (Variant 2) The Data of the selected string-parameter is read and stored into a given buffer address.
In this function not only one sub-id is read, but the complete data of all sub-ids. The data of one sub-id is cut, if the buffer-size is not large enough to held the complete data of the actual sub-id, the matching part is copied to the buffer. The string position is returned in the parameter StrPos. This Variant should be used, if strings are large, even larger than buffer size. It is mainly used by an ethernet-interface, bacause one ethernet-frame can be store normally much more data that one sub-id and therefore it is more efficient to process all sub-ids at once. The buffer must be in device memory. The size of the buffer must be at least MaxCount bytes. The data-size can be limited and an offset (start) can be set. with these parameters it is possible to split the data into several smaller buffer portions to transmit data with an interface with smaller packet size than parameter-data size. If access is not permitted, data size 0 is returned.
| p | Pointer to the Parameter. |
| ui16StartSubId | Sub-ID to start the data read. |
| ui16Count | Number of sub-ids to process. |
| pui8Destination | Buffer to store the data. |
| pui32MaxCount | Pointer to the Buffer size of the output buffer / maximum stpored data size into output buffer. After processing this function the pointer haleds the data size of the destination-buffer which is used. |
| tAccessSource | Source of access (see Access restrictions). |
| ui8AccessLevel | Actual AccessLevel (see Access restrictions). |
| pui32StrPos | Position of the last Sub-ID which does not match completely into buffer. |
|
extern |
Number of existent parameter-groups. Must be defined in main program.
|
extern |
Number of existent parameters. Must be defined in main program.
|
extern |
Pointer to the Actual access-level (see Access restrictions).
|
extern |
Flag to show if the remanent storage is modified.
On each modification of the stored value, this flag is set. It is displayed in parameter-editor on PC. The flag is resetted on a "save to NV" operation.
|
extern |
Actual access-level (see Access restrictions).
|
extern |
List of all existent parameter-groups in device. The list is filled by the paraInit function.
|
extern |
List of all existent parameters in device. The list is filled by the linker automatically.
| ReadFunction_F32 ReadFunction_STD_F32 |
| ReadFunction_I16 ReadFunction_STD_I16 |
| ReadFunction_I32 ReadFunction_STD_I32 |
| ReadFunction_F32 ReadFunction_STD_I32Q16 |
| ReadFunction_I64 ReadFunction_STD_I64 |
| ReadFunction_I8 ReadFunction_STD_I8 |
| ReadFunction_STR ReadFunction_STD_STR |
| ReadFunction_U16 ReadFunction_STD_U16 |
| ReadFunction_U32 ReadFunction_STD_U32 |
| ReadFunction_U64 ReadFunction_STD_U64 |
| ReadFunction_U8 ReadFunction_STD_U8 |
| ReadFunction_U8 ReadFunction_STD_U8_BitWise |
| RestoreDefaultFunction_Generic SetToDefaultFunction_STD_Const |
| RestoreDefaultFunction_F32 SetToDefaultFunction_STD_F32 |
| RestoreDefaultFunction_I16 SetToDefaultFunction_STD_I16 |
| RestoreDefaultFunction_I32 SetToDefaultFunction_STD_I32 |
| RestoreDefaultFunction_F32 SetToDefaultFunction_STD_I32Q16 |
| RestoreDefaultFunction_I64 SetToDefaultFunction_STD_I64 |
| RestoreDefaultFunction_I8 SetToDefaultFunction_STD_I8 |
| RestoreDefaultFunction_STR SetToDefaultFunction_STD_STR |
| RestoreDefaultFunction_U16 SetToDefaultFunction_STD_U16 |
| RestoreDefaultFunction_U32 SetToDefaultFunction_STD_U32 |
| RestoreDefaultFunction_U64 SetToDefaultFunction_STD_U64 |
| RestoreDefaultFunction_U8 SetToDefaultFunction_STD_U8 |
| RestoreDefaultFunction_U8 SetToDefaultFunction_STD_U8_BitWise |
| WriteFunction_Generic WriteFunction_STD_Const |
| WriteFunction_F32 WriteFunction_STD_F32 |
| WriteFunction_I16 WriteFunction_STD_I16 |
| WriteFunction_I32 WriteFunction_STD_I32 |
| WriteFunction_F32 WriteFunction_STD_I32Q16 |
| WriteFunction_I64 WriteFunction_STD_I64 |
| WriteFunction_I8 WriteFunction_STD_I8 |
| WriteFunction_STR WriteFunction_STD_STR |
| WriteFunction_U16 WriteFunction_STD_U16 |
| WriteFunction_U32 WriteFunction_STD_U32 |
| WriteFunction_U64 WriteFunction_STD_U64 |
| WriteFunction_U8 WriteFunction_STD_U8 |
| WriteFunction_U8 WriteFunction_STD_U8_BitWise |