Sequential (Stateful) Logic DevicesSequential Logic Devices contain state, and they use both their input terminals and their state to create their overall functions. Common Sequential Logic Devices are registers, counters, and memory Devices. Counter Device Counter DeviceCounters perform a binary incrementing function. When a Counter reaches its maximum value, it "wraps" back to its starting value. Counters rely on a digital "clock", which is a wire which oscillates between an Counters have a user defined set of inputs and outputs. The outputs perform the counting function. The inputs serve as a reference for a Counter output called "eq". The "eq" output will turn Counters have two dedicated inputs called "reset" and "sync_reset". Both are used to set a Counter to its lowest value (outputs all will be A simple way to get a Counter to count to a user defined value is to place the desired value on the Counter's user defined inputs and connect the Counter's "eq" output to the Counter's "sync_reset" input. Each time the Counter's outputs equal the Counter's inputs, the counter will clear and start counting again. The "clk" input provides the clocking for the Counter. Each time the "clk" input sees an Counter Devices are created by running the Counter Script with the following parameters:
Running the Counter Script with the parameters listed below will create an 4 bit counter with four inputs (D1, D2, D3, D4) and four outputs (Q1, Q2, Q3, Q4).
Debouncer DeviceThe Debouncer Device removes noise from signals on wires. If a wire usually has the right value, but occasionally jumps to an incorrect value and back to the right value, the incorrect value is referred to as noise. The Debouncer Device removes noise from signals. The Debouncer Device will only pass a signal from its input to its output terminal when the signal is stable for a user definable period of time. If, for example, a signal occasionally went to an incorrect value for 5 seconds or less, the Debouncer Device could be set to only pass signals that were stable for 6 seconds, and the noise would be removed from the signal. The Debouncer Device has a "clk" input, which it uses to measure the time a signal on its input is stable. Every time the "clk" input transitions from A simple way to set up a Debouncer Device is to wire an Oscillator Device output to a Debouncer Device's "clk" terminal. Using the less than 5 seconds of noise example above, one could set the Oscillator period to 3 (seconds), and that would guarantee that the Debouncer would only pass signals which were stable for 6 seconds or more. The Debouncer Device has one or more inputs, matched with one or more outputs, with each input/output pair providing a debouncing function. Debouncer Devices are created by running the Debouncer Script with the following parameters:
Running the Debouncer Script with the parameters listed below will create 2 debouncing functions, one with the input and output "1" and "1S", and the other with input and output "2" and "2S".
Register DeviceThe Register Device is a storage Device, each Register output holding a single Registers have a user defined set of inputs and a matched set of user defined outputs. A register input is clocked to its paired output on every Registers have a "reset" input terminal. When the "reset" terminal is Register Devices are created by running the Register Script with the following parameters:
Running the Register Script with the parameters listed below will create a register which stores 2 values, one with the input and output terminals "D1" and "Q1", and the other with input and output terminals "D2" and "Q2".
|