| Electronic Components Datasheet Search |
|
LP55231 Datasheet(PDF) 40 Page - Texas Instruments |
|
|
|
|||||||||||||||||||||||||||||
LP55231 Datasheet(HTML) 40 Page - Texas Instruments |
|
40 / 53 page ![]() LP55231 SNOSCR5 – MARCH 2013 www.ti.com Programming ramps with variables is very similar to programming ramps with numerical operands. The only difference is that step time and number of increments are captured from variable registers, when the instruction execution is started. If the variables are updated after starting the instruction execution, it will have no effect on instruction execution. Again, at each ramp step the output is incremented/decremented by one unless increment is 0. Time span for one step is defined with prescale and step time bits. Step time is defined with variable A, B, C or D. Variables A, B and C are set with ld-instruction. Variable D is a global variable and can be set by writing the VARIABLE register (address 3C). LED TEST ADC register (address 42) can be used as a source for the variable D, as well. Note: Variable A is the only local variable which can be read throughout the serial bus. Of course, the variable stored in 3CH can be read (and written), too. Setting register 06H, 07H, or 08H bit LOG_EN high/low sets logarithmic (1) or linear ramp (0). By using the logarithmic ramp setting the visual effect appears like a linear ramp, because the human eye behaves in a logarithmic way. Name Value (d) Description 0 Divides master clock (32.7 kHz) by 16 = 2048 Hz -> 0.488 ms cycle time prescale 1 Divides master clock (32.7 kHz) by 512 = 64 Hz -> 15.625 ms cycle time 0 Increase PWM output sign 1 Decrease PWM output step time(1) 1 - 31 One ramp increment done in (step time) x (prescale). # of The number of increment/decrement cycles. Note: Value 0 takes the same time as increment by 1, but 0 - 255 increments(2) it is the wait instruction. One ramp increment done in (step time) x (prescale). Step time is loaded with the value (5 LSB bits) of the variable defined below. 0 = local variable A step time(3) 0 - 3 1 = local variable B 2 = global variable C 3 = register address 3CH variable D value, or register address 42H value. The value of the variable should be from 00001b to 11111b (1d to 31d) for correct operation. The number of increment/decrement cycles. Value is taken from variable defined below: 0 = local variable A # of 0 - 3 1 = local variable B increments(3) 2 = global variable C 3 = register address 3CH variable D value, or register address 42H value. (1) Valid for numerical operands. (2) Valid for numerical operands. (3) Valid for variables. RAMP Instruction Application Example Suppose that the LED dimming is controlled according to the linear scale and effective PWM value at the moment t=0 is 140d (~55%,), as shown in the figure below, and we want to reach a PWM value of 148d (~58%) at the moment t = 1.5s. The parameters for the RAMP instruction will be: • Prescale = 1 → 15.625 ms cycle time • Step time = 12 → step time span will be 12*15.625 ms = 187.5 ms • Sign = 0 → increase PWM output • # of increments = 8 → take 8 steps 40 Submit Documentation Feedback Copyright © 2013, Texas Instruments Incorporated Product Folder Links: LP55231 |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |