gweimer/utils@0.2.5

General Utilities. Updated for XOD v0.28.x (makes queue-buffer pins generic); add 'all' node
NodeDescription
all
Like 'any' node, but all pins must be pulsed instead of any pin.
bits-to-byte
Convert 8 BITS into a BYTE. No input validation is done & assumes each input is 0 or 1.
byte-to-bits
Convert a BYTE into its individual BITS. No input validation is done and assumes a number between 0 and 255.
cast-number-to-hex-string
Convert NUM to a HEX string with "0x" prefix and a minimum of DIG digits (use leading 0's to fill).
hex-to-number
Convert a hex string (with leading 0x) into a number. A negative output indicates position of error on invalid input string.
if-else-v
Return T associated with last COND that is True, or return F if no COND is True.
queue-buffer
Buffer for implementing queue with PUSH/POP functionality. Must be daisy-chained to create queue of fixed depth.
running-avg
Calculate a running AVG. Variadic is dummy pin to select # of values to AVG. Unlabelled pins are for internal use only.
utils-example-allNo description
utils-example-avg
Example/test using running-avg node
utils-example-bits
Example/test using bits-to-byte and bytes-to-bits nodes
utils-example-hex
Example/test using cast-number-to-hex-string and hex-to-number nodes
utils-example-if-else
Example/test using if-else-v node
utils-example-queue
Example/test using queue-buffer with both push & pop functions
To use the nodes in your project you should have the gweimer/utils library installed. Use the “File → Add Library” menu item in XOD IDE if you don’t have it yet. See Using libraries for more info.