Start-of-day

Post Reply
ejp
Posts: 117
Joined: 01.10.2012, 08:20
Location: Denmark

Start-of-day

Post by ejp » 24.02.2017, 13:49

Hello

I have written a XML script to make a simple start-of-day on my layout.
And have found the documentaion and the use of the terms a bit confusing.

I am using Lenz LZV100 and therefore I must read all sensors to make Rocrail show these correct.

I have found that start-of-day means different things depending on the interface.

I have found the following and may have not found the correct things. Please correct me if I am wrong.

Rocrail
Rocrail has a command line option described in the manual as SOD.
When using -SOD nothing happens. When starting Rocview afterwards the sensors are not set
When using -sod a line is written in the trace but nothing happens. When starting Rocview afterwards the sensors are not set
20170224.122232.577 r9999c 00003294 OXpressN 0677 Start of Day

Rocview
Rocview has a header in the menu Control/Start of day
There are 3 submenues:
Init field. Described in the manual and works by flipping switches twice (even if the switch is occupied) and setting signals plus a bit more.
Query sensors. Described in the manual as reading all sensors and works fine
Query decoders. Not described in the manual


XML script
Has a <sys cmd="sod"/>. No description in the manual except the name.
Works the same way as Rocview/Query sensors
I have not found a command for Init field or for Query decoders


andRoc
Has System/Init field and System/Query sensors. Both work as in Rocview
I have not found Query decoders


Rocweb
Has System/Init field. Works as Rocview Init field
Has System/Start of day. Works as Rocview Query sensors
I have not found Query decoders

I think it is a bit confusing.

The reason for writing my own initiation is that my switches do not need to be switched twice and my decouplers only need to be lowered.
The switches with no sensors are switched to the last known position (which most likely is the correct one) and those with sensors are switched to the sensor position if this is not already the shown position.
All switches are checked for occupied, if so a warning is issued and the switch is not switched.

My XML script therefore starts by calling system/sod followed by a foreach through the switches. This reduces the time from about 2 minutes to about 10-15 seconds.
When I put position sensors on the remaining switches it will be even faster.
But it surely relies on the my choise and setup of switch motors, servos and sensors.

Regards
Erik Juul-Pedersen

smitt48
Moderator
Posts: 6111
Joined: 04.04.2014, 01:07
Location: Kralendijk, Bonaire - Dutch Caribbean

Re: Start-of-day

Post by smitt48 » 24.02.2017, 15:04

Hi Erik,

Nice research! :thumb_up:

Do you recommend that:
1. "Query Decoder" should be removed from Rocrail?
2. Functionality in all should reflect Rocview?
3. Names for the functions should be consistent with Rocview?

Tom

ejp
Posts: 117
Joined: 01.10.2012, 08:20
Location: Denmark

Re: Start-of-day

Post by ejp » 24.02.2017, 16:03

Hi Tom

I am not sure what to recommend as it is not up to me to design.
But this what I think could be a solution.

As Rocview has all functions divided in reasonable function, these should be retained. Also because Query sensors are only needed on certain controllers.

So:
Rocrail command line options could have a -querysensors to do just that. And work as well. -SOD or -sod could be described and after some time removed.

Rocview retained. If Query decoders really does nothing it could be removed. Otherwise described in the manual.

XML script. Same as Rocrail, perhaps also functions for the missing 2 functions.

andRoc. If Query decoders is retained and relevant for andRoc, it could be added

Rocweb. Start of day could be renamed to Query sensors.

And generally. Init field says nothing about what it is really doing besides updating the objects. It also initiates the hole layout physically.

Regards
Erik Juul-Pedersen

smitt48
Moderator
Posts: 6111
Joined: 04.04.2014, 01:07
Location: Kralendijk, Bonaire - Dutch Caribbean

Re: Start-of-day

Post by smitt48 » 24.02.2017, 16:48

Hi Erik,
I am not sure what to recommend as it is not up to me to design.
You can recommend, that is what we do here in the forum. If there is agreement then most of that is implemented.

Here is an example of forum request (November 2016) that was implemented (January 2017).
http://forum.rocrail.net/viewtopic.php?f=112&t=12731
Build upon by another forum member.
http://forum.rocrail.net/viewtopic.php?f=122&t=13357

Or follow this one a brandnew discussion about functionality: http://forum.rocrail.net/viewtopic.php? ... 37#p138227
So you see we can push for things! :shock:

Tom

ejp
Posts: 117
Joined: 01.10.2012, 08:20
Location: Denmark

Re: Start-of-day

Post by ejp » 24.02.2017, 17:28

Hi Tom

Certainly I can recommend. I have done this before.

But as a user I see only part of the system and may oversee other parts that could influence on the result.

So please se my "recommend" rather as a "small idea" in just a minor corner of the system. You and others more directly involved in development must make the decisions.

Regards
Erik Juul-Pedersen

Post Reply

Return to “Documentation”