I need a Nav Aid, area nav, engineer?

General Chit Chat
Post Reply
Message
Author
John Hill
Chief Pilot
Chief Pilot
Posts: 5723
Joined: Sun Aug 23, 2015 7:40 pm
Location: Aotearoa

I need a Nav Aid, area nav, engineer?

#1 Post by John Hill » Thu Feb 15, 2024 12:17 am

I have some ESP32 and ESP8266 micro devices which are quite small (not really tiny) and include WiFi and various analog and digital IO.

We also have a Lego train layout (think size of double garage). Obviously I need to tool up these locos to report their position on the layout and to accept commands from Central Train Control. Reporting and control via wifi is known science but I need to work out a system whereby the position of the trains can be determined, either have trains find their position and report or some remote system determine the position(s).

OK, bar code, RFID, yeah maybe but not very flexible. Camera in the ceiling, OK, but problem at a public display in a hall or suchlike.

So I need an engineer who is familiar with area navigation systems that can be scaled to the distances. Hmmm, how about those WWII era parabolic systems such at LORAN et al? Two pingers at the side and the train detects difference in travel time (phase angle). Do I need VHF/UHF or go the other way to low HF? The trains are not always in sight so that rules out infra red and ultrasonics(I think).

So,  using wifi,  my notion is that there are two receiver antenna off to the side of the layout.  Central control would 'poll' a  loco which would respond and Central would triangulate the loco position by comparing time of arrival at the two antenna.  I think I might actually need three antenna, whatever.

I wonder where I can find an engineer join the dots and colour in the squares?
Thanks
Been in data comm since we formed the bits individually with a Morse key.

User avatar
Fox3WheresMyBanana
Chief Pilot
Chief Pilot
Posts: 13248
Joined: Thu Sep 03, 2015 9:51 pm
Location: Great White North
Gender:
Age: 61

Re: I need a Nav Aid, area nav, engineer?

#2 Post by Fox3WheresMyBanana » Thu Feb 15, 2024 1:02 am

Multi-axis accelerometer chips are stupidly cheap now they are in every drone, less than $4 a piece here. Could the track layout be programmed into each chip, same for each loco, based on the curves being detected by radius and length/time, and a simple bit of dead reckoning for the straights? Set up the chip or control to record and just run it round the track transmitting accelerometer readings a few times to get some averages. Then just have each loco transmit its position every x seconds. You could do the position on a nodal basis (points/signals/stations being the nodes, rather than cartesian co-ordinates). No need for polling, and the locos only need transmit and the control only receive.
You state you want a command T/R system, but this should be easier to implement if the position data is only going one way.
Obviously this method is easily adaptable to other tracks, and can be given to fellow railway modellers.

Notes:
I think a multi-receiver system might be prone to reflection and interference errors.
Safety stops can be programmed into the locos,e.g. at the end of sidings.
Do you have a means of letting the loco know the status of upcoming signals? If this is added, it will be a big safety boost. It can then stop A/R.
You could just have a simple electromagnet, or even an upwards- uv LED, in the track ahead of each signal, with a detector on the underside of the loco. Should be able to make this discrete enough, perhaps even disguise it as a model train warning indicator as real railways have. It could be the same method for all signals, e.g. ON for Green as a fail-safe method.
Indeed, it might even be possible, with enough of these, to use them as beacons and deduce the loco position from them. Or at least cross-check the accelerometer-derived position.

John Hill
Chief Pilot
Chief Pilot
Posts: 5723
Joined: Sun Aug 23, 2015 7:40 pm
Location: Aotearoa

Re: I need a Nav Aid, area nav, engineer?

#3 Post by John Hill » Thu Feb 15, 2024 3:24 am

Thanks, I did not think of the accelerometer chips but do they give position? They are certainly interesting in the way you described. At the very least they should be fun to play with!

I do want two way comms with the train as a lot of Lego track is non-conductive and of course being Lego it is by nature prone to be torn up and relayed in arbitrary configurations. I think I will be staying with wifi for the comms which leaves me with the holy grail of train position.

Thanks for the accelerometers!
Been in data comm since we formed the bits individually with a Morse key.

Boac
Chief Pilot
Chief Pilot
Posts: 17255
Joined: Fri Aug 28, 2015 5:12 pm
Location: Here

Re: I need a Nav Aid, area nav, engineer?

#4 Post by Boac » Thu Feb 15, 2024 8:28 am

John - position is the second integral of acceleration.

User avatar
llondel
Chief Pilot
Chief Pilot
Posts: 5943
Joined: Wed Oct 03, 2018 3:17 am
Location: San Jose

Re: I need a Nav Aid, area nav, engineer?

#5 Post by llondel » Fri Feb 16, 2024 10:56 pm

I know a way to do it, but it isn't cheap. Ultrawideband (UWB) position location is accurate to about 15cm under lab conditions. It does use time difference of arrival, but because the pulse is only a nanosecond or two long, it's way better than using WiFi. To do TDOA you need an accurate and stable timing reference - light (and radio) travels about a foot per nanosecond, so if your timing reference is off by that much, it's going to displace your results.

Ideally you need three antennas for TDOA - if you've only got two then the unit could be anywhere along a line that represents that difference. The third antenna resolves that ambiguity. Or you can combine TDOA with Angle of Arrival, which will give you the extra information to use with two antennas.

WiFi accuracy is still only in the metre range, so it might not be good enough for what you want.

This might give you some insight. https://www.inpixon.com/technology/standards/wifi

Yes, I did used to work on designing UWB location systems.

John Hill
Chief Pilot
Chief Pilot
Posts: 5723
Joined: Sun Aug 23, 2015 7:40 pm
Location: Aotearoa

Re: I need a Nav Aid, area nav, engineer?

#6 Post by John Hill » Sun Feb 18, 2024 11:48 pm

Thanks, I see the common UWB esp32 modules use a Decawave D1000 chip which is a bit spendy ($30+) which puts it out of the picture for a hobby train layout.

If I get enthusiastic again I might put markers on the layout, RFID, magnet, barcode etc. The trains however will be on WiFi as I need a means of remote control and some of the layout is non-conductive rails (plastic).
Been in data comm since we formed the bits individually with a Morse key.

User avatar
llondel
Chief Pilot
Chief Pilot
Posts: 5943
Joined: Wed Oct 03, 2018 3:17 am
Location: San Jose

Re: I need a Nav Aid, area nav, engineer?

#7 Post by llondel » Mon Feb 19, 2024 4:21 am

The back-end stuff you need for UWB is $thousands. See https://ubisense.com/dimension4-2/

John Hill
Chief Pilot
Chief Pilot
Posts: 5723
Joined: Sun Aug 23, 2015 7:40 pm
Location: Aotearoa

Re: I need a Nav Aid, area nav, engineer?

#8 Post by John Hill » Mon Feb 19, 2024 4:36 am

I did not see an $$ figures but there is enough to convince that I could have more fun for the money elsewhere!
Been in data comm since we formed the bits individually with a Morse key.

Post Reply