Is it while riding for 40 min, or the bike just sitting for 40 min with the engine off?
How about disconnecting a fully charged battery, waiting for a few hours, then re-connecting, and starting the bike? If a fully charged battery can't hold a charge for a few hours - junk it. If the bike starts right up, then you've got charging issues.
My voltage regulator gradually went bad and wasn't charging well. I bought an aftermarket one, which solved the problem. BTW, I spoke with their tech support and they said Suzuki voltage regulators are junk.
you gotta be consistent, and eliminate one thing at a time.