nem4_rs232_api.h File Reference

Application Programming Interface (API) More...

#include <csi_api.h>
+ Include dependency graph for nem4_rs232_api.h:
+ This graph shows which files directly or indirectly include this file:

Data Structures

struct  NemV4Scaling
 This data structure encapsulates data for analog input scaling. More...
 
struct  stNemesysV4
 Nemesys device object - required for Nemesys access and communication. More...
 

Typedefs

typedef struct stNemesysV4 TNemesysV4
 Nemesys device object - required for Nemesys access and communication.
 
typedef struct NemV4Scaling TNemV4Scaling
 This data structure encapsulates data for analog input scaling. More...
 

Enumerations

enum  eNemV4AnalogInput { NEM4_ANALOG_IN_EXTERNAL = 1, NEM4_ANALOG_IN_FORCE_SENSOR = 2 }
 Enumeration of Nemesys analog inputs. More...
 
enum  eNemV4ContiflowValvePositions { NEM4_CONTIFLOW_VALVE_CLOSED = 0, NEM4_CONTIFLOW_VALVE_PORT_1 = 1, NEM4_CONTIFLOW_VALVE_PORT_2 = 2, NEM4_CONTIFLOW_VALVE_OPEN = 3 }
 Enumeraion of external contiflow valve positions. More...
 
enum  eNemV4DigitalInput { NEM4_DIG_IN_EXTERNAL_1 = (1 << 16), NEM4_DIG_IN_EXTERNAL_2 = (1 << 17), NEM4_DIG_IN_EMCY_STOP = (1 << 18), NEM4_DIG_IN_SAFETY_STOP = (1 << 28) }
 Enumeration of Nemesys digital outputs. More...
 
enum  eNemV4DigitalOutput { NEM4_DIG_OUT_EXTERNAL_1 = (1 << 16), NEM4_DIG_OUT_EXTERNAL_2 = (1 << 17), NEM4_DIG_OUT_EXTERNAL_3 = (1 << 2), NEM4_DIG_OUT_BLUE_LED = (1 << 3) }
 Enumeration of all Nemesys digital outputs. More...
 
enum  eNemV4ProductType { NEMESYS_M = 6, NEMESYS_S = 7 }
 Enumeration of all supported Nemesys product types.
 

Functions

long NemV4ClearFault (TNemesysV4 *Nemesys)
 Clear fault state of Nemesys. More...
 
double NemV4DevicePosToMicrolitres (TNemesysV4 *Nemesys, int32_t Pos)
 Converts a device position in increments in a volume in microlitres. More...
 
double NemV4DevicePosToMillimetres (TNemesysV4 *Nemesys, int32_t Pos)
 Converts a Nemesys position given in increments into millimeters. More...
 
double NemV4DeviceVelToMicrolitresPerMinute (TNemesysV4 *Nemesys, int32_t Velocity)
 Converts a device velocity into a flow rate in microlitres per minute (µl/min). More...
 
double NemV4DeviceVelToMillimetresPerMinute (TNemesysV4 *Nemesys, int32_t Velocity)
 Converts a device velocity value to a speed value in mm/min. More...
 
long NemV4DevInit (struct CsiBus *Bus, uint8_t NodeId, TNemesysV4 *Nemesys)
 Initialize Nemesys device object with all parameters. More...
 
long NemV4DoseVolume (TNemesysV4 *Nemesys, double Volume_ul, double Flow_ul_min)
 Dose a certain volume with a certain flow rate. More...
 
long NemV4EnableForceMonitoring (TNemesysV4 *Nemesys, int Enable)
 Enable / Disable force monitoring functionality. More...
 
long NemV4GenerateFlow (TNemesysV4 *Nemesys, double Flow_ul_min)
 Generate a constant flow until syringe is empty or full. More...
 
long NemV4GetCurrentFlow (TNemesysV4 *Nemesys, double *Flow_ul_min)
 Returns the current flow in ul / min. More...
 
long NemV4GetCurrentVelocity (TNemesysV4 *Nemesys, int32_t *Velocity)
 Read the actual velocity from the Nemesys. More...
 
long NemV4GetLastDevErr (TNemesysV4 *Nemesys, int32_t *pLastDevErr)
 Read last Nemesys error from error register. More...
 
long NemV4GetMaxFlow (TNemesysV4 *Nemesys, double *Flow_ul_min)
 Returns the maximum flow in ul / min. More...
 
