Keyboard Shortcuts
ctrl + shift + ? :
Show all keyboard shortcuts
ctrl + g :
Navigate to a group
ctrl + shift + f :
Find
ctrl + / :
Quick actions
esc to dismiss
Likes
Search
Locked
Jython Script Contribution - YAAT enhancement
#automation
#yaat
#scripting
I have found YATT very useful, and have used it in my club to move a train around a timesaver puzzle. Thanks Dave Sands very much.
I found that I needed two enhancements in order to reduce the size of the text file:
I would appreciate it if I could be told what the next step, if any, should be Bill Fitch |
Bill,
toggle quoted message
Show quoted text
I will review your proposed changes. Those look like very good additions. Dave Sand On Sep 18, 2019, at 6:17 AM, bill fitch <bill.fitch14@...> wrote: |
Bill,
toggle quoted message
Show quoted text
As it turns out, my old style is no longer relevant. I have replaced the run/skip style with a program address style. ?The actionTokens list is now treated as a computer program with control actions modifying the current address index. ?This simplified the implementation of nested IF and GOSUB logic. Thank you for the push to make this change. ?It was time to re-think how it runs and therefore this will be version 2.0. Before releasing this on the world, I would appreciate if you could verify with your setup that I did not miss something important. Dave Sand On Sep 19, 2019, at 7:39 AM, bill fitch <bill.fitch14@...> wrote: |
I will try to test it out this week or early next week Bill On Mon, 23 Sep 2019 at 21:35, Dave Sand <ds@...> wrote:
--
regards Bill Fitch |
Hi Dave
I have tested out version 2 with my YAAT text file with gosubs and nested ifs and it worked flawlessly. It is much better without the messy code that I wrote. It looks a lot nicer too. However the main reason for me looking at YAAT was to try to automate trains by providing the operators with buttons they could press on a panel. My first approach was with one train which you have seen. The next approach is to try to cope with 2 trains, for which I am looking at dispatcher. The problem with dispatcher from my viewpoint is that it required a lot of manual intervention actually dispatching the trains,and I wanted to select by pressing buttons. I approached Pete Brownlow when I attended his JMRI Automation course and he forwarded me Jay Janzen's script, from which I extracted some code. I thought that YAAT would be ideal to run the code, so I have incorporated it into version 1 of your code and tested it with a single dispatch script. My next task will be to run one dispatch after another from YAAT.? It would be very nice to use it in version 2 so if you think it relevant it would be nice if you could look at it and see whether it would be suitable for incorporation. The problems with it are:
I have put my attempt in the same folder The other request is that it would be nice to have different YAAT files for different profiles, so I have put in a bit of code for that. A colleague requested that he should be able to leave the main YAAT file alone and just modify text files, so that was my take on the request. It would also be quite nice to have a script file in the examples which would enable someone to automate dispatcher outside of YAAT. Bill |
to navigate to use esc to dismiss