Specifications
Chapter 3 – Input/Output Interfaces
92 PL 3120/PL 3150/PL 3170 Power Line Smart Transceiver Data Boo
k
Totalcount Input
A timer/counter can be configured to count either rising or falling input edges, but not both. Reading the value of a
totalcount object gives the number of transitions because the last time it was read (0 to 65,535). Maximum frequency of
the input is one-quarter of the input clock rate, for example 2.5MHz at a maximum of 10MHz PL Smart Transceiver
input clock. This object is useful for counting external events such as contact closures, where it is important to keep an
accurate running total (see Figure 3.48).
read input_value = 4, resetread, reset
t
ret
t
fin
READ
TIMER/
COUNTER
FLAG AND
EVENT
REGISTER
CLEAR FLAG
END OF
io_in()
START OF
io_in()
Event Register
Event Register
Timer/Counter 1
Timer/Counter 2
mux
IO10
IO9
IO8
IO0
IO1
IO2
IO3
IO4
IO5
IO6
IO7
Reference Figure 3.40
Optional Pull-Up Resistors
IO11
Symbol Description Typ @ 10MHz
t
fin
Function call to input sample 92 µs
t
ret
Return from function 61 µs
Figure 3.48 Totalcount Input Latency Values
A call to this function returns the current value of the totalcount value corresponding to the total number of active clock
edges because the last call. The counter is then reset, and ready for the next series of input transitions.
The actual active edge of the input depends on whether or not the invert option was used in the declaration of the
function block. The default is the negative edge.










