Freescale Semiconductor S08 manual PC Control Mode, 2. Firmware Flow PWM Adjustment

Models: S08

1 46
Download 46 pages 43.71 Kb
Page 24
Image 24
Figure 3-2. Firmware Flow: PWM Adjustment

Firmware Description

PWM value input to one channel

Auto White balance?

No

Yes

Prompt for green channel PWM input and calculate the two remaining channels’ PWM values according to existing color temperature

Get the other two channel values from user input

Adjust PWM width in next PWM cycle

Figure 3-2. Firmware Flow: PWM Adjustment

3.2 PC Control Mode

Every time the MCU is powered up, the firmware detects the status of SW1. The LED lighting control box is operated in PC control mode if SW1 is not being pressed.

In this mode, you control the LED output through the host PC. The MCU uses the serial communication interface (SCI) module to communicate to the COM port of the host PC.

After entering this mode, the MCU sends out a number of string characters to the PC COM port. These strings are the contents of the user interface menu displayed in the PC screen. This user interface menu guides you on how to control the LED box by different function keys. The MCU also sends out existing PWM control parameters to the host for display. For examples, parameters such as existing RGB PWM output values, white balance mode, and PWM frequency are displayed. Figure 3-3shows the PC screen for the user control menu.

LED Lighting Control using the MC9S08AW60, Rev. 1

24

Freescale Semiconductor

Page 24
Image 24
Freescale Semiconductor S08 manual PC Control Mode, 2. Firmware Flow PWM Adjustment