SLC-500 Clock

Introduction to the SLC-500 Clock

The SLC-500 clock is accessed through the Processor Status file (S2). As a result, we can use these data table addresses for events that occur during a certain time of the day. As an example, you might sound a horn every hour at break time. Also, you can generate a report every night at midnight. In addition, you might use the clock for time stamping fault conditions. When the fault occurs, you can copy the time of day to an integer file.

Accessing the clock

To access the clock, open the “Processor Status” at the top of your project tree. Another way to access the status is to open the S2 Data File.

Once the data file is open, take a look at the general tab of the status file.

It must be remembered that the Status file is just another data table. The memory addresses of year, month, date, hour, minute, and second are in the status file. When you press “Set Date & Time”, the time and date is transferred to your processor from your PC. Be sure the remember the hour is in 24 hour format. To put it differently, at 2pm, the value of S:40 will be 14.

A point often overlooked is that the day of week is also in the status file. We just need to change the RADIX to find it. A radix is just the numbering system format in which we are viewing data. Change the RADIX to Decimal, and find S:53. This feature is available in later versions of the firmware for the 5/03 processor or higher.

Free Running Clock

At last, let’s take a look at the free running clock (S4). The free running clock is always running in the processor. We might use this clock for pulsed conditions such as messaging, or an alarm horn. According to the help file when online with my 5/04, bit 0 will cycle every 20ms. For each higher bit number, the clock rate is slower by a factor of 2. Usually, I’ll just start with S:4 to check the rate… For a slower clock rate, user a higher bit number. For a faster clock rate, use a lower bit number.

For more information on the SLC500, visit the category page.

— Ricky Bryce

Leave a comment

Your email address will not be published. Required fields are marked *