  We present a model for the non-thermal radio emission from bright O stars, in
terms of synchrotron emission from wind-embedded shocks. The model is an
extension of an earlier one, with an improved treatment of the cooling of
relativistic electrons. This improvement limits the synchrotron-emitting volume
to a series of fairly narrow layers behind the shocks. We show that the width
of these layers increases with increasing wavelength, which has important
consequences for the shape of the spectrum. We also show that the strongest
shocks produce the bulk of the emission, so that the emergent radio flux can be
adequately described as coming from a small number of shocks, or even from a
single shock.
  A single shock model is completely determined by four parameters: the
position of the shock, the compression ratio and velocity jump of the shock,
and the surface magnetic field. Applying a single shock model to the O5 If star
Cyg OB2 No. 9 allows a good determination of the compression ratio and shock
position and, to a lesser extent, the magnetic field and velocity jump.
  Our main conclusion is that strong shocks need to survive out to distances of
a few hundred stellar radii. Even with multiple shocks, the shocks needed to
explain the observed emission are stronger than predictions from time-dependent
hydrodynamical simulations.
