Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

SysSem and SysFile warnings and errors

moshtaraq
2020-03-26
2020-04-03
<< < 1 2 (Page 2 of 2)
  • sgronchi - 2020-03-31

    Should be 0x701 with payload 00, not 10 and it is the CANopen bootup message.
    0x0 - 01 00 is NMT start all (remember some post above?). Really, Wikipedia page (https://en.m.wikipedia.org/wiki/CANopen) is helpful here.

    The project you posted compiles with 0 warnings, 0 errors. If you need help you need also to post at least a snippet where those warnings occur.

    Your RPDO1 has 8 bytes, not 4.

     
  • moshtaraq - 2020-04-03

    I've been playing around a bit with sending and receiving messages over CAN. For my project I need to cyclically send some messages to a couple receivers. When I try to send more than one message (more than one ID) cyclically then 1 message (ID181) is sent 10 times and the other (ID281) 1 time. I know that 181 has a higher priority but when I configure it to send both messages every second, I expect it to send both every second. But only 181 gets through. What parameters do I need to put in 'Event timer', 'Inhibit timer' etc. for it to send both, and eventually about 10 messages, on fixed intervals?

     
  • sgronchi - 2020-04-03

    You are probably using asynchronous mode (254 or 255), usually they are "on event", where event is usually logical OR between "on any mapped variable change" and "on Event Timer event" and "manual triggering" (typically for 254). "Inhibit time" means "do not send me more than 1 message over an Inhibit Time interval". I do not think that Codesys stack support manual triggering.
    You could, in theory, set the same interval (beware of different units!) for both.
    For a more robust solution, you could also look into synchronous mode (again, study CANopen: the CiA 301 document is free, just register on their site, or look at http://www.byteme.org.uk/canopenparent/ for a much shorter explanation).

     
  • moshtaraq - 2020-04-03

    I've read the different types/modes but none seem to fit my needs? The Opus display is the only CANopen device in our network so I have no idea how to implement that synchronous mode. I set both parameters on the same value but still 181 gets through 5x more than 281.

     
  • sgronchi - 2020-04-03

    ...if it is the only CANopen device, why would you even set up that as CANopen slave? There are plenty of valid reasons, but what are yours?
    You can just use CANL2ConfigX children (see target documentation for that), if you do not need a slave.

     
  • moshtaraq - 2020-04-03

    I thought it would've given me more options/flexibility. This is a tiny part for my bachelor thesis so I thought using a normalized and well known piece of software would add value to my thesis. I looked into the CANL2Config but that seems way to complicated from what I can find in the manual from Topcon. If I google it I get 0 results btw.

     
  • sgronchi - 2020-04-03

    CANL2 is just raw CAN, without an application protocol on top like CANopen, DeviceNet or J1939 (a.k.a. NMEA2000 for most parts). Your reasoning is absolutely sound, but I advise you first to study available options and understand the principles behind their architecture and then choose. Experimenting is a beautiful thing, as long you understand what you are doing.
    You typically use CANopen to make a network, so that devices interoperate in a specific way. CANopen provides solutions to a variety of problems, but if you do not understand what it solves, and most what it does NOT solve, you are doomed.
    Network means at least two nodes support CANopen (at least some times, I usually make a CANopen slave to use Object Dictionary for configuration...). If you really want a CANopen slave, and have it working with SYNC, you could instantiate a CANopen manager (Codesys for master) under the same CANbus node as your slave.

    Final note: Inhibit time is in hundreds of microseconds, event timer is in milliseconds, so "same value" means a 10-fold difference.

     
  • moshtaraq - 2020-04-03

    The problem I'm facing is the following: I'm used to Arduino programming and having thousands of examples and documentation is very basic and understandable to beginners and experts. I can't for the life of me find any easy documentation on anything I'm doing so I'm pushed into experimenting. If I google canl2 I find nothing that helps me in the slightest.... If I google something for an arduino project (even a super complicated one) I find hundreds of sites that have examples and tutorials on how to do things.

     
  • sgronchi - 2020-04-03

    CANL2 = CAN Layer 2 = messages over CAN without attached interpretation of IDs and content.
    https://www.kvaser.com/can-protocol-tutorial/ for example.

     
<< < 1 2 (Page 2 of 2)

Log in to post a comment.