Doubt about the CurTimeEx function block.

hcchin
2010-04-20
2010-06-05
  • hcchin - 2010-04-20

    I am trying to use this "CurTimeEx" function block to get the controller's date, time, and day of the week but it just return the default date, time and the day of the week. (1970-01-01, 00:00s, 0)

    I want to know the day of the week when i give the date and time to the CurTimeEx function block. It seem doesn't work.....

    I also have try the "CurTime" i am not sure, Is it works as i don't know what is return data mean for... the data type is "SysTime64".

    perhaps you can advise me how to use the CurTimeEx function block.

     
  • shooter - 2010-04-30

    go to w www.oscat.de w

    you will find a day_of_week function.

     
  • maauto - 2010-04-30

    Maybe it's platform dependent, but for my target CurTimeEx just works without needing to do anything else. You need to include SysLibTime.lib and that's it. And BTW, it doesn't seem to work in simulation mode.

    But what do you mean by "when I give the date and time to the CurTimeEx" ?

     
  • rahulnshinde - 2010-05-10

    Hi,

    Try this sample project I crafted out for you.

    U will be required to change the target settings.

    You can investigate further in my custom made program as per your requirements.

    Hope this helps.

    Regards,

    Rahul.

    Sample.rar [22.02 KiB]

     
  • Romuald - 2010-06-03

    hcchin hat geschrieben:
    I am trying to use this "CurTimeEx" function block to get the controller's date, time, and day of the week but it just return the default date, time and the day of the week. (1970-01-01, 00:00s, 0)

    On my WAGO, I noticed that first, the clock is not updated. In the web interface, the option 'Clock' always shows the beginning's unix time i.e. 1970-01-01. After a clock update, the clock has been functionnal.

    So try to update clock with the Web interface.

     
  • hcchin - 2010-06-05

    shooter hat geschrieben:
    go to w www.oscat.de w
    you will find a day_of_week function.

     

Log in to post a comment.