Action triggering with concrete loko

Post Reply
Libor
Posts: 27
Joined: 06.12.2014, 08:20

Action triggering with concrete loko

Post by Libor » 17.03.2019, 09:28

Dear friends, I would like to ask you for advice. I have defined action, which is triggered by sensor when any loco goes through it. But I would like to trigger this action when only one concrete loko goes through it. No triggering when any other loko goes through. What is the better method how to do it ?

hermannk
Moderator
Posts: 896
Joined: 06.07.2014, 12:32
Location: Kiel Germany

Re: Action triggering with concrete loko

Post by hermannk » 17.03.2019, 09:44

Hi Libor,
you may define a "condition" with the sensor action:
- https://wiki.rocrail.net/doku.php?id=actioncond-en
Regards
Hermann

Libor
Posts: 27
Joined: 06.12.2014, 08:20

Re: Action triggering with concrete loko

Post by Libor » 17.03.2019, 10:03

Dear Hermann, yes, I have try this, but without any success. When I define condition type of loko with concrete loco ID, still any other loco trigges the action.

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

Re: Action triggering with concrete loko

Post by smitt48 » 17.03.2019, 11:23

Hi Libor,

Is the sensor attached to a block? A sensor does not know when a certain lok is running over the sensor, you have to define it in a block.
It is best to add your plan here, so we can see how it is defined.

Tom

Libor
Posts: 27
Joined: 06.12.2014, 08:20

Re: Action triggering with concrete loko

Post by Libor » 17.03.2019, 12:22

I have try to attached the zip of my plan. The action SoundON is attached to the two sensors : 542 and 527. I would like, that this action SoundON will be triggered only when loco T478 goes through the sensor. The whole operation goes ok on sensor 542. But this operation do not works on sensor 527. Where I have done the mistake ? Thank you very much for your explanation. Libor
Attachments
issue.zip
(131.23 KiB) Downloaded 3 times

hermannk
Moderator
Posts: 896
Joined: 06.07.2014, 12:32
Location: Kiel Germany

Re: Action triggering with concrete loko

Post by hermannk » 17.03.2019, 13:18

Hi Libor,
as Tom already pointed out a sensor has to be assigned to a block (used with a block) if you want to refer to a loco.
Sensor "542" is used with block "k542" - that's fine.
Sensor "527" is not used with any block - correct that and it will work.
Hint: block "527" has no sensor defined in the route preferences.
Regards
Hermann

Libor
Posts: 27
Joined: 06.12.2014, 08:20

Re: Action triggering with concrete loko

Post by Libor » 17.03.2019, 20:15

Dear Guys, thank you very much for your help, it seems to be ok now. I have thought, that it is enough to have attached the sensor to block only in window Sensor-General in line BlockID. I have not associated the sensor in window Block-Routes. Thank you once more.
Libor

Post Reply

Return to “Automatic mode”