Motion Master
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
OffsetDetection Class Reference

#include <offset_detection.h>

Public Types

enum class  State { kMissing , kInProgress , kFound }
 

Public Member Functions

 OffsetDetection (Cia402Drive &cia402_drive)
 
MotionMasterError start ()
 Start the automatic offset detection. More...
 
MotionMasterError wait ()
 Once the offset detection process was started, this function must be used to wait for it to finish. More...
 
int32_t get_commutation_offset ()
 Get the current commutation offset. More...
 

Member Enumeration Documentation

◆ State

enum class OffsetDetection::State
strong
Enumerator
kMissing 
kInProgress 
kFound 

Constructor & Destructor Documentation

◆ OffsetDetection()

OffsetDetection::OffsetDetection ( Cia402Drive cia402_drive)
explicit

Member Function Documentation

◆ get_commutation_offset()

int32_t OffsetDetection::get_commutation_offset ( )

Get the current commutation offset.

Returns
the commutation offset

◆ start()

MotionMasterError OffsetDetection::start ( )

Start the automatic offset detection.

If the procedure was finished successfully, the calculated offset will be saved to the proper OD entry (0x2007:2)

Returns
error

◆ wait()

MotionMasterError OffsetDetection::wait ( )

Once the offset detection process was started, this function must be used to wait for it to finish.

Returns
error

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