tDiagnoseState (ENUM) ¶ TYPE tDiagnoseState : InOut: Name Initial DiagnoseState_InvalidInputParameter -1 DiagnoseState_NotEnabled 0 DiagnoseState_GetDiagInfo 1 DiagnoseState_DiagInfoAvailable 2 DiagnoseState_DiagInfoNotAvailable 3
Functions ¶ ApplicationStateChanged (Function) CallDeviceSpecificFunction (Function) CloseKbus (Function) ConfigureDevice (Function) ConfigureSubdevice (Function) DiagnoseGetDeviceState (Function) DiagnoseGetSubdeviceState (Function) GetDeviceFlags (Function) GetIoSizes (Function) GetLastError (Function) OpenKbus (Function) ReadBit (Function) ReadBool (Function) ReadBytes (Function) ReadEnd (Function) ReadStart (Function) RegisterEventHandler (Function) UnregisterEventHandler (Function) WatchdogSetTime (Function) WatchdogStart (Function) WatchdogStop (Function) WatchdogTrigger (Function) WriteBit (Function) WriteBool (Function) WriteBytes (Function) WriteEnd (Function) WriteStart (Function) kbus_information ldkc_KbusInfo_Create (Function) ldkc_KbusInfo_Destroy (Function) ldkc_KbusInfo_GetDigitalOffset (Function) ldkc_KbusInfo_GetDigitalOffsetInput (Function) ldkc_KbusInfo_GetDigitalOffsetOutput (Function) ldkc_KbusInfo_GetStatus (Function) ldkc_KbusInfo_GetTerminalCount (Function) ldkc_KbusInfo_GetTerminalDiagnose (Function) ldkc_KbusInfo_GetTerminalInfo (Function) ldkc_KbusInfo_GetTerminalList (Function) ldkc_KbusInfo_TerminalDiagnoseRelease (Function)
ApplicationStateChanged (FUN) ¶ FUNCTION ApplicationStateChanged : DINT Sets the state of the PLC application. Its up to the devices to react accordingly. @param state The state of the application. @return DAL_SUCCESS on success. DAL_FAILURE when at least one device returned an error. InOut: Scope Name Type Return ApplicationStateChanged DINT Input event ApplicationStateChangedEvent
CallDeviceSpecificFunction (FUN) ¶ FUNCTION CallDeviceSpecificFunction : DINT @brief Calls a device-specific function implemented by a device library. @param fnName Name of the function to invoke @param retVal Return value @param … Additional parameters @return DAL_SUCCESS if the function was invoked successfully DAL_FAILURE on error DAL_NOTUSED if the function was not found InOut: Scope Name Type Return CallDeviceSpecificFunction DINT Input fnName STRING retVal POINTER TO UDINT
CloseKbus (FUN) ¶ FUNCTION CloseKbus : DINT Closes the device @param deviceId Id of the device. @return Returns 0 on success, -1 otherwise. InOut: Scope Name Type Return CloseKbus DINT Input deviceId DINT
ConfigureDevice (FUN) ¶ FUNCTION ConfigureDevice : DINT Configures a device. @param deviceId Id of the device. @param configData The device specific configuration. @return Returns 0 on success, -1 otherwise. InOut: Scope Name Type Return ConfigureDevice DINT Input deviceId DINT configData POINTER TO BYTE
ConfigureSubdevice (FUN) ¶ FUNCTION ConfigureSubdevice : DINT Configures a sub device. @param deviceId Id of the device. @param subdeviceId Id of the sub device. @param configData The device specific configuration. @return Returns 0 on success, -1 otherwise. InOut: Scope Name Type Return ConfigureSubdevice DINT Input deviceId DINT subdeviceId DINT configData POINTER TO BYTE
DiagnoseGetDeviceState (FUN) ¶ FUNCTION DiagnoseGetDeviceState : DINT Get the state of the device (corresponds to codesys’ bus). @param[in] deviceId Id of the device. @param[in] bufferSize Size of the supplied buffer. @param[out] diagnoseBuffer Buffer where the state is stored in. @param[out] busState The state of the bus. @return Returns 0 on success, -1 otherwise. InOut: Scope Name Type Return DiagnoseGetDeviceState DINT Input deviceId DINT bufferSize UDINT diagnoseBuffer POINTER TO BYTE busState POINTER TO tBusState
DiagnoseGetSubdeviceState (FUN) ¶ FUNCTION DiagnoseGetSubdeviceState : DINT Get the state of a subdevice (corresponds to codesys’ device). @param deviceId Id of the device. @param subdeviceId Id of the device to get the state from. @param[in] bufferSize Size of the supplied buffer. @param[out] diagnoseBuffer Buffer where the state data is stored in. @param[out] diagnoseState The state of the diagnose. @return Returns 0 on success, -1 otherwise. InOut: Scope Name Type Return DiagnoseGetSubdeviceState DINT Input deviceId DINT subdeviceId DINT bufferSize UDINT diagnoseBuffer POINTER TO BYTE diagnoseState POINTER TO tDiagnoseState
GetDeviceFlags (FUN) ¶ FUNCTION GetDeviceFlags : DINT Returns the devices flags @param deviceId @param flags Pointer to the flags @return Returns 0 on success, -1 otherwise. InOut: Scope Name Type Return GetDeviceFlags DINT Input deviceId DINT flags POINTER TO UDINT