  Aims: Ices in dense star-forming cores contain the bulk of volatile molecules
apart from H2 and thus represent a large fraction of dark cloud chemistry
budget.To directly constrain the freeze-out profile of CO, the formation route
of CO2 and the carrier of the 6.8 micron band, the spatial distribution of the
CO/CO2 ice system and the 6.8 micron band carrier are measured in a nearby
dense core.
  Methods: VLT-ISAAC, ISOCAM-CVF and Spitzer-IRS archival mid-infrared (3-20
micron) spectroscopy of young stellar objects is used to construct a map of the
abundances of CO and CO2 ices in the Oph-F star-forming core, probing core
radii from 2 10^3 to 14 10^3 AU or densities from 5 10^4 to 5 10^5 cm^-3 with a
resolution of ~ 3000 AU.
  Results: The line-of-sight averaged abundances relative to water ice of both
CO and CO2 ices increase monotonously with decreasing distance to the core
center. The map traces the shape of the CO abundance profile between freeze-out
ratios of 5-60% and shows that the CO2 ice abundance increases by a factor of 2
as the CO freezes out. It is suggested that this indicates a formation route of
CO2 on a CO ice surface to produce a CO2 component dilute in CO ice, in
addition to a fraction of the CO2 formed at lower densities along with the
water ice mantle. It is predicted that the CO2 bending mode band profile should
reflect a high CO:CO2 number ratio in the densest parts of dark clouds. In
contrast to CO and CO2, the abundance of the carrier of the 6.8 micron band
remains relatively constant throughout the core. A simple freeze-out model of
the CO abundance profile is used to estimate the binding energy of CO on a CO
ice surface to 814+/-30 K.
