On Tue, Aug 23 '22 at 02.01 NZST, Stegemann Uwe <[email protected]> wrote: > I want to setup TwinSafe Logic Terminals, EL6900, EL2904 and EL1904.I've > created a Safety-Project with TwinCat3 and downloaded the safety-logic to the > EL6900. I use the default settings from TwinCat3. Now I want to implement it > to the etherlab-master. > > Do I have to change settings in TwinCat3? I am not an Expert of this; I only > want to use the Safety-Editor to create the Safety - Logic!
Yes, just set up the project in TwinSAFE and download to the module. Depending on the project designed in TwinSAFE you will end up different PDOs. I use ecrt_slave_config_reg_pdo_entry() to deal with the fact the PDO assignment is fixed. This does mean the module has to be "there" and visible to the etherlab master before starting the application. You will need to use TwinCAT to find the order of the slaves "Connections" (your 0x6000/0x7000 is the first connection, 0x6010/0x7010 is the second). On the newer EL6910-based hardware this seems to start at 0x6080/0x7080. > The last point: In the Safety - Logic I used one variable to set > Com/Err - Signal which is also linked to a PDO, I can't mapped! Yes, you'll also need to map Run and ErrAck as well. Run obviously should be asserted the entire time you want to run the safety logic, and ErrAck usually needs a rising edge (or two) after startup, as you will likely have CommErr faults etc. on startup. These show up as the "Standard Inputs" and "Standard Outputs" in the PDO map. For an EL1918 (=EL6910) these are 0xf688:00 and 0xf788:00 - on the older EL6900 you seem to have this at 0xf201 maybe? But you don't have any Standard Outputs mapped I guess. >From what I can see the indices/subindices seem to stay the same regardless of the TwinSAFE config at least - just some might come and go. The size of the Standard Inputs/Outputs PDO might change depending on how many you added, but they always seem to align to 8 bits at least. For the StdInputs/StdOutputs you also need to find the offset for each Input/Output bit in TwinCAT just like finding the slaves "connection" order. These are not fixed position; they can change depending on order you add/delete alias devices in TwinSAFE so need to be checked each time you do a new safety project. If you haven't done so already, I would highly recommend you get your safety logic running happily in TwinCAT (by setting up a dummy PLC project and linking Run/ErrAck/ComErr alias devices etc. to bools). Once this is OK, try and make it work with etherlab - debugging is difficult otherwise (although mapping Group State/Diag PDOs to your application can help somewhat). -- Etherlab-users mailing list [email protected] https://lists.etherlab.org/mailman/listinfo/etherlab-users
