Activity for ph0010421

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I've made an FB which is a TCP server. It uses the excellent CAA NetServices library. If I have the FB in a task <4ms, then the RT crashes immediately at boot up. If the task >=4ms, it starts and runs perfectly. This is even if the block is not doing anything; just instantiated. Am I missing something silly? Why would a low task time cause this? 4ms is perfectly adequate, but I'm just interested why... thanks PH

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I've made an FB which is a TCP server. It uses the excellent CAA NetServices library. If I have the FB in a task <4ms, then the RT crashes immediately at boot up. If the task >=4ms, it starts and runs perfectly. This is even if the block is not doing anything; just instantiated. Am I missing something silly? Why would a low task time cause this? thanks PH

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    So the printer wants an ASCII conversion of the hex equivalent of ASCII characters?? They don't make it easy for us

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    hello Use FC3 instead of FC4

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I'm using the MQTT_Client_SL library. Very good so far. One of the inputs to the MQTTClient FB is hCert (RTS_IEC_HANDLE). Which function do I need to use to get this? Or do I add a FILE library? thanks

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    So it's currently mapped to an array of BYTES? Can you create a UNION? TYPE sBytesString : UNION AsBytes: ARRAY[0..127] OF BYTE; AsString: STRING(128); END_UNION END_TYPE Map it to the bytes, read it in the STRING!

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    My guess is that's a STRING, not an INT type. And it's 128 bytes, not bits

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    My guess is that's a STRING, not an INT type.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I wouldn't call an FB from inside a FUN; it feels wrong to me. I have had something similar. Try declaring the FB instances as GlobaVars rather than the instance memory.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Like this?

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello New W11 machine. I've tried installing and the 'Codesys installer' appeared, which basically failed. This was the exe from the Store. I've now tried installing with an old copy of SP17, which didn't try and use the Codesys installer, but has hung at the 'Install all packages added to the setup' stage. Has the exe been updated to use the Codesys installer? What is the installer? Do we think it'll work on w11? thanks, Paul

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I can't find anything to read on the subject so I'll ask here. Up to now, when adding a (for example) Modbus Master, I've selected the version <= the RT version, so if I'm using SP13 Patch 3, I can use a library that doesn't exceed this. I've no idea if this is correct, but it's always worked. Can someone explain the 4.x.x.x libraries that have appeared; are they tied to a RT version? The controller I use is now at SP18Patch60, so should I continue to use 3.5.xxx or change? thanks

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello That's certainly CiA402. I'll attach a part of the manual for my servos, but the state diagram should be the same at yours. To be sure, get one from your manufacturer. Look at the bits in the StatusWord to see where you are in the diagram, then twiddle the bits in the ControlWord to get you to the next step. Then there are other bits in the StatusWord to tell you 'InPosition' and things like that. From the screenshot, as it mentions only 'PositionProfile' the driver will create the motion profile....

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello You'll need to write a proper sequence to send, then wait for confirmation, and then move on to the next step. Use the CASE statement in ST. It's perfect for creating a sequence.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    I've had the same with SP19 patch 2 I can't help you I'm afraid.

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello Use 'Import PLCOpenXML' to bring this into your project.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello Use 'Import PLCOpenXML'

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Click on NET in the project tree and add it there.

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello TCIS_Send needs to be longer than 4 bytes because idata is 28 bytes long. There may be other ways, but I would make a UNION with string/array of bytes. Write your STRING into the AsString part then copy the AsBytes part into TCIS_Send (Elements [3] to [30]) then 252 would be in [31] (I've assumed the idata is always the same length)

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello TCIS_Send needs to be longer than 4 bytes because idata is 28 bytes long. There may be other ways, but I would make a UNION with string/array of bytes. Write your STRING into the AsString part then copy the AsBytes part into TCIS_Send (Elements [3] to [30]) then 252 would be in [31]

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    In the Struct, change the 'BOOL' to 'BIT'

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I've just seen this feature: very nice. Using the 'DeviceReader' project previously, I could see the SL possibility too (Dongle or Softkey). Is it possible to get this status too please?

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I've just seen this feature: very nice. Using the 'DeviceReader' project previously, I could see the SL possibility too (Dongle of Softkey). Is it possible to get this status too please?

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Do you need an 'hours-run' counter? And 1 second resolution is ok? I think you're over-thinking it. (The task time needs to be < 1second) Have a look at the LAD... Then, the time in seconds can be made into hh:mm:ss with this FUNction Declarations: FUNCTION funSecondsToStringTime: string VAR_INPUT InSeconds: UDINT; END_VAR VAR AsString: STRING; Minutes: UDINT; Hours: UDINT; Seconds: UDINT; MinutesAsString: STRING(2); HoursAsString: STRING(2); SecondsAsString: STRING(2); END_VAR and the code: Hours...

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    FUNCTION_BLOCK fbdStopwatch VAR_INPUT Condition: BOOL; END_VAR VAR_OUTPUT TimeTaken: TIME; END_VAR VAR StartTime: TIME; fbiStartOs: R_TRIG; fbiStopOs: F_TRIG; END_VAR and then: fbiStartOs(CLK := Condition); fbiStopOs(CLK := Condition); IF fbiStartOs.Q THEN StartTime := TIME(); END_IF; IF fbiStopOs.Q THEN TimeTaken := TIME() - StartTime; END_IF;

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    I'd contact Beijer directly.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello With a UNION: TYPE uDINT_WORD : UNION AsDINT: DINT; AsWORDs: ARRAY[0..1] OF WORD; END_UNION END_TYPE then create a variable of this type and the WORDs MyDINT: uDINT_WORD; LSW: WORD; MSW: WORD; Then you can access the WORDs... MyDINT.AsDINT := 70000; LSW := MyDINT.AsWORDs[0]; MSW := MyDINT.AsWORDs[1];

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    the BIT datatype actually takes 1 bit, but it can't be in an ARRAY. That may work for you?

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello We have a Siemens RF680R rfid reader. Siemens have given me a Beckhoff library (I'm not using Beckhoff). They have nothing else. And not even a manual, apparently. Has anyone got any sample code to talk to this device? It supports ethernet/ip (only a few WORDs each way); the bulk of the comms being done by generic CIP messaging. thanks

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    The T7B SoftControl is an old product and has been superseded. It wasn't able to add additional licences to it (Mod TCP Server in your case). The built-in licences are ethercat master, Modbus RTU master and Modbus TCP client. The current X2 platform does have this capability.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I created a library (Lib1) and I use another library (Lib2) in there. If I give Lib1 to someone, do I need to give them Lib2 also? Or can I 'inlcude' Lib2 insode Lib1? thanks

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    that's the bit pattern for an iee754 floating point number, not a string. And it's 3.714 not 37.14

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    You can put your Pause flag in series with the line that advances the sequence. (Before the MOV 20 in your code) So it will finish step 10 that wait there before moving to step 20

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    I think that was the problem. It was a long time ago!

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I've had this exact problem. I think it was the Axis setting "Dynamic Limit". I increased this value (maybe the Accel and decel too). I didn't work out the reason why!!

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Just put a R_TRIG and F_TRIG in a new FB

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    The drive's own torque-limit homing method is ok, but not for vertical axes. I made a sequence to set the drive's torque limit, then do a MC_Jog and wait for zero-speed. Then a MC_Home (method 35)

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    The drive's own torque-limit homing method is ok, but not for vertical axes. I made a sequence to set the drive's torque limit, then do a MC_Jog and wait for zero-speed. The a MC_Home (method 35)

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello Using EtherCAT. Is it possible to register from the Z phase using MC_Touchprobe? thanks

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    I credit Isaac Newton 😁

  • ph0010421 ph0010421 modified a comment on discussion Motion πŸ‡¬πŸ‡§

    v^2 = u^2 + 2as (v^2 / 2a) = s (15000 * 15000) / (2 * 45000) = s

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    v^2 = u^2 + 2as (v^2 / 2a) = s (15000 * 15000) / (2 * 45000) = s

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello As the box has no FUN or FB assigned yet, outputs can't be added yet; the pins are placed automatically based on the FUN (or FB) definition. If you want the box to be as you wish (with your choice of inputs and outputs), then add a new POU-->FB (or FUN)

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello For tool correction, can I just use the G41/G42, or do I need to use the SMC_ToolCorr FB aswell? thanks Ph

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Great answer. Thank you

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello I have CNC files with M-codes. I don't want to stop the path when I see an M-code, but I need to recognise the M-code. If I use 'PreAcknowledge', the path doesn't stop, but I don't see wM from the interpolator. Any ideas please? ph

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I'd like to map data to EtherCAT IO from my IEC code instead of using the EtherCAT I/O Mapping tab. I can point to(and read) the inputs. (I can see the base address and offset from there) With the outputs, it seems the mapping tab is overwriting my data (I have no variable mapped). Is there a way to inhibit the 'graphical' mapping? (The slave NEEDS to see PDO assignment or I could use SDO only)

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello I'd like to map data to EtherCAT IO from my IEC code instead of using the EtherCAT I/O Mapping tab. I can point to(and read) the inputs. With the outputs, it seems the mapping tab is overwriting my data (I have no variable mapped). Is there a way to inhibit the 'graphical' mapping? (The slave NEEDS to see PDO assignment or I could use SDO only)

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    I made this little stopwatch FB. The accuracy can't be better than the scan time though.

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Changed := Old <> New; Old := New;

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello you need the ESI file from Delta. Then just add this device under the Ethercat master. I doubt there's a specific library for a VFD.

  • ph0010421 ph0010421 modified a comment on discussion Motion πŸ‡¬πŸ‡§

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello I'd like to create a CAM at runtime. I need to enter 4 points (x,y) and then select this cam. Can anyone help? thanks

  • ph0010421 ph0010421 posted a comment on discussion Runtime πŸ‡¬πŸ‡§

    An old thread, but I've just found this is the same for the TCP_Read aswell. Paul

  • ph0010421 ph0010421 modified a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello I'd like to start a cam, but at an absolute position on the Master. So I can execute MC_CamIn now, but the cam will actually start in 100mm. I'd like to replicate a MOVELINK instruction which is available of some motion controllers. thanks

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hello I'd like to start a cam, but at an absolute position. So I can execute MC_CamIn now, but the cam will actually start in 100mm. I'd like to replicate a MOVELINK instruction which is available of some motion controllers. thanks

  • ph0010421 ph0010421 posted a comment on discussion Motion πŸ‡¬πŸ‡§

    Hi all This question has been asked a few times, but no answer. Is it possible to control a servo (on ethercat) but use an external encoder as the position feedback? thanks

  • ph0010421 ph0010421 modified a comment on discussion Engineering πŸ‡¬πŸ‡§

    I'll answer my own question. It doesn't read 0x1018, but reads the value in the slave eeprom. This is accessed by <SlaveName>.VendorId Codesys makes it easier than you think!

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    I'll answer my own question. It doesn't read 0x1018, but reads the value in the slave eeprom. This is accessed by <SlaveName>.VendorId

  • ph0010421 ph0010421 posted a comment on discussion Engineering πŸ‡¬πŸ‡§

    Hello Does the EtherCAT master read 0x1018 sub 1 to confirm VendorId? (EtherCAT master-->Startup Checking) I have an ESI file with vendor Id 755 and the device is actually 7595 but there is no problem. I need to confirm the slave is really 755 thanks

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Object doesn't exist in the object dictionary I think.

  • ph0010421 ph0010421 modified a comment on discussion Motion

  • ph0010421 ph0010421 posted a comment on discussion Motion

    Hello I'm using MC_CamIn, but I'd like to be able to change between a virtual master (normal operation) or a handwheel (setting up). Is it possible to simply copy the relevant axis to a 'new' master? IF Setting then NewMasterAxis := HandwheelAxis; ELSE NewMasterAxis := MyVirtualAxis; END_IF; and use 'NewMasterAxis' for the MC_CamIn? thanks Ph

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Hello Try creating a UNION between: AsBytes: ARRAY[0..3] OF BYTE; AsReal: REAL; Map your incoming bytes to AsBytes[0], [1], [2] and [3] and the REAL value should appear in AsReal. You may need to change the order 0123 to 2301 in the mapping depending on the device.

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Use the matching IDE then 'update device' on the ethercat master and you should be able to select the best version. Alternatively, the PLC vendor should have a project archive with their preferred versions of libraries. Extract this to a new project and then their libraries will magically appear so you can select them.

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    If your PLC runtime is 3.5.6 then the ethercat library needs to be this version (or the latest version, without exceeding)

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Hello Is it possible to lock an FB before sharing? (As PLCOpenXml perhaps?) or is the only way to prevent changing/viewing to put it in a Library? thanks

  • ph0010421 ph0010421 modified a comment on discussion Engineering

    Hello I'm using this sample code: https://faq.codesys.com/display/CDSFAQ/Reading+the+Manufacturer+Information+of+the+Controller but the Runtime is crashing. My target is 3.5sp13 patch3; I'm pretty sure this worked with SP10. I have to delete the app to get comms again. Any ideas??

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Hello I'm using this sample code: https://faq.codesys.com/display/CDSFAQ/Reading+the+Manufacturer+Information+of+the+Controller but the Runtime is crashing. My target is 3.5sp13 patch3; I'm pretty sure this worked with SP10. Any ideas??

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Hi everyone I've made a library that uses the iodrvEthercat library. My platforms are either sp10 or sp13. In sp13 there are no problems. In sp10 target (so it's using 3.5.10.0 library) there is a problem...I think it's the sdo read/writes. Is there a document showing the improvements between library versions so I can confirm. Thanks. Stay safe...

  • ph0010421 ph0010421 posted a comment on discussion Engineering

    Hello I'd like to be able to turn off PDO in the program. I think I could put the etherCAT slave into PreOperational and then write zero to 16#1600 etc, but thought that there may be a cleaner way. One other small problem is the method ETCSlave always seems to return ETC_SLAVE_STATE.ETC_SLAVE_BOOT meaning I need to guess what state the slave is in. (Using SP13) Thanks ph

1