1. Change the sampling freq
2. some minor refactor