Bug fixes and added freq module