User Tools

Site Tools


You are not allowed to perform this action
commands:led

Command:LED

On Tiger with Two Axis Card
Format [Addr#]LED X=[1 to 100]
Type Percentage between 0 and 100
Remembered Using [Addr#]SS Z
Firmware Required PWM_LED_DIM

Sets the brightness of ASIs LED illuminator by generating PWM thru TTL out. TTL out mode should be set to ‘9’ (i.e. TTL y=9). Enable out from the LED illuminator should be connected to TTL out on controller. This setting can be saved in non-volatile memory using the SAVESET command. The PWM frequency is 1.3KHz. It’s a Card-Addressed command.

The LED command has a slightly different format on a TGLED card. Refer to TGLED card user guide for more details.

NOTE: If you are encountering flickering, try adjusting your shutter speed to integer multiples of the PWM period (0.77 ms).

On Tiger and TGLED card
Format [Addr#]LED X=[1 to 100] Y=[1 or 100] Z=[1 or 100] F=[1 or 100]
Type Percentage between 0 and 100
Remembered Using [Addr#]SS Z

This command is “recycled” for a slightly different use in TGLED than for other cards . In the context of a TGLED card this command is used to set the individual brightness percentage of the LEDs connected to the card. Setting the brightness to 0% results in LED to be off. Setting the brightness to 50% results the in the LED being driven with PWM with 50% duty cycle. Setting the percentage to be 100% results in the LEDs to turn on fully.

X sets the brightness for LED connected to channel 1, Y sets the brightness for LED connected to channel 2, Z sets the brightness for LED connected to channel 3, and F sets the brightness for LED connected to channel 4.

Default is 50.

Example

1LED X=10 Y=50 F=0 
:A

Sets the Brightness of LED connected to Channel #1 to be 10% , Channel #2 to be 50% and Channel #4 to OFF. Brightness of Channel #3 will be unchanged.

1LED X? Y? Z? F?		 
X=10 Y=50 Z=50 F=0 :A

Queries the card for Brightness of LEDs connected to Channel #1,#2,#3 and #4

On Tiger with Micro-mirror card
Format [Addr#]LED X=[output] Y=[switich_time] Z=[laser_mode] R=[Side0_state] T=[Side1_state]
Type Integer (see below)
Remembered Using [Addr#]SS Z
Firmware Required MM_LASER_TTL

The LED commands are used to control the laser outputs of the card (Micro-mirror card backplane connectors, usually output by the Programmable Logic Card or TTL card in early versions). The origin of these commands was for MM_SPIM firmware, but a separate define MM_LASER_TTL was created so that it could be used in other situations as well. This documentation for v2.88+, though the Y parameter was added ~v2.86. In general these only apply when the auxiliary TTL output mode is set to 1 (TTL T) and when the SPIM state machine is not running.

output (X) selects which logical laser is on when the SPIM state machine is not running. The exact hardware output depends on bits 0-2 of the LED Z setting. X=0 means neither laser is on, X=1 means the Side0 laser is on, X=2 means the Side1 laser is on, and X=3 means both lasers are on (LED Y setting applies in this case). Requires TTL T (aux_IO_mode) setting to be 1. Setting is overridden during SPIM state machine operation.

switch_time (Y) sets the switching time in ms between the laser outputs when the SPIM state machine is not running and when both lasers are active per the LED X command. Used to simulate the effect of a passive 50/50 beam splitter, which is particularly useful during alignment. Default is 10ms, cannot be set less than 1ms.

laser_mode (Z) determines the behavior of the laser TTL outputs, both when using the LED settings and also during the SPIM state machine.

  • Bits 0-2 form a code 0-7 selecting how the logical laser outputs are converted to physical TTL outputs. Setting should correspond to the physical hardware connected to the laser TTL outputs. Specifically
    • code 0 for individual laser shutters for the two sides (default until v3.01)
    • code 1 for single laser with side switch (Side0 is laser shutter for both sides and Side1 is high when the second side is active) (default v3.01+)
    • code 2 for Side0 high when the first side of SPIM is active, Side1 high when the second side of SPIM is active
    • code 3 for single laser (Side0) automatically turned on during a FAST_CIRCLES move
    • codes 4-7 are reserved for future use
  • Bits 3-7 are reserved for future use and currently cannot be set

Side0_state (R) can be set to 1 or 0 as shorthand for turning on/off the Side0 laser without affecting the state of the Side1 laser. It is equivalent to querying the logical laser output state (X), changing the LSB, and then setting the output state (X). Introduced in v3.11.

Side1_state (T) can be set to 1 or 0 as shorthand for turning on/off the Side1 laser without affecting the state of the Side0 laser. It is equivalent to querying the logical laser output state (X), changing the 2nd bit, and then setting the output state (X). Introduced in v3.11.

On MS2000 or RM2000
Format LED X=[1 to 100] Y=[0 or 1] Z=[0 or 1] F=[0 or 1]
Type Percentage between 0 and 100
Remembered Using SS Z
Firmware Required LED DIMMER

X argument sets the brightness of ASIs LED illuminator by generating PWM thru TTL out. TTL out mode should be set to ‘9’ (i.e. TTL y=9). Enable out from the LED illuminator should be connected to TTL out on controller. This setting can be saved in non-volatile memory using the SAVESET command.

If you encountering flickering in a live image, try adjusting your shutter speed to avoid aliasing with the LED PWM frequency.

Y, Z, and F arguments provide on/off control for additional LED lamp connectors on some controllers. Not PWM dimmable.

On MS2000 with Dual LED
Format LED X=[0 to 100] Y=[0 or 100] R=[0 or 100] T=[0 or 100]
Type Percentage between 0 and 100
Remembered Using SS Z
Firmware Required DUAL_LED

Dual LED is a new two LED driver for MS2000. Instead of using PWM to dim the LED, DUAL LED varies the current applied to dim the LEDs resulting in very little flicker even at high shutter speeds. The brightness of the two LEDs can be independently set using the X and Y arguments of the LED command. At 100% brightness about 900ma is applied. Dual LED have a current limiting feature, user can set the maximum allowed brightness of the two LEDs with R and T arguments. This setting is saved in a non volatile memory on the PCB , so this setting is preserved even after firmware upgrade. Say a LED with maximum rated current is 100ma attached to channel 1. Then setting LED R=10 will limit the maximum applied current to 90ma.

X sets the brightness for LED connected to channel 1,
Y sets the brightness for LED connected to channel 2,
R sets the maximum brightness for LED connected to channel 1, and
T sets the maximum brightness for LED connected to channel 2.

Example

LED X=10 Y=50
:A

Sets the Brightness of LED connected to Channel #1 to be 10% , Channel #2 to be 50% .

LED X? Y? 
X=10 Y=50 :A

Queries the card for Brightness of LEDs connected to Channel #1,and #2.

LED R=10 
:A
LED X=50 
:A
LED X?
X=10 :A

User sets the maximum brightness of LED#1 to 10%. If the user tries to increase the brightness beyond 10%, its overwritten by maximum brightness settings and limited to 10%.

Address: 29391 W Enid Rd. Eugene, OR 97402, USA | Phone: +1 (541) 461-8181
commands/led.txt · Last modified: 2019/04/18 23:33 (external edit)