model train carriage lighting

Hi guys.

I would like to be able to light up my train carriages to have a night time lighting effect but im not sure which kind of arduino board I should use and how I can control it. I have room to put a 9v battery in one compartment for power supply just notsure what to use and control method.

All tips and advice would be greatly appreciated

Thank you in advance

What scale are you talking about?
I routinely install LED strips in H0. They are powered from the tracks and are always turned on.

How big is your layout? The easiest way to remote control something that simple would probably be IR remote, or you can make it intelligent enough to sense the darkness and turn the lights on automatically.
In any case, a standalone microprocessor would be a much more suitable approach. Something from the ATtiny range, perhaps?

Thanks for the reply

Will be using ho/oo scale.

I havent yet designed a layout because I need to buy more track etc but it will probably be around 2400x1800 roughly

Will I need to build a board for the ATtiny or do I just solder bits to the micro processor?

Well, you could have it all hanging in the air, but a little bit of perfboard would make it a lot less prone to shorts. Trying to stuff an entire Arduino board (even the Nano) in a H0 carriage would be challenging.
You don't need a lot of components, really. A voltage regulator, ATtiny, a transistor or MOSFET to drive the LEDs, and a few caps and resistors here and there, plus either a photoresistor or some communications device.

2400x1800, so no more than 5-6 trains, right?
Which option do you consider more attractive? Lights automatically turning on when it gets darker or you manually turning them on/off?
A simple RF module would also work, I suppose. There should be enough room for it.
You mentioned 9V battery to power the lights. Is that a requirement? Why not pick up the power from the tracks or overhead line? Is there power in the tracks and/or overhead line or are we talking about self powered locos?

I built a small circuit with an Attiny 45 and an IR receiver to control an electromagnet to lift the uncoupling hook in an N Gauge wagon. It is powered by an 80mAh 1s Lipo. There was no room for perf board so I built everything onto the Attiny pins. The concept could easily be modified to switch lights on an off.

This YouTube video shows it - to give an idea of the size. Infra-red on-board uncoupling in N-Gauge wagon - YouTube

...R