Add Scanner class, improve time module, add new tests, fixes