adapted to new dmmodule.h