Wiki » History » Version 3

« Previous - Version 3/8 (diff) - Next » - Current version
David PICARD, 10/08/2018 06:29 PM

swlk4w Wiki

Swagelok 4W actuated valve :
  • Actuator : Gulex K8
  • Port size : 3/8"
  • Port configuration 4 to 1 selector


From source

Same procedure for Linux and Windows.

$ git clone

Binaries (Windows)

Download Windows binaries under the "Fichiers" tab.

Windows driver

For Windows versions earlier than 10, the STMicroelectronics VCP (virtual COM port) driver is required. With Windows versions starting at 10, ST recommends to use the driver provided with by the OS.

Using the software

Generate a config file

To generate a config file, open a command prompt, and type :

swlk4w -g myconf.conf

Here is the file generated on Windows :

port_name = COM22
baud_rate = 115200
data_bits = 8
parity = none
stop_bits = 1

data_directory = %TEMP%
geographical_location = XXX

sync_start_minute_multiple = 15
sec_per_position = 900
sec_read_delay = 10

step01 = 1
step02 = 2
step03 = 3
step04 = 4

pos1 = unused1
pos2 = unused2
pos3 = unused3
pos4 = unused4

Adjust the config file

Serial section

Search the serial port name that your system has given to the valve, and edit port_name accordingly. Don't change the other parameters.

Data section

Set the data directory. This is where the log file with time and valve position will be saved.

Change the station code e.g. to one of the GAW IDs.

Timing section

  • sync_start_minute_multiple : the valve will synchronize with this multiple (minutes). 15 means the valve will start to move at the next 1/4 h.
  • sec_per_position : number of seconds to wait in every position.
  • sec_read_delay : number of seconds before polling the valve to read back its actual position. Set to 15 s.

Sequence section

This section is used to build a sequence, that will be repeated forever. The sequence is specified in key-value pairs.

Important : the sequence is not played in the order in which the lines appear, but in the alphabetical order of the keys.

Suppose you want to sample ports 1, 2, 1, 2 and 3. You must specify the sequence as follows. Note that the keys are alphabetically sorted.

step01 = 1
step02 = 2
step03 = 1
step04 = 2
step05 = 3