Database CREATE TABLE status (id integer primary key, timestamp datetime, door_open integer); CREATE TABLE messages (id integer primary key, timestamp datetime, message text);