Just to add another view (which perhaps is an extension of what Richard will soon find with his Pi Servo pHAT approach) ...
I use DCC++ on an Arduino Mega with motor shield to command the locos on my small G-scale garden railway.? (It's connected to an iMac running JMRI and I use the iThrottle app to give me a wifi roving throttle? The Mega gets its power over USB from the iMac;? the motor shield has a separate 20V DC input to pass on to the rails.)
Quite separately, I have an ESP32 chip loaded with a modification from 2 sets of Rui Santos's code to set up a wifi server (search for ESP32 wifi server on youTube to find one video on creating a web server with buttons and one for servo control with a slider). My version provides a webpage of buttons to any connected client (such as an iPhone).? The client sends a web request of the form 192.168.55..1/?NN on my local network.? The ESP32 wifi server picks out the NN and recognises this as a request to switch a particular point/turnout servo, connected to a pin on the ESP32.? (I have 5 servos but it could support more.)? Note (1) that the ESP (and from there the servos) is powered from a 5V supply from a phone charger brick, and not from the DCC++ power supply - it's the sort of thing that you can use to recharge your phone when you're out and about and (2) the ESP32 can either send a single command to a servo to say move straight to position x, or a sequence of commands to move the servo incrementally to its end position to produce a smoother point change.
All works fine.? The only problem is I have two separate interfaces to play with - one to JMRI and one to the ESP32 - so tend to have to have both an iPhone (to the ESP32) and iPad (to WiThrottle) to hand, which is cumbersome.
Hence, I'm looking for an easy way for WiThrottle/JMRI to instruct the ESP32 to do something.
Maybe I can modify Outputs.cpp in the Arduino code to call the ESP32 webpage...? (Is there an HTTP library that might support this?)
Maybe the ESP32 will work with one of the DCCInterface.com products mentioned on the? page given by fcot2002 earlier (note the link there had a mistake in it).
If anyone has tried either of these things, please let me know with some details.
I'll write again if I get anywhere.
Regards,
Les