| Bibliothek: | Memory |
| Eingeführt: | 2.3.0 |
| Aussehen: | ![]() |
The counter holds a single value, whose value is emitted on the output Q. Each time the clock input (diagrammed with a triangle on the component's south edge) triggers according to its Trigger attribute, the value in the counter may update based on the two inputs on the component's west edge: The upper input is called load and the lower is called count, and they are interpreted as follows.
| load | count | trigger action |
| 0 or z | 0 | The counter remains unchanged. |
| 0 or z | 1 or z | The counter increments. |
| 1 | 0 | The counter loads the value found at the D input. |
| 1 | 1 or z | The counter decrements. |
The range of counting can be configured using the Maximum Value attribute. When the counter reaches this value, the next increment wraps the counter back to 0; and if it is at 0, then a decrement will wrap the counter around back to its maximum value.
In addition to the output Q, the component also includes a single-bit output carry. This is 1 whenever the counter is at its maximum and the load and count inputs indicate that the component should increment on the next step - or when the counter is at 0 and the load and count inputs indicate to decrement at the next step.
The clear input resets the counter's value to 0 (all zeroes) asynchronously; that is, as long as the clr input is 1, the value is pinned to 0, regardless of the clock input.
When the Appearance attribute is set to Logisim-evolution, the counter uses standard IEC/IEEE graphical symbols (IEC 617-12 and IEEE Std 91-1984). This appearance includes additional control pins and mode indicators:
| Symbol | Label | Function |
|---|---|---|
| G (or G5) | Count Enable | When high (1), counting is enabled. When low (0), the count is held regardless of clock pulses. |
| M1 | [load] | Load mode control. Activates loading from the Data input. |
| M2 | [count] | Count mode control. Activates counting operation. |
| M3 | [up] | Up-count control. Selects increment mode. |
| M4 | [down] | Down-count control. Selects decrement mode. |
| 2,3,5+/C6 | Clock+ | Clock input for specific mode combinations (with count enable active). |
| 2,4,5- | Clock- | Alternative clock input path for different operational modes. |
Note: The Logisim-evolution appearance may show duplicate clock and carry pins. These represent different operational modes of the counter according to the IEC/IEEE standard. The functionality is identical to the Classic appearance; only the graphical representation differs.
When the component is selected or being added,
Alt-0 through Alt-9 alter its Data Bits
attribute.
rising edgeindicates that the counter should update its value at the instant when the clock rises from 0 to 1. The
falling edgevalue indicates that it should update at the instant the clock falls from 1 to 0.
Clicking the counter brings keyboard focus to the component (indicated by a red rectangle), and typing hexadecimal digits will change the value stored in the counter.
Allows the label associated with the component to be edited.