  This article describes the implementation of a focal plane based wavefront
control loop on the high-contrast imaging instrument SCExAO (Subaru
Coronagraphic Extreme Adaptive Optics). The sensor relies on the Fourier
analysis of conventional focal-plane images acquired after an asymmetric mask
is introduced in the pupil of the instrument. This absolute sensor is used here
in a closed-loop to compensate the non-common path errors that normally affects
any imaging system relying on an upstream adaptive optics system.This specific
implementation was used to control low order modes corresponding to eight
zernike modes (from focus to spherical). This loop was successfully run on-sky
at the Subaru Telescope and is used to offset the SCExAO deformable mirror
shape used as a zero-point by the high-order wavefront sensor. The paper
precises the range of errors this wavefront sensing approach can operate within
and explores the impact of saturation of the data and how it can be bypassed,
at a cost in performance. Beyond this application, because of its low hardware
impact, APF-WFS can easily be ported in a wide variety of wavefront sensing
contexts, for ground- as well space-borne telescopes, and for telescope pupils
that can be continuous, segmented or even sparse. The technique is powerful
because it measures the wavefront where it really matters, at the level of the
science detector.
