not working. add table for periodic commands, refactored periodic commands