![]() |
SimpleFOClibrary 2.4.0
|
#include "Arduino.h"#include "Sensor.h"#include "CurrentSense.h"#include "../time_utils.h"#include "../foc_utils.h"#include "../defaults.h"#include "../pid.h"#include "../lowpass_filter.h"Go to the source code of this file.
Classes | |
| class | FOCMotor |
Macros | |
| #define | MOT_ERR "ERR-MOT:" |
| #define | MOT_WARN "WARN-MOT:" |
| #define | MOT_DEBUG "MOT:" |
| #define | SIMPLEFOC_MOTOR_WARN(msg, ...) |
| #define | SIMPLEFOC_MOTOR_ERROR(msg, ...) |
| #define | SIMPLEFOC_MOTOR_DEBUG(msg, ...) |
| #define | _MON_TARGET 0b1000000 |
| #define | _MON_VOLT_Q 0b0100000 |
| #define | _MON_VOLT_D 0b0010000 |
| #define | _MON_CURR_Q 0b0001000 |
| #define | _MON_CURR_D 0b0000100 |
| #define | _MON_VEL 0b0000010 |
| #define | _MON_ANGLE 0b0000001 |
Enumerations | |
| enum | MotionControlType : uint8_t { torque = 0x00 , velocity = 0x01 , angle = 0x02 , velocity_openloop = 0x03 , angle_openloop = 0x04 , angle_nocascade = 0x05 , custom = 0x06 } |
| enum | TorqueControlType : uint8_t { voltage = 0x00 , dc_current = 0x01 , foc_current = 0x02 , estimated_current = 0x03 } |
| enum | FOCModulationType : uint8_t { SinePWM = 0x00 , SpaceVectorPWM = 0x01 , Trapezoid_120 = 0x02 , Trapezoid_150 = 0x03 } |
| enum | FOCMotorStatus : uint8_t { motor_uninitialized = 0x00 , motor_initializing = 0x01 , motor_uncalibrated = 0x02 , motor_calibrating = 0x03 , motor_ready = 0x04 , motor_error = 0x08 , motor_calib_failed = 0x0E , motor_init_failed = 0x0F } |
| #define _MON_ANGLE 0b0000001 |
Definition at line 44 of file FOCMotor.h.
| #define _MON_CURR_D 0b0000100 |
Definition at line 42 of file FOCMotor.h.
| #define _MON_CURR_Q 0b0001000 |
Definition at line 41 of file FOCMotor.h.
| #define _MON_TARGET 0b1000000 |
Definition at line 38 of file FOCMotor.h.
| #define _MON_VEL 0b0000010 |
Definition at line 43 of file FOCMotor.h.
| #define _MON_VOLT_D 0b0010000 |
Definition at line 40 of file FOCMotor.h.
| #define _MON_VOLT_Q 0b0100000 |
Definition at line 39 of file FOCMotor.h.
| #define MOT_DEBUG "MOT:" |
Definition at line 16 of file FOCMotor.h.
| #define MOT_ERR "ERR-MOT:" |
Definition at line 14 of file FOCMotor.h.
| #define MOT_WARN "WARN-MOT:" |
Definition at line 15 of file FOCMotor.h.
| #define SIMPLEFOC_MOTOR_DEBUG | ( | msg, | |
| ... | |||
| ) |
Definition at line 27 of file FOCMotor.h.
| #define SIMPLEFOC_MOTOR_ERROR | ( | msg, | |
| ... | |||
| ) |
Definition at line 23 of file FOCMotor.h.
| #define SIMPLEFOC_MOTOR_WARN | ( | msg, | |
| ... | |||
| ) |
Definition at line 19 of file FOCMotor.h.
| enum FOCModulationType : uint8_t |
FOC modulation type
| Enumerator | |
|---|---|
| SinePWM | Sinusoidal PWM modulation. |
| SpaceVectorPWM | Space vector modulation method. |
| Trapezoid_120 | |
| Trapezoid_150 | |
Definition at line 72 of file FOCMotor.h.
| enum FOCMotorStatus : uint8_t |
Definition at line 81 of file FOCMotor.h.
| enum MotionControlType : uint8_t |
Motion control type
Definition at line 49 of file FOCMotor.h.
| enum TorqueControlType : uint8_t |
Motiron control type
Definition at line 62 of file FOCMotor.h.