Update wave_generator.c