Keating, Thomas, active 1764-1813, Lieutenant-Colonel