Pi-star switcher was created to support changing profiles on a Pi-Star hotspot. It consists mainly of a bash script that can operate with a Nextion screen.
In Particular the NextionDriver by ON7LDS allows commands to be sent to the host and 1 line received back.
The files are available from https://github.com/sgtsmall/Pi-Star_switcher.git
Have a look at the README.md file and the installation.md I will be doing some more work on this for both the screens and the script checking. However it seems to work reasonably well now.