Well first up .... welcome to X world 69!!
The idiot lite should come on, everytime when starting..... as a test. If I remember a couple others should too. And then go out once started.
There is a "check engine lite" which I think is what you are refering to (looks like an oil can??). There is also a yellow or red "battery" lite that also should go out immediately once started.
I don't know how old your battery was when it failed. But I can give you directions for testing the charging system. I'm seeing normal battery life with OEM style batteries between 5-10 years. Of course there are extreme examples.
Test your volt regulator.... get to your battery or smart charger connection (if you have one). Start the bike, and put a volt meter on the battery/smart charger connection. Crank over to DC volts on your meter. It should read at minimum, 12.7 volts... I'd prefer 13 volts. Rev briefly if needed.
If it isn't reading that high, we'll need to test stator next.
Down by the toe shifter inside the frame rails is the volt regulator, an electrical looking device mounted on the engine case. There will be 2 connectors, one goes to battery (red and black wires) and other goes to stator (alternator, 3 black wires). Unhook the stator connector. Put your volt meter probes in ANY 2 of the 3 slots from the stator (NOT THE REGULATOR END). Start bike, and TURN your volt meter to AC volts. With roughly 2000 rpm's it should be reading 50 volts ac on ANY 2 of the 3 plugs/holes/slots. Test all 3 slots with each other. All 3 phases have to be charging 50 volts ac.
If this test shows 50 volts ac, at all 3 places, your stator is GOOD. And you'll only need to replace the volt regulator (they are pretty bullet proof, so I'd doubt it will be the regulator, but we have to prove that it isn't in trouble).
If you aren't getting 50 volts ac on all 3 phases of the stator, it is burned up (or possibly wire issue from the stator to the regulator, doubtful). And you'll need to replace it.
Don't think your X a being a special case burning up the stator. Its fairly common, especially now with the age of our bikes.
I'm part of a small group in the community that believes our stator issue is due to the "shunt type" voltage regulator and the heat it creates in operation. Here on this site without much "searching", you can find out how to replace your volt regulator with a "shuntless" system, for a reasonable price.
I can talk you thru it here, how to replace your stator, or you can visit my youtube channel, and watch how its done.
"Grandpa Grumpy Pants X World". There are also other X owners on youtube replacing stators, if you need variety (automotive villiany, 2 cool wheels, superX400).
Lemme know how you want to do it..... Greg or I are both willing to help.
Bruce Whitefoot
AKA Grandpa Grumpy Pants
flatlandersupportingXworld