add DM_back_side code and update front_side code