John,
re the PI, Zero, my limited experience with it shows its just too small for the task of fully running a railway, but its remarkable how close it comes at the price!
I understand the temptation/benefits to "just connect directly". In fact Rocrail has a whole set of Raspberry PI based "
Rocnet" interfaces that do connect directly. There are some excellent and low cost interface boards available, and some very nice interfaces in Rocrail for setting the boards up etc. My main issue with them is that each PI on the network then needs separate boards for Track sensing, servo operation etc. - But you can have lots of these interfaces connected to each PI, so for physically small layouts, this is hardly a problem. You can even update the PI firmware from within RocRail.
My NodeMCU boards are aimed at a rather different situation, where each physically remote station on my garden track I can have a single low cost board to support a few track sensors and points servos (sufficient for a station). The reason for using MQTT as the interface and the extensive
RocNet protocol is that by using existing standards I did not have to redo all the work that has gone into the interfaces and automatic train control etc that Rocrail already has. Because of the physical simplicity (and low cost of the hardware), each station has one ESP8266 and can be solar/battery powered and easily removed/moved. If the layout is very complex, I would recommend direct connection not WiFi, and probably to use the LocoNet, C-Bus or Rocnet interfaces. (Half of my layout (the bit in the shed) actually uses C-bus modules, and my track powered locos run from an C-Bus controller/booster).
If you just want a train or a few points controlled from a tablet, then using customised HTML is fine if you want to program it, but for sequences, automated scheduling, nice graphics, why repeat what has already been done??
ESP BASIC was new to me, but from what I see its an HTML based interpreter? so may have speed issues in comparison to the "normal" Arduino compiler approaches??
FYI my "Mobile" ESP based decoder was partly designed as a speed test for the ESP, and I was very pleased to find that it is able to simultaneously run two channels of speed synchronised digitised sampled audio, as well as doing all the WiFi PWM loco speed control and RocNet interface stuff (as I hope you can see from the linked video in my original post). By the way, because I used NMRA compatible "CV" locations, an additional "extra" from using standards was that you can use any programming interface to read and program the loco features.
I'm not connected to Rocrail, just a satisfied user! I tried JMRI, but ended up confused!