check all connections. Very common for them to become corroded, dirty, etc. There are SEVERAL connectors in the wiring harness that can give issues, and one is a bear to access (under the steering pedestal). If all good, check (and clean) the ground wire from battery to frame, then make sure the engine's grounded from engine to frame as well. If that's ok, look real close at the battery. If the battery is not held into the tray, it rattles around and will contact the muffler heat shield, and cause all sorts of issues.
Last resort is the combination box. There is some reference to 'repairing' it...though I've not had any luck. I have a stash of 2 or 3 of 'em and if I have a tractor in the shop that exhibits issues, and all else is "ok", I'll plug my "test box" into it. My test box is a potted box; no way to repair anything BUT I do think that some of the early boxes had a circuit board that was repairable. I just haven't seen one yet.