mirror of
https://github.com/xodio/xod.git
synced 2026-03-04 07:54:04 +01:00
title
| title |
|---|
| Logic Nodes |
#16. Logic Nodes
Note
This is a web-version of a tutorial chapter embedded right into the XOD IDE.
To get a better learning experience we recommend to install the
desktop IDE or start the
browser-based IDE, and you’ll see the same tutorial there.
Boolean values are cool. You can use them to construct complex logic systems.
In XOD, you will find a lot of nodes for this purpose. All of them are located
in xod/core.
andreturnstrueif both inputs (IN1andIN2) aretrueorreturnstrueifIN1,IN2, or both aretruexorreturnstrueif only one ofIN1andIN2istruenotinverts the input valuenandis an invertedandnoris an invertedor
Test circuit
↓ Download as a Fritzing project
In the example patch above the and node returns false until both buttons
are pressed. The not node inverts the value from the and node, so the LUM
pin receives its true value (1). Thus, the LED turns on.
Pressing one of the buttons changes nothing. The LED will turn off only when
the LUM pin receives false (0). This will happen only if the not node
receives the true value, which is possible only if both buttons are pressed at
the same time.

