cellUview 1.0.0
A real-time image processing and analysis suite for digital microscopy.
Loading...
Searching...
No Matches
Public Member Functions | List of all members
MotorDriver Class Reference

#include <motorDriver.h>

Public Member Functions

void start (const char *device="/dev/ttyUSB0", int baud=115200)
 
void stop ()
 
int * getPosition ()
 
bool getRunning ()
 
bool getConnected ()
 
void mov (char axis, int inc)
 

Detailed Description

Class to interface with motor control board.

Member Function Documentation

◆ getConnected()

bool MotorDriver::getConnected ( )
Returns
true if motor connection could be established

◆ getPosition()

int * MotorDriver::getPosition ( )
Returns
array of 3 integer values for current x, y, and z motor positions

◆ getRunning()

bool MotorDriver::getRunning ( )
Returns
true if motors currently moving

◆ mov()

void MotorDriver::mov ( char  axis,
int  inc 
)

Public member function called by GUI class to initiate a motor movement. Updates axis and increment for movement and sets flag to wake motor thread.

◆ start()

void MotorDriver::start ( const char *  device = "/dev/ttyUSB0",
int  baud = 115200 
)

Opens serial link with motor driver board and starts motor thread.

Parameters
devicedevice id, defaults to "/dev/ttyUSB0"
baudbaud rate of serial connection, defaults to 115200

◆ stop()

void MotorDriver::stop ( )

Stops motor thread and closes serial connection.


The documentation for this class was generated from the following files: