traffic counting; TODO: split module