Bits from a stream



I'm currently trying to figure out how bits work in CL. From what I've
dredged through the Hyperspec, bits are integers/unsigned bytes of
width 1. I would like to know how I should handle them - do I handle
them as if they were ordinary integers, just having a significantly
reduced range? Googling "bits common lisp" and "bit common lisp"
doesn't seem to give me useful information ("32 bit and 64 bit versions
of Common Lisp"...).

Basically I need to do some compression on some data I'm storing - the
way I keep my data is rather amenable to compression, but compressing
it requires access to individual bits. I would like to store and
retrieve data from a file, so I will need access to bits in a stream.

So, first I'd like to know if there already exists such a function.
Basically I have a bit of lisp-pseudocode for such a hypothetical
function:
(let
(
(bitn 0)
(byte 0))
(defun read-bit-reset ()
(setf bitn (setf byte 0)) )
(defun read-bit (stream)
(when (zerop bitn)
(setf bitn 8)
(setf byte (read-byte stream)) )
(prog1 (logical-and byte 1) #|erk. what's the logical
(bitwise) and?|#
(setf byte (right-shift byte 1)) #|la la la la la... what's
shift?|#
(decf bitn) )))

Okay, so maybe I'll dredge through the hyperspec and figure out what
names CL gives to bitwise or/and and bit shifting. But first, is there
already such a function? Thanks!

.