Index

Boolean focus_acquired()

Return the status of the latest set-focus command.

Arguments:
(none)

Example:
The following example tells the control system to set the focus position to 10mm, with a 0.5 mm precision. It then waits for the control system to indicate when the focusing operation completes. Then, if the focus_acquired() function indicates that the specified position was not acquired, it tries again, this time with a lower precision.
 set_focus 10, 0.5
 until $acquired(focus)
 if(!$focus_acquired()) {
   print "Trying again with less focusing precision"
   set_focus 10, 1.0
 }

Context:
If the precision or position passed to the set_focus() command are unobtainable, the focusing procedure eventually gives up trying. The focus_acquired() function can be used to determine whether it succeded or failed.

Martin Shepherd (25-Mar-2010)