ragav4456
Full Member level 4
Hi friends
I need to vary pwm duty cycle in 0 to 255(50khz). but 50khz resolution is 8.64 bits(0 to 398).
i need scale the value 0 to 398 into 0 to 255? How to scale the values?
input data 255=398/1.56 ;
correct or not? how to use float value?
____________________
Hitech C compiler
I need to vary pwm duty cycle in 0 to 255(50khz). but 50khz resolution is 8.64 bits(0 to 398).
i need scale the value 0 to 398 into 0 to 255? How to scale the values?
input data 255=398/1.56 ;
correct or not? how to use float value?
____________________
Hitech C compiler