using pulse-height modulation using pulse-width modulation