Byte Manipulation with ldb
USER(1): (setq flags #b111000111)
USER(2): (ldb (byte 4 0) flags)
#b0111 ; lowest (rightmost) four bits
USER(3): (ldb (byte 4 4) flags)
#b1100 ; next four bits
USER(4): (ldb (byte 8 0) flags)
#b11000111 ; lowest eight bits
Previous slide
Next slide
Back to first slide
View graphic version