Working implementation of reader thread

Signed-off-by: Lasse Bigum <lasse@bigum.org>