Author Topic: Displaying time  (Read 5751 times)

StefanA

  • Newbie
  • *
  • Posts: 29
  • I'm a llama!
    • View Profile
Displaying time
« on: January 31, 2014, 06:40:11 AM »
I want to display my nano-10's RTC on a software HMI. I use the modbus holding registers for hours, minutes and seconds. Hours and minutes works fine but the seconds skips every other value. The software HMI are supposed to have a poll rate of 500ms.  What could be wrong?

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3171
    • View Profile
    • Internet Programmable PLCs
Re:Displaying time
« Reply #1 on: February 01, 2014, 05:03:12 PM »
Most likely the HMI is not polling the seconds every 0.5s. The HMI could be sending some wrong commands that is not accepted by the PLC and therefore time out of these commands caused the actual polling period of those valid commands to become longer.

You can connect U-485 to the RS485 port and monitor the communication traffic between your HMI and the PLC and see how often is the command to retrieve the TIME[3] value is sent and how long it takes the PLC to reply.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

StefanA

  • Newbie
  • *
  • Posts: 29
  • I'm a llama!
    • View Profile
Re:Displaying time
« Reply #2 on: February 05, 2014, 09:58:52 AM »
I use modbus/tcp. But I have a lot of objects on the hmi screen and apparently it takes to long to update them. I made a test screen with only the time registers and that work fine. Have to think something out. Another question. Can I use the 5v analog reference voltage to power a analog temp. sensor? The current runs well below 50µA.

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3171
    • View Profile
    • Internet Programmable PLCs
Re:Displaying time
« Reply #3 on: February 05, 2014, 08:29:03 PM »
Yes the 5V reference voltage on the Nano-10 can source 10mA of current to your temperature sensor. Since it only takes 50uA there is no problem at all.

Is it very critical to be able to see the "seconds" being updated on the HMI every second?

You can try to connect to the PLC via the Ethernet if your HMI support it. Ethernet communication is significantly faster than serial communication.

If you must use serial comm, you can try to increase the baud rate of both the PLC and the HMI to see if that makes a difference.
« Last Edit: February 05, 2014, 08:30:29 PM by support »
Email: support@triplc.com
Tel: 1-877-TRI-PLCS