Dynamic station selection for Run Device Functions [Serial]

Are there any ways to make a serial connection that uses a dynamic reference to a station (IE a station field in a table record)? I was hoping to have a table that stores a table record for each serial printer so that operators could select between them and choose where we print to, but while doing so I found that the selected station does not appear to be able to be dynamic when we go to call the Serial Run Device Function.

The only obvious work around I can see is to check for the individual station options, and use different hardcoded stations in IF statements on the trigger, but this will require us to edit apps if we ever need to add/edit printers and stations opposed to simply adding another table entry – which I would like to avoid if possible.

If functionality for this does not exist (or similar functionality that would achieve the same means), I would like to flag this for the tulip team as a potential feature addition.

1 Like

Hi Nick,

Sorry about the delayed response here! I believe this should be possible -

You can configure the serial player to point to a table record field, so you could have a row-per-station table with the serial configurations in it.

However, this seems to be what you were trying, however, and you weren’t able to get it to work as expected? Can you share a little more about what issues you encountered?

I’m also going to tag @jmlowden because I know he had some nifty serial device trigger set-ups that were a little bit more dynamic he might be able to share as well!

I never closed the loop to leverage table records with the connection details, but I can work on that this week. One of the main issues I had resolved with some help from this forum was to locate the COM port address from the list of connected devices for a specific device serial number that I wanted to connect. These serial numbers would need to be in one of your table columns.

You should be able to pick your device from a single-select widget, load the corresponding table record that contains the connection parameters for that device, and connect the device (or provide an error message if that device is not actually in the list of physically connected devices).

A little more complex would be to have that single select be further filtered based on what devices are physically connected, but I think this is also possible.

Will work on this and plan to present at Thursday AM Office Hours, and can post screenshots here as well.


Hi Beth,
I might be missing something extremely basic, but for some reason I did not think I could point it at a table record field. From what I am seeing, I am only able to select a static station – there is no selector for the data type (record, variable, etc) and I did not see anything in the drop down I could identify as a selectable record option. Is there a step I am missing here?

Have you tried storing the serial device IDs and configurations in a Table, then using a variable Identifier to call the desired device? I dynamically connect to multiple balances using the following logic:

I am not particularly having issues selecting various serial device IDs at the same station, but selecting which station we are communicating serial through (each station will likely only have 1 device, given how the site is set up). I would like to have these ‘device configurations’ be used many places, which is why I am trying to have the station be dynamic without having to do CASE checks for each station we are potentially using.

Aha, I misunderstood the issue then. I agree it does seem that the “connect at” station selection within the “Run Device Function” command is static. (However, I can confirm that it is possible to make the trigger logic such that the device selection dynamically references conneciton parameters in a table, see subsequent post.)

Further discussion with @Beth yielded the possibility that you could select/specify the desired station in a variable (or in a referenced table, perhaps in a table of Station parameters?) and then just have that connector logic repeated for each station, with the device paramters being dynamic.

This wouldn’t be fully dynamic as both the table and triggers would need to be updated if stations are added or removed, but it could give you something reasonably “portable” to copy/paste from app to app.

What do you mean by “CASE checks” and how are you achieving this?

You would currently only need to edit apps if the stations changed, but the printer changes could be achieved with just table updates as follows:

First, get the connected device serial #s into a list
(I have this triggering on App Start but also triggerable via button to “refresh” the list):

Next I have a single-select drop-down listing my connectable devices, with corresponding triggers to connect the selected device (triggers could be consolidated):

But he does not want to connect n devices to one station, but to n stations.
And then he wants to execute the device function an a selected station.

You executed the device function “at this station”.

The question was not how to choose a device, but how to choose the station as well.

My bad for breaking from non-tulip vocab. I was just referring to setting up an individual IF… THEN… branch for every single station.

Again, you’d still have to maintain your stations table, but instead of seperate if/then in one trigger, you could just copy the trigger and update the condition and station for each accordingly (perhaps easier to manage, harder to corrupt?) and only have it execute for the selected stations conditionally if the station referenced in the trigger “is in” the array listing the selected stations to which you want to connect your device.