Hi Yaasan
This is a good start. I too have written train control software (actually since 1989 starting with Turbo Pascal and Märklin 6050!)
The features you have shown - controlling functions of a loco, seeing s88 status, changing signals are all needed and are very useful for testing a layout but I think you will find that creating these virtual controllers does not lead to the ability to control a whole layout. Here is what I mean. Imagine you wish to run a train from station A to B. The track between these two stations goes through 5 turnouts and passes two signals. To do this with virtual controls, one will need to know the following:
Address of the loco.
Correct direction for each turnout and the address of each.
Address of both signals.
In addition, if you wish the train to run a a nice prototypical speed, you will need to know the scale speed for each speed step so one know how to accelerate through the speed steps etc.
When running a layout these are not things one can keep in ones head for long, and this is exactly where layout control software can be so wonderfully powerful.
One might then say we need to create a 'route' from points A to B, yes that is is easy to do too, but its has not yet made it possible to control a layout, because now one still needs to remember to use route A-B but what if other trains are using the tracks, or need to have the turnout along the way set differently....?
In other words the control of a layout starts getting very complex, and it needs the parts you have made, but also lots of other parts too, - and I encourage you to make them also.
The approach that I took and what I would also suggest to you is to think of how the user wants to run their trains. I do not want to have to play a piano concert setting signals turnout or loco speeds. I don't even want to know any addresses. I like to click on a train on my layout diagram and pick which station it is to go to. Done. I then want the computer to decide when the track is free, set the signals, set the turnouts, set the right speed steps for the loco (or perhaps multiple locos in the train) monitor its progress with s88 feedback, play the sound effects, switch of smoke when not needed etc. While that is all happening I want to send another train on a journey or do some manual shunting somewhere. This all sounds very complex and indeed it is - but that is exactly what software is for - handling such complex problems!
So I encourage you to think about adding layers of abstraction between the loco, turnouts, signals and s88 and concepts that the observer is interested in, which is stations and train names. For example: send my Intercity from Main station to my rural station.
Think of the layers of abstraction like this:
CAN BUS level command
Serial port command
Loco address and speed
Loco name
Train that the loco is part of
Location of the train
Destination of the train
The hardware controllers we can buy and virtual version of them one usually sees usually go only the first 3 levels. Speed knobs and lists of functions - but not enough to actually drive a train from A to B without being a concert pianist with the mouse or keyboard ! :-)
Select your data models carefully. I found that OOP was not always the best option, for example I sometimes need to get the station name of the track that the train is on. My 'train' structure includes the track number and an index into the list of stations, so I can quickly grab the station name, and pass that into the station announcement.
You may decide to start a new piece of software with a broader comprehensive goal and use the code you have already written to do the low level stuff as it is needed. You may in fact find that instead of giving the user a virtual loco controller (with speed steps and lists of functions) you want to give them the view from inside the cab and add the signals (and speed limit signs) one may see through the window and a speed control in km/h rather than speed steps - stuff we can't always do with the physical controllers.
For example:
http://layout.mixmox.com/1/signals-in-cab-viewKeep at it !