You are here: Foswiki>Software Web>AGW (16 Sep 2020, CarlHolmberg)Edit Attach

AutoGuider and Wavefront sensing units

The units are responsible for autoguiding and active optics control. They come in two flavours, from AIP (PEPSI, LUCI) and OSU (MODS). The units are controlled by GCS.


Incoming beam is picked up by the AGW pickup mirror. It passes through a filter wheel and is split on dichroic into guider and wavefront sensing parts. See PEPSI description for detailed schematics. Light is collected on AzCam controlled cameras.

Both AGW units consist of a guide camera and a camera with a Shack-Hartman sensor.


LUCI and PEPSI AGW motors are controlled by UMACs. OAC is responsible for fulfilling GCS position requests to LUCI/PEPSI AGWs by sending commands to UMACs.

MODS AGW motors are controlled by MODS mechanisms, using MicroLYNX -7 motor controllers. A MODS software library provides GCS the interface to send position requests to the MODS AGWs.

Understanding AGW coordinate system

AGW[1-4] comes in two flavors of the coordinate system. The primary is a Polar system, where the origin is placed at the origin of the R arm. The axis are referenced as Theta (Θ) for angle and R (for radius). These AGWs offer absolute and relative encoders for Θ axis and relative encoder for the R axis (so at least R axis really needs to be homed & referenced before you start to use the AGW, although Θ axis is moved to 0 angle at homing as well). The other coordinate system is Cartesian on the focal plane, with origin in the center of AGW (unit, not Θ) rotation (I am not sure about that - ask engineering/operations, JH, Barry, Olga). Transformation between Cartesian and Polar coordinates is performed in the UMAC software.


The MODS AGWs[5-6] offer just two Cartesian systems. PEPSI's bend AGWs[7-8] cannot move their axis, so only the CCD detector and focal plane coordinates are used.

Basic oacserver operations

Login as Then:
[oac@oac ~]$ ping<n>
PING<n> (<n>) 56(84) bytes of data.
64 bytes from<n>: icmp_seq=1 ttl=255 time=6.00 ms
[oac@oac ~]$ ping<n>
PING<n> (<n>) 56(84) bytes of data.
64 bytes from<n>: icmp_seq=1 ttl=255 time=6.00 ms
[oac@oac ~]$ stopAGW -u <n>
[oac@oac ~]$ startAGW -u <n>
[oac@oac ~]$ getdata -u <n>
general state:      0x201
general errors:          0
THETA state:        0x3
THETA errors:          0
R state:        0x3
R errors:          0
FOC state:        0x3
FOC errors:          0
FIL state:        0x3
FIL errors:          0
Home Status:       0x17
UMAC Power Status:          1
OAC Version:        5.0
UMAC Temp:         23 degC
Ambient Temp:          1 degC
UMAC Hum:         13 %RH
[oac@oac ~]$ home -u <n> -m21
[oac@oac ~]$ setxy -u <n> -x <x> -y <y>

replacing with AGW number (1,2...8). 0x3 in axis state means axis homed, 0x6 axis in movement, 0x0 axis not homed. Anything else than 0 in errors means problem on the axis and shall be investigated. Home status 0x17 means all axis homed. stop/startAGW turns off/on power for AGW UMAC (and AzCam controllers and computer). Sometimes needs to be repeated if the command ends with an error message, or OAC needs to be restarted.

If the OAC doesn't respond, try to restart OAC server:
[oac@oac ~]$ sudo /etc/init.d/oac stop
[oac@oac ~]$ sudo /etc/init.d/oac start

Direct interaction with UMAC

Those commands can be as well type into Terminal window in PeWin. See below why those are usefull.


# start homing on all axes
[oac@oac ~]$ pmacsend -u1 "M7100=1 M7101=1 M7102=1 M7103=1"
At 22:09:01

# check homing status. 23 = all homed (or 20 for AGW[78], as those are missing XY stage)
[oac@oac ~]$ pmacsend -u1 M7500 # 23 = 1 + 2 + 4 + 16
At 22:09:18


# values are in um (10-6 m, so take what you know from mm and * 1000)
# M7110 and M7111 are move triggers; if already set to 1, need to be set to 0 before moving
[oac@oac ~]$ pmacsend -u1 "M7115=50000 M7116=600000 M7110=1 M7111=1"
At 22:09:18

[oac@oac-dev ~]$ pmacsend -u1 "M7110 M7111 M7115 M7116"
At 22:09:01

Topic revision: r15 - 16 Sep 2020, CarlHolmberg
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback