The Brainliest Answer!
You can make an railway signal with electromagnet
if you like the idea i can provide u the details

1 5 1
with batteries
ok,then u can go to class 7 NCERT science book electricity chapter and on the last page it given in detail with pic
how was ur project?
I didnt get the book
you can very easily search for it in googlk