MotionLib  1.0.0
SamBuCa motion library
Public Member Functions | List of all members
edge::MEdgeGrblDevice Class Reference
Inheritance diagram for edge::MEdgeGrblDevice:
Inheritance graph
[legend]
Collaboration diagram for edge::MEdgeGrblDevice:
Collaboration graph
[legend]

Public Member Functions

 MEdgeGrblDevice (int lun, const std::string &driverPath=std::string())
 Construct a new EdgeGrblDevice. More...
 
- Public Member Functions inherited from grbl::MGrblDeviceBase< edge::EdgeGrblDeviceBase >
grbl::ErrorCode send (const std::string &cmd, std::function< bool(const std::string &)> msg={}, const std::chrono::milliseconds &timeout=GrblDeviceBase::defaultSendTimeout) override
 
- Public Member Functions inherited from edge::EdgeGrblDeviceBase
 EdgeGrblDeviceBase (int lun, const std::string &driverPath=std::string())
 Construct a new EdgeGrblDevice. More...
 
void read () override
 fill LineBuffer with incoming bytes
 
void write (const std::string &data) override
 raw write some bytes More...
 
bool wait (const std::chrono::milliseconds &timeout) override
 wait for input More...
 
void wake () override
 wake thread waiting for input
 
void read (struct edge_reg *reg, uint32_t &value)
 Get a register value. More...
 
void read (struct edge_reg *reg, size_t offset, uint32_t &value)
 Get a register value at depth. More...
 
void read (struct edge_reg *reg, std::vector< uint32_t > &values)
 Get all registers. More...
 
void write (struct edge_reg *reg, uint32_t value)
 Write a value to register. More...
 
void write (struct edge_reg *reg, size_t offset, uint32_t value)
 Write a value to register. More...
 
struct fmc_mfe_hdl * getDrv () const
 get driver handler
 
- Public Member Functions inherited from grbl::GrblDeviceBase
void fetch (const std::chrono::milliseconds &timeout)
 wait for data and process it More...
 
virtual grbl::ErrorCode sendRealtime (const std::string &cmd, std::function< bool(const std::string &)> msg={}, const std::chrono::milliseconds &timeout=defaultSendTimeout)
 send a realtime-command wait for reply More...
 
virtual bool takeLine (std::string &line)
 consume line from buffer More...
 

Additional Inherited Members

- Public Attributes inherited from grbl::GrblDeviceBase
ccut::Signal< std::string > dataSignal
 
- Static Public Attributes inherited from grbl::GrblDeviceBase
static const std::chrono::milliseconds defaultSendTimeout
 
- Protected Member Functions inherited from edge::EdgeGrblDeviceBase
void init (int lun, const std::string &driverPath)
 
void irqLoop ()
 Wait for irq using blocking API and set variables once available.
 
bool waitIrq (const std::chrono::milliseconds &timeout, const struct edge_reg *const expectedReg, uint32_t expectedBit)
 Wait for irq from given source. More...
 
void drvOpen (int lun, const std::string &simPath, bool isSim)
 Open FMC_MFE device with given driver. More...
 
void drvClose ()
 Close the driver.
 
- Protected Attributes inherited from edge::EdgeGrblDeviceBase
int m_wakeFd [2]
 
struct fmc_mfe_hdl * m_edgeDrvHdl
 
std::vector< char > m_fifoBytes
 
- Protected Attributes inherited from grbl::GrblDeviceBase
ccut::LineBuffer m_buffer
 
- Static Protected Attributes inherited from edge::EdgeGrblDeviceBase
static const std::string loggerCat {"edge:edgegrbldevice"}
 

Detailed Description

Definition at line 38 of file MEdgeGrblDevice.hpp.

Constructor & Destructor Documentation

◆ MEdgeGrblDevice()

edge::MEdgeGrblDevice::MEdgeGrblDevice ( int  lun,
const std::string &  driverPath = std::string() 
)
explicit

Construct a new EdgeGrblDevice.

Parameters
lunLUN to use
driverPathPath of the sim library (leave empty for non-sim)

Definition at line 43 of file MEdgeGrblDevice.cpp.


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