How can I change the amplitude of a pwm signal ?

If you use a h-bridge driver chip designed for 3-phase motors you eliminate the need to send complicated sine waves to the motor. Something like the TI DRV8313 is controlled solely through three sets of digital signals (look at the control waveforms in the datasheet). One of which (for each phase) can be a PWM signal to control the motors speed.

and the datasheet