Added tonegenerator class