An alarm clock using the MAX7219 chip and a rotary encoder