XMC1300 LED Current Control Explorer - Example A3
Open online SPICE simulator circuit link: lighting_led_24V_LED_CC_EXP_XMC1302_A3.tsc
XMC LED Current Control Explorer - Example A3
HUMAN EYE
COMPARATOR REFERENCE
OUTPUT STAGE
VDC IN
How to program the microcontroller:
1. Build project in DAVE
2. Pack together the .hex and .elf files into a .zip
(usually found in the Debug folder)
3. Click on the microcontroller symbol
4. Click on the "MCU-code" details
5. Select "Upload"
6. Select the .zip file created earlier
7. Click "Upload"
8. Click "OK"
This example demonstrates modulated peak-current control on one LED channel,
based on the DAVE project "LED_CCEXP_A3_ACMP_BCCU_CCU4".
The following code lines have been changed to speed up initialization, simplify
potentiometer behavior, and show internal signals:
(line 62) #define OFFTIME (0xB)
(line 63) #define WALKTIME (0x0)
(line 89) .fclk_ps = 0x60,
(line 255) XMC_GPIO_SetMode(P0_7, XMC_GPIO_MODE_OUTPUT_PUSH_PULL_ALT1);
(line 276) dimlevel = potresult;
Product info: XMC1302-T038F0200 AB
Reference manual: XMC1300 AB-Step
Evaluation board: XMC LED Current Control Explorer
DAVE code: LED_CCEXP_A3_ACMP_BCCU_CCU8
Development platform: DAVE™
Other circuits