src/busylight.cpp
// Calculates the PWM value for the RGB LED, taking into account Anode/Cathode
Calculates the PWM value for the RGB LED, taking into account Anode/Cathode
Calculates the PWM value for the RGB LED taking into account Anode / Cathode
int RGB_calc(int value) {
  #if LED_TYPE == 0
  return PWM_MAX_VALUE - ((value / 255.f) * PWM_MAX_VALUE);
  #else
  return (value / 255.f) * PWM_MAX_VALUE;
  #endif
}
int RGB_calc ( int value ) { #if LED_TYPE == 0 return PWM_MAX_VALUE - ( ( value / 255.f ) * PWM_MAX_VALUE ) ; #else return ( value / 255.f ) * PWM_MAX_VALUE ; #endif }
Calculates the PWM value for the RGB LED, taking into account Anode/Cathode
Calculates the PWM value for the RGB LED taking into account Anode / Cathode