| Electronic Components Datasheet Search |
|
AS3661 Datasheet(PDF) 70 Page - ams AG |
|
|
|||||||||||||||||||||||||||||
AS3661 Datasheet(HTML) 70 Page - ams AG |
|
70 / 87 page ![]() www.austriamicrosystems.com Revision 1.3 69 - 85 AS3661 Datasheet - D e t a i l e d D e s c r i p t i o n 8.12.2.1 RWV Application Example Let's say that the LED dimming is controlled according to the linear scale and effective PWM value at the moment t=0 is 0d (0%,) and we want to reach a PWM value of 255d (100%) at the moment t = 3s. The parameters for the RAMP instruction will be: Prescale = 0 (0.488 ms cycle time) Step time = 4 (use variable D in register 0x3C with a value of 24d) Sign = 0 (increase PWM output) Number of increments = 0 (use local variable A which must be loaded with the value 255d) COMPILER COMMAND SYNTAX EXAMPLE: RMP, 0, 0, 4, 0; The example above gives us a ramp time of 2.987s (tr = 0.488ms * 24 * 255). Figure 30. Ramp Instruction Example with Variables 8.12.3 SET PWM (Numerical Operands) This instruction is used for setting the PWM value on the outputs LED1 to LED9 without any ramps. Set PWM output value from 0 to 255 with PWM value bits [7:0]. Instruction execution takes sixteen 32 kHz clock cycles (=488µs) . COMPILER COMMAND SYNTAX: SPW, PWM Value[8]; # of increments 0-3 The number of increment/decrement cycles. Value is taken from variable defined below: 0 local variable A 1 local variable B 2 local variable C 3 register address 0x3C variable D value, or register address 0x42 value. Table 77. SPW Parameter Description Name Value Description PWM Value 0-255 PWM output duty cycle 0 - 100% Table 76. RWV Parameter Description Name Value Description |
|
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 |