Text this: Canonical equations for a constrained mechanical system