; seperates a long string of bytes into their individual byte sections.
; Param: byteString[, unsettime]
; - byteString - Contains the string of bytes grouped together (ex: 0101101010100101)
; - unsetTime - (optional) unsets the %octet variables after the specified time in seconds
/octets {
var %pos = 1
/unset %octet.*
while ($mid($$1, %pos, 8)) {
/set $iif($2, $+(-u,$2)) %octet. [ $+ [ $floor($calc(%pos / 8)) ] ] $mid($$1, %pos, 8)
/inc %pos 8
}
return $floor($calc(%pos / 8))
}