EZO-PMP - Dispensing different volume value as needed

Hi Kyle,

In a Conditional Function, can I change the volume to be dispensed by a pump as needed? Thanks.

Tuan

Yes. Here is the description when you add the Volume Output Action:

[Action] Output: Volume: Instruct the Output to dispense a volume.

Usage: Executing self.run_action(“d6da6820”) will actuate a volume output. Executing self.run_action(“d6da6820”, value={“output_id”: “959019d1-c1fa-41fe-a554-7be3366a9c5b”, “channel”: 0, “volume”: 42}) will send a volume to the output with the specified ID and channel.

1 Like

Hi Kyle,

Thanks for a quick reply.

I tried your way and it did not work. I got the message below:

My code:

self.run_action(“6e8ff642”, value={“output_id”: “959019d1-c1fa-41fe-a554-7be3366a9c5b”, “channel”: 0, “volume”: 100})

Error message:

2022-11-13 09:30:13,248 - ERROR - mycodo.action.output_volume_6e8ff642 - Error: Output with ID '959019d1-c1fa-41fe-a554-7be3366a9c5b' not found.

The code below runs the pump, but the dump does not dispense the correct volume, which is 100ml. As a matter fact, it always dispenses the same amount (the static value configured to be dispensed) even when I changed the volume:

value=‘{“output_id”: “959019d1-c1fa-41fe-a554-7be3366a9c5b”, “channel”: 0, “volume”: 100}’

self.run_action(“6e8ff642”, value)

Thanks for your help.

Tuan

output _id must be the ID of your output you want to manipulate, not the ID of the example I wrote. You can find this ID when you hover or click the output type button on the Output page.

It works. Thank you so much for your help.

Tuan

1 Like