implemented falling endge trigger in refeactored output mag, put the hooks in for output mag torque monitoring, added in checking initial parameters