.... I'm looking at designing a regulator module using a super capacitor to maintain constant voltage (or current) to lights for several seconds with up to a 50mA 12V LED load. That will also eliminate any flickering as cars travel around the loop.
So from a design requirements perspective, you need energy storage of, say, 2 Joules. That is, if you want to run 50 mA at 12V (0.6 Watts) for several seconds (let's call it 3 seconds), that 0.6W x 3 sec = 1.8 Joules.
If energy storage is done with a 5V supercap (as done with YLB that GRJ mentions), an economically priced 0.47 Farad supercap would be more than enough. That is, a 0.47F supercap charged to 5V stores about 6 Joules. You can "read all about it" in the OGR design thread for the YLB here. This would be if you go the route of a 5V regulator module, a 5V supercap, and a boost regulator module. As discussed in the thread, consider some method (could be as simple as a resistor) to limit the supercap charging current when you initially turn on track power. That is , if you have a handful of passenger cars with this "topology", you might get a whopping initial charging current (many Amps) if the 5V regulator attempts to directly drive a depleted supercap.
I picked that up and will give it a test. It is certainly cheaper than anything I could put together myself. I can't even mail one across town for that price.
But if you're going with the buck-boost module, where is your 2 Joules of energy storage? This would likely be done on the input side of the module since presumably you want constant brightness for the "several seconds" at 0.6 Watts. But here's the rub. That input-side capacitor must be able to handle full track voltage. As the photo shows, they use a 35V capacitor (220uf) which is minimum rating for O-gauge AC operation. Yet, when entering the 6V AC block, you might be coming from, say, only 12V AC so the the 220uF cap might only be charged up to 15V DC or so. 15V and 220uF is a paltry 0.025 Joules...so ~100 times smaller than what you need! So you'd need to increase that 220uF to something like a ginormous 22,000 uF capacitor (rated at 35V).
I vote for the YLB method. I'd think the 3 major components, 1) AC-to-DC stepdown 5V module, 2) 5V supercap, 3) DC-to-DC boost regulator, should be in the ~$5 range if you're willing to do eBay from Asia suppliers.