firmware refactor, entropy added