SimpleFOClibrary  2.1
BLDCDriver6PWM Class Reference

#include <BLDCDriver6PWM.h>

Inheritance diagram for BLDCDriver6PWM:
BLDCDriver

Public Member Functions

 BLDCDriver6PWM (int phA_h, int phA_l, int phB_h, int phB_l, int phC_h, int phC_l, int en=NOT_SET)
 
int init () override
 
void disable () override
 
void enable () override
 
void setPwm (float Ua, float Ub, float Uc) override
 
virtual void setPhaseState (int sa, int sb, int sc) override
 

Public Attributes

int pwmA_h
 
int pwmA_l
 phase A pwm pin number More...
 
int pwmB_h
 
int pwmB_l
 phase B pwm pin number More...
 
int pwmC_h
 
int pwmC_l
 phase C pwm pin number More...
 
int enable_pin
 enable pin number More...
 
float dead_zone
 a percentage of dead-time(zone) (both high and low side in low) for each pwm cycle [0,1] More...
 
- Public Attributes inherited from BLDCDriver
long pwm_frequency
 pwm frequency value in hertz More...
 
float voltage_power_supply
 power supply voltage More...
 
float voltage_limit
 limiting voltage set to the motor More...
 
float dc_a
 currently set duty cycle on phaseA More...
 
float dc_b
 currently set duty cycle on phaseB More...
 
float dc_c
 currently set duty cycle on phaseC More...
 

Detailed Description

6 pwm bldc driver class

Definition at line 13 of file BLDCDriver6PWM.h.

Constructor & Destructor Documentation

◆ BLDCDriver6PWM()

BLDCDriver6PWM::BLDCDriver6PWM ( int  phA_h,
int  phA_l,
int  phB_h,
int  phB_l,
int  phC_h,
int  phC_l,
int  en = NOT_SET 
)

BLDCDriver class constructor

Parameters
phA_hA phase pwm pin
phA_lA phase pwm pin
phB_hB phase pwm pin
phB_lA phase pwm pin
phC_hC phase pwm pin
phC_lA phase pwm pin
enenable pin (optional input)

Definition at line 3 of file BLDCDriver6PWM.cpp.

Member Function Documentation

◆ disable()

void BLDCDriver6PWM::disable ( )
overridevirtual

Motor disable function

Implements BLDCDriver.

Definition at line 33 of file BLDCDriver6PWM.cpp.

◆ enable()

void BLDCDriver6PWM::enable ( )
overridevirtual

Motor enable function

Implements BLDCDriver.

Definition at line 25 of file BLDCDriver6PWM.cpp.

◆ init()

int BLDCDriver6PWM::init ( )
overridevirtual

Motor hardware init function

Implements BLDCDriver.

Definition at line 43 of file BLDCDriver6PWM.cpp.

◆ setPhaseState()

void BLDCDriver6PWM::setPhaseState ( int  sa,
int  sb,
int  sc 
)
overridevirtual

Set phase voltages to the harware

Parameters
sc- phase A state : active / disabled ( high impedance )
sb- phase B state : active / disabled ( high impedance )
sa- phase C state : active / disabled ( high impedance )

Implements BLDCDriver.

Definition at line 83 of file BLDCDriver6PWM.cpp.

◆ setPwm()

void BLDCDriver6PWM::setPwm ( float  Ua,
float  Ub,
float  Uc 
)
overridevirtual

Set phase voltages to the harware

Parameters
Ua- phase A voltage
Ub- phase B voltage
Uc- phase C voltage

Implements BLDCDriver.

Definition at line 66 of file BLDCDriver6PWM.cpp.

Member Data Documentation

◆ dead_zone

float BLDCDriver6PWM::dead_zone

a percentage of dead-time(zone) (both high and low side in low) for each pwm cycle [0,1]

Definition at line 41 of file BLDCDriver6PWM.h.

◆ enable_pin

int BLDCDriver6PWM::enable_pin

enable pin number

Definition at line 39 of file BLDCDriver6PWM.h.

◆ pwmA_h

int BLDCDriver6PWM::pwmA_h

Definition at line 36 of file BLDCDriver6PWM.h.

◆ pwmA_l

int BLDCDriver6PWM::pwmA_l

phase A pwm pin number

Definition at line 36 of file BLDCDriver6PWM.h.

◆ pwmB_h

int BLDCDriver6PWM::pwmB_h

Definition at line 37 of file BLDCDriver6PWM.h.

◆ pwmB_l

int BLDCDriver6PWM::pwmB_l

phase B pwm pin number

Definition at line 37 of file BLDCDriver6PWM.h.

◆ pwmC_h

int BLDCDriver6PWM::pwmC_h

Definition at line 38 of file BLDCDriver6PWM.h.

◆ pwmC_l

int BLDCDriver6PWM::pwmC_l

phase C pwm pin number

Definition at line 38 of file BLDCDriver6PWM.h.


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