Hi Timo, FUNCTION Sonderzeichen_Check : bool VAR_INPUT sInputString : STRING; // Zu prüfender String END_VAR VAR i: INT; iAsc: INT; END_VAR Sonderzeichen_Check:= TRUE; FOR i:= 0 TO len(sInputString) - 1 DO iAscii:= sInputString[i]; //Get ASCII value //Check value between 48('0') and 65('9') or between 65('A') and 90('Z') or between 97('a') and 122('z') or IF iAscii >= 48 AND iAscii <= 57 OR iAscii >= 65 AND iAscii <= 90 OR iAscii >= 97 AND iAscii <= 122 THEN //iAscii valit ELSE Sonderzeichen_Check:=...
Hi, This is with Combivis Studio. I thought you need a license from KEB to create a boot project.
Hi, I guess you don't have the right xml file. Download Beckhoff_EtherCAT_BKxxx_MDP.zip from https://download.beckhoff.com/download/configuration-files/io/ethercat/xml-device-description and install these in Device Repository.
Ich habe das gleiche problem. Losch mal die '.precompile cache’ datei und öffne dass project. Ich habe dan keine fehler meldung und kann ohne probleme online.
If you use LTIME() you will be very accurate and be able to have a normal task cycle time.
Hi, i guess you want to make a hour counter. You need to store the measured value. Try to use a retain variable, but need a graceful shutdown, or save it your self. see https://forge.codesys.com/forge/talk/Runtime/thread/278e325579/ Succes.
One i wrote this to measure elepse time When xMeasure is true is starts en when false it stops and time is messured. FUNCTION_BLOCK FB_ElapseTime VAR_INPUT xMeasure: BOOL; END_VAR VAR_OUTPUT xRisingEdge: BOOL; xFallingEdge: BOOL; tElapsed: TIME; ltElapsed: LTIME; ltPrev_Elapsed: LTIME; ltElapsedMax: LTIME; END_VAR VAR xLastValue: BOOL; LTIMEStart: LTIME; LTIMEEnd: LTIME; tonReset: TON:= (IN:= TRUE, PT:= TIME#30S0MS); END_VAR ------------------------------------------- xRisingEdge:= (xLastValue XOR...
You have to declare some inputs. declaration: SdoRead_RU01: ETC_CO_SdoRead; wRU01: WORD; code: SdoRead_RU01( xExecute:= , usiCom:= 1, //index of master 1: first ETC master uiDevice:= DRIVE_400U1.PhysSlaveAddr, wIndex:= 16#2C01, bySubindex:= 16#00, udiTimeOut:= 500, pBuffer:= ADR(wRU01), szSize:= SIZEOF(wRU01));