long NemV4GetMaxSyringeLevel (TNemesysV4 *Nemesys, double *Level_ul)
 Returns the maximum syringe level in µl. More...
 
long NemV4GetPosIs (TNemesysV4 *Nemesys, int32_t *PosIs)
 Reads the actual position from the Nemesys. More...
 
long NemV4GetSyringeLevel (TNemesysV4 *Nemesys, double *Level_ul)
 Returns the current syringe level in µl. More...
 
uint32_t NemV4IsEnabled (TNemesysV4 *Nemesys)
 Check if Nemesys is in enabled state. More...
 
uint32_t NemV4IsInFaultState (TNemesysV4 *Nemesys)
 Query fault state of Nemesys pump drive. More...
 
long NemV4IsSafetyStopActive (TNemesysV4 *Nemesys)
 Reads the safety stop input. More...
 
long NemV4IsStopped (TNemesysV4 *Nemesys)
 Checks if a dosing unit is moving or stopped. More...
 
int32_t NemV4MicrolitresPerMinuteToDeviceVel (TNemesysV4 *Nemesys, double Flow_ul_min)
 Converts a flow rate in microlitres per minute (µl/min) into a device velocity. More...
 
int32_t NemV4MicrolitresToDevicePos (TNemesysV4 *Nemesys, double Volume_ul)
 Converts a volume in microlitres into a device position in increments. More...
 
int32_t NemV4MillimetresPerMinuteToDeviceVel (TNemesysV4 *Nemesys, double Speed_mm_min)
 Converts a velocity in mm/in into a device velocity. More...
 
int32_t NemV4MillimetresToDevicePos (TNemesysV4 *Nemesys, double Pos_mm)
 Converts a position in mm into a Nemesys position in increments. More...
 
long NemV4MoveDistance (TNemesysV4 *Nemesys, int32_t Distance, uint32_t Velocity)
 Moves the pusher a certain distance from the current position. More...
 
long NemV4MoveToPos (TNemesysV4 *Nemesys, int32_t PosAbs, uint32_t Velocity)
 Move pusher to a certain position. More...
 
long NemV4MoveWithVelocity (TNemesysV4 *Nemesys, int32_t Velocity)
 Moves the syringe pusher with the given velocity. More...
 
long NemV4ReadAnalogInput (TNemesysV4 *Nemesys, enum eNemV4AnalogInput Input, int16_t *Value_mV)
 Reads the analog input value of the given Input and returns it in Value_mV. More...
 
long NemV4ReadDigitalInput (TNemesysV4 *Nemesys, enum eNemV4DigitalInput Input)
 Reads the state of one single digital input. More...
 
long NemV4ReadDigitalInputs (TNemesysV4 *Nemesys, uint32_t *Inputs)
 Reads all 4 digital inputs from the device and returns the inputs bitmask in Inputs. More...
 
long NemV4ReadForceSensor (TNemesysV4 *Nemesys, float *Force_kN)
 Reads the internal force sensor value scaled to kN. More...
 
long NemV4ReadStatusWord (TNemesysV4 *Nemesys, uint16_t *pwStatusWord)
 Read status word from Nemesys. More...
 
long NemV4SetEnabled (TNemesysV4 *Nemesys)
 Set single dosing unit into enable state. More...
 
void NemV4SetSyringe (TNemesysV4 *Nemesys, double InnerSyringeDiameter_mm)
 Configure the syringe that is used for flow and volume unit conversion. More...
 
long NemV4SetSyringeLevel (TNemesysV4 *Nemesys, double Level_ul, double Flow_ul_min)
 Set syringe to a certain fill level. More...
 
long NemV4Stop (TNemesysV4 *Nemesys)
 Stops the current dosing move. More...
 
long NemV4SwitchValve (TNemesysV4 *Nemesys, uint8_t ValvePosition)
 Switches a valve connected to the Nemesys I/O connector to a given position. More...
 
long NemV4WriteDigitalOutput (TNemesysV4 *Nemesys, enum eNemV4DigitalOutput Output, uint8_t On)
 Switches one single digital output channel on/off. More...
 
long NemV4WriteDigitalOutputs (TNemesysV4 *Nemesys, uint32_t OutputMask, uint32_t States)
 Switches the given digital outputs on/off. More...
 
long NemV4WriteForceLimit (TNemesysV4 *Nemesys, float ForceLimit_kN)
 Sets a custom force limit. More...
 

Detailed Description

Application Programming Interface (API)

Author
Uwe Kindler (UK)
Date
2021/04/12