Texas Instruments | LP5569 Lighting Pattern Design | Application notes | Texas Instruments LP5569 Lighting Pattern Design Application notes

Texas Instruments LP5569 Lighting Pattern Design Application notes
Application Report
SNVA822 – May 2018
LP5569 Lighting Pattern Design
ABSTRACT
This application report describes how to design lighting pattern with LP5569 Programmable lighting engine
and provides examples of the fashion lighting pattern for the user.
1
2
3
4
5
Contents
Introduction ................................................................................................................... 1
Device Overview ............................................................................................................. 2
Lighting Pattern Design with LEDs on LP5569EVM .................................................................... 2
Lighting Pattern Design with LEDs on LP5569 Ring Demo ............................................................ 5
References .................................................................................................................. 14
List of Figures
1
LED Board Design ........................................................................................................... 5
2
Mono-Color Chasing Engine Code for 4 Devices ....................................................................... 7
3
Multi-Color Chasing Code for U1 and U2
4
5
6
7
................................................................................ 8
Multi-Color Chasing Code for U3 and U5 ................................................................................ 9
Door Open .................................................................................................................. 10
lasm.exe Path............................................................................................................... 11
Compile Panel in LP5569EVM GUI ...................................................................................... 12
List of Tables
1
LED and I2C Address Assignment ........................................................................................ 5
Trademarks
All trademarks are the property of their respective owners.
1
Introduction
This application report describes LP5559 lighting pattern design with examples for the device quick start.
Most of the programs are presented with command compiler syntax. The Command compiler is described
in The Control View - Source Edit Tab of Using the BOOST-LP5569EVM Evaluation Module. This
application report also includes LED ring Demo (click here) sample code in both command syntax and C
language. Command compiler software is available with the evaluation kit.
SNVA822 – May 2018
Submit Documentation Feedback
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
1
Device Overview
2
www.ti.com
Device Overview
The LP5569 device is a programmable, easy-to-use 9-channel I2C LED driver designed to produce
lighting effects for various applications. The LED driver is equipped with an internal SRAM memory for
user programmed sequences and three programmable LED engines, which allow operation without
processor control. Autonomous operation reduces system power consumption when the processor is put
in sleep mode.
3
Lighting Pattern Design with LEDs on LP5569EVM
The following lighting pattern is realized with white LEDs on LP5569EVM.
3.1
Bouncing Effect
This design is best viewed with 9 white LEDs on the LP5569EVM. This design has 4 white LEDs on at all
times. Each LED has different PWM settings to create two tracers bouncing back and forth.
; bouncing.src
L10:
L11:
L12:
L13:
L14:
L15:
L16:
L17:
L20:
L21:
L22:
L23:
L24:
L25:
L26:
L27:
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
dw
0000000000000001b
0000000000000010b
0000000000000100b
0000000000001000b
0000000000010000b
0000000000001000b
0000000000000100b
0000000000000010b
0000000100000000b
0000000010000000b
0000000001000000b
0000000000100000b
0000000000010000b
0000000000100000b
0000000001000000b
0000000010000000b
.segment
program1
map_start
L10
load_end
L17
;load the start address
;load the end address
loop1:
trigger
set_pwm
map_next
set_pwm
map_next
set_pwm
map_prev
wait
branch
end
.segment
program2
map_start
load_end
loop2:
trigger
set_pwm
map_next
set_pwm
map_next
set_pwm
map_prev
branch
end
.segment
end
2
s{2}
0
30
100
0.1
0, loop1
;wait time to create effect
L20
L27
;load the start address
;load the end address
w{1}
0
30
100
0, loop2
program3
LP5569 Lighting Pattern Design
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
Lighting Pattern Design with LEDs on LP5569EVM
www.ti.com
3.2
Breath_white Effect
This design is best viewed with 9 white LEDs on the LP5569EVM. This design has 3 group LED
breathing.
GRP1:
GRP2:
GRP3:
.segment
dw
0000000001001001b
dw
0000000010010010b
dw
0000000100100100b
program1
;Begin of a segment
map_addr
GRP1
set_pwm
00
loop1:
ramp
1, 100
ramp
1, -100
wait
0.3
branch
0, loop1
end
.segment
program2
;Begin of a segment
map_addr
GRP2
set_pwm
00
loop2:
ramp
1, 100
ramp
1, -100
wait
0.3
branch
0, loop2
end
.segment
program3
;Begin of a segment
map_addr
GRP3
set_pwm
00
loop3:
ramp
1, 100
ramp
1, -100
wait
0.3
branch
0, loop3
end
SNVA822 – May 2018
Submit Documentation Feedback
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
3
Lighting Pattern Design with LEDs on LP5569EVM
3.3
www.ti.com
Chaser Effect
This design is best viewed with 9 white LEDs on the LP5569EVM. This design has 3 white LEDs on at all
times. Each LED has different PWM settings to create a chaser (or tracer) effect.
; chaser.src
;
L00:
dw
L01:
dw
L02:
dw
L03:
dw
L04:
dw
L05:
dw
L06:
dw
L07:
dw
L08:
dw
L09:
dw
L10:
dw
L11:
dw
L12:
dw
L13:
dw
L14:
dw
L15:
dw
ALL:
dw
.segment
0000000000000001b
0000000000000010b
0000000000000100b
0000000000001000b
0000000000010000b
0000000000100000b
0000000001000000b
0000000010000000b
0000000100000000b
0000000010000000b
0000000001000000b
0000000000100000b
0000000000010000b
0000000000001000b
0000000000000100b
0000000000000010b
0000000111111111b
program1
map_addr
ramp
ramp
wait
map_start
load_end
ALL
0.5, 150
0.5, -150
0.2
L00
L15
;load the start address
;load the end address
loop1:
set_pwm
map_next
set_pwm
map_next
set_pwm
map_next
set_pwm
map_prev
map_prev
wait
branch
end
.segment
program2
end
4
0
5
50
150
0.07
0, loop1
;wait time to create effect
LP5569 Lighting Pattern Design
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
4
Lighting Pattern Design with LEDs on LP5569 Ring Demo
The LED ring is the latest HMI in the smart personal electronic device space and improves the user
experience. More and more appliance vendors are adopting this concept in next generation products. For
the appliance customer, the existing model with the existing MCU already meets system specification, but
the fancy lighting pattern will exhaust the system resources and potentially cause the MCU to crash. It is
requires a triple design circle to design complex lighting patterns without an engine control LED driver.
According to Figure 1 for LED board design, U1,U2,U3, and U5 drive 12 pcs RGB LED modules. The LED
mapping and I2C address assignments are shown as the Table 1.
Figure 1. LED Board Design
Table 1. LED and I2C Address Assignment
Device
I2C Address
Broadcasting I2C
Address
Channel Number of The
LED Driver
LED
U1
0x32H
0x40H
LED0, LED3, LED6
D1-B, D1-G,D1-R
U1
0x32H
0x40H
LED1, LED4, LED7
D2-B, D2-G,D2-R
U1
0x32H
0x40H
LED2,LED5, LED8
D3-B, D3-G,D3-R
U2
0x33H
0x40H
LED0, LED3, LED6
D4-B, D4-G,D4-R
U2
0x33H
0x40H
LED1, LED4, LED7
D5-B, D5-G,D5-R
U2
0x33H
0x40H
LED2,LED5, LED8
D6-B, D6-G,D6-R
U3
0x34H
0x40H
LED0, LED3, LED6
D7-B, D7-G,D7-R
U3
0x34H
0x40H
LED1, LED4, LED7
D8-B, D8-G,D8-R
U3
0x34H
0x40H
LED2,LED5, LED8
D9-B, D9-G,D9-R
U5
0x35H
0x40H
LED0, LED3, LED6
D10-B, D10-G,D10-R
U5
0x35H
0x40H
LED1, LED4, LED7
D11-B, D11-G,D11-R
U5
0x35H
0x40H
LED2,LED5, LED8
D12-B, D12-G,D12-R
SNVA822 – May 2018
Submit Documentation Feedback
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
5
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
Firstly, define the LED Mapping in the beginning of the engine coding as shown below.
row1:
dw
dw
dw
dw
dw
dw
dw
dw
dw
row7:
row8:
row9:
4.1
0000000001001001b
0000000010010010b
0000000100100100b
0000000011011011b
0000000110110110b
0000000101101101b
0000000111111111b
0000000001001001b
0000000010010010b
;Map
;Map
;Map
;Map
;Map
;Map
;Map
;Map
;Map
B LED = D1, D4, D7 on the eval. board.
G LED = D2, D5, D8 on the eval. board.
R LED = D3, D6, D9 on the eval. board.
BG LED on the eval. board.
GR LED on the eval. board.
RB LED on the eval. board.
all LEDs on the eval. board.
B LED = D1,D4,D7 on the eval. board.
G LED = D2,D5,D8 on the eval. board.
Breathing
During the breathing pattern, all LEDs fade in and out as the same color at the same rate, therefore all
devices should run the same engine code below.
.segment
loop1_0:
program1
;Program for engine 1.
map_start
load_end
row1
row7
;Map the first LED.
;End address of the mapping data table.
ramp
ramp
wait
ramp
ramp
wait
map_next
branch
map_addr
ramp
wait
wait
map_addr
ramp
ramp
ramp
ramp
map_addr
ramp
2, 200
2, -255
0.4
2, 200
2, -255
0.4
;Increase PWM
;Decrease PWM
;Wait for 0.4
;Increase PWM
;Decrease PWM
;Wait for 0.4
;Set the next
;Loop 6 time
loop1:
6
6,loop1
row8
1.5, 200
0.4
0.4
row9
3, 200
3, -255
3, 200
3, -255
row8
1.5, -255
0->78% in 2 second.
->0% in 2 seconds.
seconds.
0->78% in 2 second.
->0% in 2 seconds.
seconds.
row active in the mapping table.
;Increase PWM 0->78% in 1.5 second.
;Wait for 0.4 seconds.
;Wait for0.4 seconds.
;Increase
;Decrease
;Increase
;Decrease
PWM
PWM
PWM
PWM
0->78% in
->0% in 3
0->78% in
->0% in 3
3 second.
seconds.
3 second.
seconds.
;Decrease PWM ->0% in 1.5 seconds.
LP5569 Lighting Pattern Design
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
4.2
Mono-Color Chasing
The mono-color chasing pattern needs the devices to start execution with a specific sequence delay. Each
device has different code, as shown in Figure 2.
wait
ld
loop1_2: map_sel
set_pwm
map_sel
sub
set_pwm
map_sel
sub
set_pwm
add
wait
branch
branch
wait
map_addr
set_pwm
0.4
ra, 75
7
ra
4
ra, 20
ra
1
ra, 20
ra
ra, 20
0.03
63, loop1_2
10, loop1_2
0.1
row7
0
wait
ld
loop1_2: map_sel
set_pwm
map_sel
sub
set_pwm
map_sel
sub
set_pwm
add
wait
branch
branch
wait
map_addr
set_pwm
0.4
ra, 255
7
ra
4
ra, 20
ra
1
ra, 20
ra
ra, 20
0.03
63, loop1_2
3, loop1_2
0.1
row7
0
U1
U5
wait
ld
loop1_2: map_sel
set_pwm
map_sel
sub
set_pwm
map_sel
sub
set_pwm
add
wait
branch
branch
wait
map_addr
U2 set_pwm
0.4
ra, 135
7
ra
4
ra, 20
ra
1
ra, 20
ra
ra, 20
0.03
63, loop1_2
3, loop1_2
0.1
row7
0
wait
ld
loop1_2: map_sel
set_pwm
map_sel
sub
set_pwm
map_sel
sub
set_pwm
add
wait
branch
branch
wait
map_addr
set_pwm
0.4
ra, 195
7
ra
4
ra, 20
ra
1
ra, 20
ra
ra, 20
0.03
63, loop1_2
3, loop1_2
0.1
row7
0
U3
Figure 2. Mono-Color Chasing Engine Code for 4 Devices
SNVA822 – May 2018
Submit Documentation Feedback
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
7
Lighting Pattern Design with LEDs on LP5569 Ring Demo
4.3
www.ti.com
Multi-Color Chasing
The multi-color chasing pattern requires the devices to start execution with a specific sequence delay.
Each device has different code, as shown in Figure 3 and Figure 4.
.segment
loop2_3:
program2
wait
branch
map_clr
trigger
rst
trigger
map_addr
ramp
loop2_1:
wait
loop2_2:
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
branch
map_addr
set_pwm
loop2_3: wait
branch
map_clr
trigger
rst
0.08
2, loop2_3
U1
U2
.segment
s{3}
w{1}
row8
1, 200
0.08
2
200
0.08
5
200
0.08
8
200
0.08
2
0
0.08
5
0
0.08
8
0
0.08
3
200
0.08
6
200
0.08
9
200
0.08
3
0
0.08
6
0
0.08
9
0
0.08
63, loop2_2
row7
0
0.08
2, loop2_3
loop2_1:
loop2_2:
program2
trigger
map_addr
ramp
wait
branch
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
branch
map_addr
set_pwm
map_clr
trigger
rst
w{1}
row8
1, 200
0.08
3, loop2_1
2
200
0.08
5
200
0.08
8
200
0.08
2
0
0.08
5
0
0.08
8
0
0.08
3
200
0.08
6
200
0.08
9
200
0.08
3
0
0.08
6
0
0.08
9
0
0.08
63, loop2_2
row7
0
s{3}
s{3}
Figure 3. Multi-Color Chasing Code for U1 and U2
8
LP5569 Lighting Pattern Design
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
segment
loop2_1:
loop2_2:
program2
trigger
map_addr
ramp
wait
branch
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
branch
map_addr
set_pwm
map_clr
trigger
rst
.segment
w{1}
row8
1, 200
0.08
3, loop2_1
3
200
0.08
6
200
0.08
9
200
0.08
3
0
0.08
6
0
0.08
9
0
0.08
2
200
0.08
5
200
0.08
8
200
0.08
2
0
0.08
5
0
0.08
8
0
0.08
63, loop2_2
row7
0
s{3}
U5
loop2_1:
loop2_2:
loop2_3:
program2
trigger
map_addr
ramp
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
branch
map_addr
set_pwm
wait
branch
map_clr
trigger
rst
w{1}
row8
1, 200
0.08
2
200
0.08
5
200
0.08
8
200
0.08
2
0
0.08
5
0
0.08
8
0
0.08
3
200
0.08
6
200
0.08
9
200
0.08
3
0
0.08
6
0
0.08
9
0
0.08
63, loop2_2
row7
0
0.08
2, loop2_3
U3
s{3}
Figure 4. Multi-Color Chasing Code for U3 and U5
SNVA822 – May 2018
Submit Documentation Feedback
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
9
Lighting Pattern Design with LEDs on LP5569 Ring Demo
4.4
www.ti.com
Door Open
The door open pattern needs the devices to start execution with a specific sequence delay. Each device
has different code as shown in Figure 5.
loop1_8: wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
loop1_9: wait
branch
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
branch
map_clr
trigger
trigger
rst
0.4
1
200
0.05
4
200
0.05
7
200
0.05
6, loop1_9
0.4
7
0
0.05
4
0
0.05
1
0
0.05
63, loop1_8
loop1_8: wait
loop1_9: wait
branch
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
loop1_10: wait
branch
branch
map_clr
trigger
trigger
0.4
0.05
2, loop1_9
7
200
0.05
4
200
0.05
1
200
0.05
0.4
1
0
0.05
4
0
0.05
7
0
0.05
3, loop1_10
63, loop1_8
s{2}
w{3}
s{2}
w{3}
U1
U5
loop1_8: wait
loop1_9: wait
branch
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
loop1_10: wait
branch
branch
map_clr
U2 trigger
trigger
rst
0.4
0.05
2, loop1_9
1
200
0.05
4
200
0.05
7
200
0.05
0.4
7
0
0.05
4
0
0.05
1
0
0.05
3, loop1_10
63, loop1_8
loop1_8: wait
map_sel
U3 set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
loop1_9: wait
branch
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
map_sel
set_pwm
wait
branch
map_clr
trigger
trigger
rst
0.4
7
200
0.05
4
200
0.05
1
200
0.05
6, loop1_9
0.4
1
0
0.05
4
0
0.05
7
0
0.05
63, loop1_8
s{2}
w{3}
s{2}
w{3}
Figure 5. Door Open
10
LP5569 Lighting Pattern Design
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
4.5
Coding Tips
•
•
•
4.6
Use the branch instruction to synchronize multiple devices, as it guarantees all devices will be at the
same time scale and step.
Remember to clear the LED mapping with map_clr when using the same LED in the difference engine.
Use the appropriate variable (ra, rb, rc, rd) for the progressive increase or decrease operation.
Uploading The Program to SRAM
The compile tool (Lasm.exe) can be downloaded from the GUI package on ti.com. The command window
or GUI can be used to compile the .scr file.
Figure 6. lasm.exe Path
SNVA822 – May 2018
Submit Documentation Feedback
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
11
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
Figure 7. Compile Panel in LP5569EVM GUI
After the compiling, a .hex file will appear in the same folder as the .scr file.
00
00
74
3E
9D
91
90
84
4C
40
9D
46
46
74
40
9F
40
9D
4A
40
A5
A4
40
9D
00
00
00
00
00
00
00
00
12
49
92
00
C8
07
14
FF
60
00
C8
02
00
00
00
00
87
C8
06
00
00
05
01
FF
03
00
00
00
00
00
00
00
00
00
9C
9D
31
84
44
9F
9D
9F
46
40
A3
9D
9D
46
14
4A
40
9D
4A
9F
9D
46
40
00
00
00
00
00
00
00
00
92
00
80
FF
60
00
87
02
86
00
00
4F
04
01
00
C8
00
00
05
00
86
03
00
00
00
00
00
00
00
00
00
00
01
9C
A3
3E
9D
BF
14
92
40
9D
46
A8
40
40
A2
4A
9D
4A
40
9D
40
40
9D
46
00
00
00
00
00
00
00
00
24 00 DB 01 B6
86 28 C8 21 FF
02 9F 87 1E C8
C8 31 FF 9F 87
04 92 14 84 60
97 A1 97 4C 00
C8 74 00 9D 08
14 84 60 91 14
00 9F 87 14 C8
05 40 C8 46 00
00 9D 05 40 00
3E 9F 86 40 00
C8 46 00 9D 01
00 46 00 9D 04
54 9D 00 E0 04
00 A1 83 9D 03
09 40 C8 4A 00
00 9D 09 40 00
C8 4A 00 9D 08
05 40 00 4A 00
00 9D 00 E0 08
D7 46 00 9D 06
09 40 00 46 00
00 A4 94 A2 01
00 00 00 00 00
00 00 00 00 00
00 00 00 00 00
00 00 00 00 00
00 00 00 00 00
00 00 00 00 00
00 00 00 00 00
00 00 00 00 00
@ 09 program1
@ 77 program2
@ A6 program3
01
74
74
19
9D
9F
84
44
46
9D
46
74
40
40
E2
40
9D
4A
40
9D
00
40
9D
9D
00
00
00
00
00
00
00
00
6D
00
00
FF
01
86
60
00
00
08
00
00
C8
00
00
C8
03
00
C8
08
00
EB
06
00
00
00
00
00
00
00
00
00
01
28
74
74
92
40
9D
BF
A4
40
9D
9D
46
46
00
4A
40
9D
4A
40
E1
46
40
E0
00
00
00
00
00
00
00
00
FF
C8
00
00
14
00
05
AB
BC
C8
08
07
00
00
00
00
00
02
00
00
00
00
00
02
00
00
00
00
00
00
00
00
00
21
9F
90
84
74
92
A1
9D
46
40
40
A3
9D
E0
9D
4A
40
9D
4A
46
9D
46
00
00
00
00
00
00
00
00
00
LP5569 Lighting Pattern Design
49
FF
88
FF
60
00
14
AB
02
00
00
C8
5D
07
80
06
00
C8
02
00
00
09
00
00
00
00
00
00
00
00
00
00
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
Lighting Pattern Design with LEDs on LP5569 Ring Demo
www.ti.com
Then, copy the hex file to the array table and upload the data to the SRAM by the below coding.
void load_SRAM()
{
int i,j;
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE,0x40);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x2F);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x48);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x02);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x54);
//Device global
//send register
//send register
//send register
//send register
setting
address
data
address
data
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE, 0x32);
//load hex to SRAM in U1
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4b);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x09);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4c);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x78);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4d);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0xa8);
//send register data
for(j=0; j<16; j++)
{
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4F); //send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,j);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE,0x50); //send register address
for(i=0; i<32; i++)
MAP_I2C_masterSendMultiByteNext(EUSCI_B1_BASE,table_32[i+j*32]);//send register data
}
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE, 0x33);
//load hex to SRAM in U2
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4b);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x09);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4c);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x7b);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4d);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0xaa);
//send register data
for(j=0; j<16; j++)
{
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4F); //send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,j);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE,0x50); //send register address
for(i=0; i<32; i++)
MAP_I2C_masterSendMultiByteNext(EUSCI_B1_BASE,table_33[i+j*32]);//send register data
}
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE, 0x34);
//load hex to SRAM in U3
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4b);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x09);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4c);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x7b);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4d);
//send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0xab);
//send register data
for(j=0; j<16; j++)
{
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4F); //send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,j);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE,0x50); //send register address
for(i=0; i<32; i++)
MAP_I2C_masterSendMultiByteNext(EUSCI_B1_BASE,table_34[i+j*32]);//send register data
}
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE, 0x35);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4b);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x09);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4c);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x77);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4d);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0xa6);
SNVA822 – May 2018
Submit Documentation Feedback
//load
//send
//send
//send
//send
//send
//send
hex to SRAM in U5
register address
register data
register address
register data
register address
register data
LP5569 Lighting Pattern Design
Copyright © 2018, Texas Instruments Incorporated
13
References
www.ti.com
for(j=0; j<16; j++)
{
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x4F); //send register address
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,j);
//send register data
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE,0x50); //send register address
for(i=0; i<32; i++)
MAP_I2C_masterSendMultiByteNext(EUSCI_B1_BASE,table_35[i+j*32]);//send register data;
}
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE, 0x32);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x2F);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x49);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x3d);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x08);
MAP_I2C_setSlaveAddress(EUSCI_B1_BASE, 0x40);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x02);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0x00);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x02);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0xa8);
MAP_I2C_masterSendMultiByteStart(EUSCI_B1_BASE, 0x01);
MAP_I2C_masterSendMultiByteFinish(EUSCI_B1_BASE,0xa8);
}
5
//SET U1 as the
//send register
//send register
//send register
//send register
clk out
address
data
address
data
//Run all the engine
//send register address
//send register data
//send register address
//send register data
//send register address
//send register data
References
Using the BOOST-LP5569EVM Evaluation Module
LP5569 Nine-Channel I2C RGB LED Driver With Engine Control and Charge Pump
14
LP5569 Lighting Pattern Design
SNVA822 – May 2018
Submit Documentation Feedback
Copyright © 2018, Texas Instruments Incorporated
IMPORTANT NOTICE FOR TI DESIGN INFORMATION AND RESOURCES
Texas Instruments Incorporated (‘TI”) technical, application or other design advice, services or information, including, but not limited to,
reference designs and materials relating to evaluation modules, (collectively, “TI Resources”) are intended to assist designers who are
developing applications that incorporate TI products; by downloading, accessing or using any particular TI Resource in any way, you
(individually or, if you are acting on behalf of a company, your company) agree to use it solely for this purpose and subject to the terms of
this Notice.
TI’s provision of TI Resources does not expand or otherwise alter TI’s applicable published warranties or warranty disclaimers for TI
products, and no additional obligations or liabilities arise from TI providing such TI Resources. TI reserves the right to make corrections,
enhancements, improvements and other changes to its TI Resources.
You understand and agree that you remain responsible for using your independent analysis, evaluation and judgment in designing your
applications and that you have full and exclusive responsibility to assure the safety of your applications and compliance of your applications
(and of all TI products used in or for your applications) with all applicable regulations, laws and other applicable requirements. You
represent that, with respect to your applications, you have all the necessary expertise to create and implement safeguards that (1)
anticipate dangerous consequences of failures, (2) monitor failures and their consequences, and (3) lessen the likelihood of failures that
might cause harm and take appropriate actions. You agree that prior to using or distributing any applications that include TI products, you
will thoroughly test such applications and the functionality of such TI products as used in such applications. TI has not conducted any
testing other than that specifically described in the published documentation for a particular TI Resource.
You are authorized to use, copy and modify any individual TI Resource only in connection with the development of applications that include
the TI product(s) identified in such TI Resource. NO OTHER LICENSE, EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE TO
ANY OTHER TI INTELLECTUAL PROPERTY RIGHT, AND NO LICENSE TO ANY TECHNOLOGY OR INTELLECTUAL PROPERTY
RIGHT OF TI OR ANY THIRD PARTY IS GRANTED HEREIN, including but not limited to any patent right, copyright, mask work right, or
other intellectual property right relating to any combination, machine, or process in which TI products or services are used. Information
regarding or referencing third-party products or services does not constitute a license to use such products or services, or a warranty or
endorsement thereof. Use of TI Resources may require a license from a third party under the patents or other intellectual property of the
third party, or a license from TI under the patents or other intellectual property of TI.
TI RESOURCES ARE PROVIDED “AS IS” AND WITH ALL FAULTS. TI DISCLAIMS ALL OTHER WARRANTIES OR
REPRESENTATIONS, EXPRESS OR IMPLIED, REGARDING TI RESOURCES OR USE THEREOF, INCLUDING BUT NOT LIMITED TO
ACCURACY OR COMPLETENESS, TITLE, ANY EPIDEMIC FAILURE WARRANTY AND ANY IMPLIED WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT OF ANY THIRD PARTY INTELLECTUAL
PROPERTY RIGHTS.
TI SHALL NOT BE LIABLE FOR AND SHALL NOT DEFEND OR INDEMNIFY YOU AGAINST ANY CLAIM, INCLUDING BUT NOT
LIMITED TO ANY INFRINGEMENT CLAIM THAT RELATES TO OR IS BASED ON ANY COMBINATION OF PRODUCTS EVEN IF
DESCRIBED IN TI RESOURCES OR OTHERWISE. IN NO EVENT SHALL TI BE LIABLE FOR ANY ACTUAL, DIRECT, SPECIAL,
COLLATERAL, INDIRECT, PUNITIVE, INCIDENTAL, CONSEQUENTIAL OR EXEMPLARY DAMAGES IN CONNECTION WITH OR
ARISING OUT OF TI RESOURCES OR USE THEREOF, AND REGARDLESS OF WHETHER TI HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
You agree to fully indemnify TI and its representatives against any damages, costs, losses, and/or liabilities arising out of your noncompliance with the terms and provisions of this Notice.
This Notice applies to TI Resources. Additional terms apply to the use and purchase of certain types of materials, TI products and services.
These include; without limitation, TI’s standard terms for semiconductor products http://www.ti.com/sc/docs/stdterms.htm), evaluation
modules, and samples (http://www.ti.com/sc/docs/sampterms.htm).
Mailing Address: Texas Instruments, Post Office Box 655303, Dallas, Texas 75265
Copyright © 2018, Texas Instruments Incorporated
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Related manuals

Download PDF

advertising