I have just noticed that I have duplicated the same object twice. I will check if this is the issue!
Hi There, I have been working on a project to make a PLC a CANopen slave. It's been working very well so far, but I have found either an issue or something I'm not doing right. When mapping objects to PDOs, boolean values are not working as expected. No errors are reported by the compiler, however, in runtime these PDO objects do not work properly. Setting a boolean RPDO object to TRUE has no effect in the slave application, and boolean TPDOs written by the slave application do not change state either....
Hi BY, Could you tell me how you imported your DBC file? I have one to import but I can't find how to import it into my instance of Codesys! Cheers, John
Any help on this would be greatly appreciated! :D
Hi All, I need to monitor an active connection between Codesys(PC) and a PLC. I have tried monitoring active visu clients, but unfortunately this doesn't work. I think this is most likely because the PLC is an embedded system and most importantly doesn't have a display for Visu. Monitoring active visu clients on a display works no problem. Is there an easy and light weight way of monitoring an active connection between Codesys (PC) and PLC via code? I was really hoping there might be a system variable...
Hi All, I need to log into a Codesys 3.5 PLC via CANbus (CR711S). The manufacturer is ifm Electronic GmbH. The release notes state that it is possible to do so, but a PCAN-USB adapter must be used for stable connection. It also says that the CAN client must be added to the Codesys gateway configuration as a top level interface. I have a PCAN-USB adapter, and from what I can see in my Windows device manager, the service for the adapter is 'PEAK_USB'. I have added this as a CAN client to my gateway...
Yes after a bit more investigation I can see that it is a module that must be added, whereas I was trying to add it to my application. I will have a go! I've had a little bit of success with the SysFile library, but unfortunately it still doesn't help my problem! If I use the mode 'AM_READ_PLUS' this allows me to write data to a specific location after using the SysFileSetPos function as I had hoped. The problem now is although I can now write in a specific location, any data from that point equal...
Hi Morberis, Thank you very much for your quick reply! After having a look at the Datalog manager it seems as though it is a new feature of SP16, so perhaps I could download the new version and try this. I'm not sure if my target device will work with it but it's worth a look for sure. I'm fairly familiar with using attributes so if this method is possible for my target then maybe this is the way to go with my FB. I have also noticed that the CAA File library doesn't seem to use the functions of...
I have also found this to be an issue. I am creating a function block to create a .CSV file using the SysFile.Lib but also want to implement code so that it is possible to log data in a ring buffer format. The principle is that once a maximum entry limit is reached the last entry will be removed by truncating the file. This works no problem, however, because appending to files in a specific position is not possible the oldest data stays and the latest entry in the file changes each time the code...
Hi there, Thanks for your reply! That's very useful information and I will definitely consider this as my solution. I had looked into something similar, however, the method has it's limitations i.e. the maximum node ID in the network is 64 after using so many PDOs. There are also 4 variants of the controller I am developing this solution for, where the highest I/O density is 128 with almost every pin configurable as analogue or digital inputs/outputs - so 30 PDOs may only be suitable for less I/O...
Hi There, I'm attempting to create a CANopen device configuration for a PLC, so that it can be used as a CANopen slave device for other control systems. The PLC I am configuring is very capable in terms of I/O, so there is a lot of process data that will need to be made available. The standard 4 TPDOs will not be a large enough data area for process data, so I'm looking to use Multiplexed PDOs (MPDOs). MPDOs use standard PDOs, but multilplex the data contained within it, so that vast amounts of data...
Hi there, I am developing a file browser for an ifm display (CR1059). The display OS is embedded linux (yocto). I have used the CAA file library with success, however, I can see there is a limitation when using this library. To open a file or directory you must enter the file path, but this is limited to 255 characters. Therefore it would only be possible to browse files and directories if the complete filepath is <= 255 characters. Because of this, I have been trying a different method using the...
Hi Edwin, My CODESYSControl.cfg file was: [SysCom] Linux.Devicefile=/dev/ttyUSB portnum := COM.SysCom.SYS_COMPORT1; But now I have removed the ';' [SysCom] Linux.Devicefile=/dev/ttyUSB portnum := COM.SysCom.SYS_COMPORT1 This seems to work now, but the data I am receiving is not right - this could be my USB adapter or hardware set-up, but if you (or anyone else in the community!) have any pointers then that would be very helpful! I am usuing Hercules to send: 'Hello' But I am receiving this in my...
Hi Edwin, Thank you for your quick response! My RTS version is 3.5.15.10. Best regards, John
Hi there, I've been reading through this thread and have tried most solutions to try and achieve RS232 comms via USB adapter. The difference is the hardware I am using is an HMI from ifm Electronic (Codesys SP15 Patch1), running Linux version 4.14.98-yocto-standard. I've tried many variations of the CODESYScontrol.cfg and CODESYScontrol_User.cfg files for SysCom settings but none delivered a good result. The Linux commands to read and write using the USB adapter seem to work fine, it just seems that...