Daemon to control NE1000 syringe pump from New Era Pump Systems.

external links



The ne1000 daemon is composed of the following traits:

has-position (from has-limits)
uses-serial (from uses-uart)


diameter (float)
Syringe pump inside diameter, in mm.

address (integer) default: 0
Address of syringe pump in RS232 network.

units (string) default: ML
Volume units.

limits ([number, number]) default: [-inf, +inf]
Configuration limits are strictly optional.
from has-limits
addendum by ne1000:
Volume limits, in units. Most negative limit should be zero.

rate_units (string) default: MM
Rate units. First character indicates mL or uL, second character per-minute or per-hour.

low_noise (boolean) default: True
Toggle low noise mode.

baud_rate (number) default: 19200
from uses-uart

make (String) default: NULL
from is-daemon

model (String) default: NULL
from is-daemon

out_of_limits (string) default: closest
Control behavior of daemon when set_position is given a value outside of limits.
from has-limits

serial_port (string)
from uses-uart

port (integer)
TCP port for daemon to occupy.
from is-daemon

serial (string) default: NULL
Serial number for the particular device represented by the daemon
from is-daemon


The ne1000 daemon will provide the following state information:

type: number

type: [number, number]
from has-limits

type: number
from has-limitshas-position

type: number
from has-limitshas-position


Daemons with the ne1000 trait expose the following public methods:

Withdraw as quickly as possible until pump stalls.

Inject as quickly as possible until pump stalls. Once stalled, the position is set to zero.

Set rate, in units.

rate, {'type': 'number'}

get_limits ➜ [number, number]
Get daemon limits. Limits will be the intersection of config limits and driver limits (when appliciable).
from has-limits

in_limits ➜ boolean
Check if a given position is within daemon limits.
from has-limits

position, {'type': 'number'}

get_destination ➜ number
Get current daemon destination.
from has-limitshas-position

get_units ➜ string
Get units of daemon. These units apply to the position and destination fields.
from has-limitshas-position

get_position ➜ number
Get current daemon position.
from has-limitshas-position

Give the daemon a new destination, and begin motion towards that destination.
from has-limitshas-position

position, {'type': 'number'}

set_relative ➜ number
Give the daemon a new destination relative to its current position. Daemon will immediately begin motion towards new destination. Returns new destination.
from has-limitshas-position

distance, {'type': 'number'}

Expose direct access to the serial port to clients. This should not be encouraged for normal use, but may be very important for debugging. If a device is expected to return data, it should be logged at the INFO level, not returned to the client. This is done to allow long tasks to be run asynchronously, and to explicitly discourage use of this method except when debugging. Setting `busy` to true is encouraged, but individual daemon writers should consider their own use case.
from uses-uartuses-serial

message, {'type': 'string'}

busy ➜ boolean
Returns true if daemon is currently busy.
from is-daemon

id ➜ dictionary
JSON object with information to identify the daemon, including name, kind, make, model, serial.
from is-daemon

get_config_filepath ➜ string
String representing the absolute filepath of the configuration file on the host machine.
from is-daemon

get_config ➜ dictionary
Full configuration for the individual daemon as defined in the TOML file. This includes defaults and shared settings not directly specified in the daemon-specific TOML table.
from is-daemon

get_traits ➜ [string]
Get a full list of the daemon traits.
from is-daemon

get_state ➜ dictionary
Get daemon state, as saved in the state.toml file.
from is-daemon

Set daemon state. Accepts any subset of the state dictionary, dynamically.
from is-daemon

list_methods ➜ [string]
Get an array of all known public method names.
from is-daemon

Cleanly shutdown daemon.
from is-daemon

help ➜ string
If method not given, return a human-readable string with information about the daemon as a whole. If method is given, return a human-readable string with the signature of the method on the first line and a description of the method on subsequent lines. The signature is not specified to be in any particular language. It is intended for usage by humans ONLY.
from is-daemon

method, {'type': 'string'}