Feature Overview
BUNPACK() slice the value with bit width.
- By specifying the argument after [number w], a value of up to 32 bits can be sliced.
- By setting [number s] to a negative value, bit slice can be started from the decimal point.
- This function consumes 30 Token.
a,b=bunpack(0xf8,4,4,4) -- Value, First bit-shift, bit-width, ...[bit-width] ?a -- 15 (0xf) ?b -- 8 (0x8) |
This function is included in the KNUTIL library.
release note
P#121616 2022-11-30 12:12 ( Edited 2022-12-02 15:17)
[Please log in to post a comment]