Direct measurement of the top quark mass in $p\bar p$ collisions at D0