Electronic Components Datasheet Search
  English  ▼

X  

AS3661 Datasheet(PDF) 71 Page - ams AG

Part # AS3661
Description  Programmable 9-channel LED Dr iver
PDF  87 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  AMSCO [ams AG]
Direct Link  http://www.ams.com
Logo AMSCO - ams AG

AS3661 Datasheet(HTML) 71 Page - ams AG

Back Button AS3661 Datasheet HTML 67Page - ams AG AS3661 Datasheet HTML 68Page - ams AG AS3661 Datasheet HTML 69Page - ams AG AS3661 Datasheet HTML 70Page - ams AG AS3661 Datasheet HTML 71Page - ams AG AS3661 Datasheet HTML 72Page - ams AG AS3661 Datasheet HTML 73Page - ams AG AS3661 Datasheet HTML 74Page - ams AG AS3661 Datasheet HTML 75Page - ams AG Next Button
Zoom Inzoom in Zoom Outzoom out
 71 / 87 page
background image
www.austriamicrosystems.com
Revision 1.3
70 - 85
AS3661
Datasheet - D e t a i l e d D e s c r i p t i o n
8.12.3.1 SPW Application Example
The SPW command can be used to set the PWM duty cycle of the program execution engine. In the following example
we want to set the duty cycle of the PWM output to 55% like in the ramp example in the previous section. The right
PWM value can be calculated with the following formula:
PWM value = (Duty Cycle * 255 / 100) = 55% * 255 / 100 = 140.
The predefined PWM value can be used as a starting point for dimming LEDs for example.
COMPILER COMMAND SYNTAX: SPW, 140;
8.12.4 SET PWM (Variables)
This instruction is used for setting the PWM value on the outputs LED1 to LED9 without any ramps. In comparison to
the SPW command, this command is in combination with variables similar to the RWM example in one of the previous
sections.
COMPILER COMMAND SYNTAX: SPV, Variable[2];
8.12.4.1 SPV Application Example
The purpose of the SPV command is basically the same one like with the SPW command in the previous section. The
only difference is that this command allows the user the control the PWM duty cycle with the variables of the chip.
COMPILER COMMAND SYNTAX EXAMPLE: SPW, 0;
The example above shows the control of the duty cycle with the local variable A. If the local variable is for example
loaded with a value of 100, the duty cycle of the PWM output is set to 39.2%.
8.12.5 WAIT
When a wait instruction is executed, the engine is set in a wait status and the PWM values on the outputs are frozen.
This can be used for example to keep the LEDs enabled for a certain period of time before another up/down dimming
process is being initiated.
COMPILER COMMAND SYNTAX: WAIT, prescale[1], time[5];
8.12.5.1 WAIT Application Example
In the example shown below we want to have a target wait time of 125ms after dimming up the LEDs. In order to get
the 100ms delay we select a prescaler value “1”, which gives a cycle time of 15.625ms. If we divide the 100ms by the
cycle time we get the right value for the time parameter which is 8.
COMPILER COMMAND SYNTAX EXAMPLE: WAIT, 1, 8;
Table 78. SPW Parameter Description
Name
Value
Description
Variable
0-3
0
local variable A
1
local variable B
2
global variable C
3
register address 3CH variable D value, or register address 42H value.
Table 79. WAIT Parameter Description
Name
Value
Description
Pre-scale
0
Divide master clock (32 768 Hz) by 16 which means 0.488 ms cycle time.
1
Divide master clock (32 768 Hz) by 512 which means 15.625 ms cycle time.
time
1-31
Total wait time will be = (time) x (prescale). Maximum 484 ms, minimum 0.488 ms.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87


Datasheet Download

Go To PDF Page


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


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
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