Skip to content

Commit

Permalink
[Docs] Update BLDC docs
Browse files Browse the repository at this point in the history
  • Loading branch information
sahil-kale committed Jan 6, 2024
1 parent afb9df5 commit 8e50a97
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 31 deletions.
3 changes: 2 additions & 1 deletion Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -1018,7 +1018,8 @@ FILTER_SOURCE_PATTERNS =
# (index.html). This can be useful if you have a project on for instance GitHub
# and want to reuse the introduction page also for the doxygen output.

USE_MDFILE_AS_MAINPAGE =
INPUT += README.md
USE_MDFILE_AS_MAINPAGE = README.md

#---------------------------------------------------------------------------
# Configuration options related to source browsing
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ The following were, at one point, WIP, but are deprioritized in favour of a focu
- Brushed Motor (Torque and Open-Loop Speed)

## Library Architecture
![High Level Architecture](https://github.com/sahil-kale/basilisk-actuator-control-lib/assets/32375512/a86fd9e6-1148-4635-a11f-be8f48c2e8cb)
<img src="assets/HighLevelArch.png" width="500">

The components shown in blue are implemented in this library; the user must implement the other modules as per their application. This affords flexibility when implementing the library as the user can adapt the various modules as required by the specific application.

Expand Down
Binary file added assets/HighLevelArch.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 18 additions & 0 deletions control_loop/bldc/foc/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
## Field Oriented Control Loop
The FOC control loop is capable of controlling a 3-phase motor by applying a desired current vector induced by the stator. A typical FOC control loop is shown below and generally follows what is implemented by this library:
![Typical Sensored FOC](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/typicalfoc.png)

Note that this control loop is capable of using multiple rotor position estimators, enabling sensorless fallback operation if desired (in addition to fully sensorless capability). See the API for further information, alongside the unit tests.

### State Machine
A visual diagram of the state transition and associated conditions for the FOC control loop is shown below:

![State Machine](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/BrushlessFOCStateMachine.png)

### Control Flow
A high-level control flow diagram of the top-level control loop is shown below, alongside the control flow for the FOC current controller flow diagram.
![High level control flow diagram](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/BrushlessFOCHighLevelControlFlow.png)
![FOC Current Control Flow](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/BrushlessFOC_FOCControlFlow_.png)

### Phase Estimation Control Law
TBC and linked.
31 changes: 2 additions & 29 deletions control_loop/bldc/readme.md
Original file line number Diff line number Diff line change
@@ -1,36 +1,9 @@
# Brushless Control Loop
# 3 Phase Control Loops
## Overview
The brushless control loops are intended to enable FOC and trapezoidal control of Permenant-Magnet Synchronous and Brushless DC motors (PMSM and BLDC). A note that while the terminology of 'BLDC' is adopted throughout the codebase, the field oriented control technique can generally be employed on both PMSM and BLDC motors by assuming the back-emf waveform of the latter to be generally sinusoidal.

Two control loops are defined:
`BrushlessFOCControlLoop`, which enables field oriented control of a BLDC motor.
`Brushless6StepControlLoop`, which enables trapezoidal control of a BLDC motor.

The specific API for both of these control loops can be found [here](https://sahil-kale.github.io/basilisk-actuator-control-lib/annotated.html).

Background info: TBC

## 6 Step Control Loop

## FOC Control Loop
The FOC control loop is capable of controlling a 3-phase motor by applying a desired current vector induced by the stator. A typical FOC control loop is shown below and generally follows what is implemented by this library:
![Typical Sensored FOC](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/typicalfoc.png)

Note that this control loop is capable of using multiple rotor position estimators, enabling sensorless fallback operation if desired (in addition to fully sensorless capability). See the API for further information, alongside the unit tests.

### State Machine
A visual diagram of the state transition and associated conditions for the FOC control loop is shown below:

![State Machine](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/BrushlessFOCStateMachine.png)

### Control Flow
A high-level control flow diagram of the top-level control loop is shown below, alongside the control flow for the FOC current controller flow diagram.
![High level control flow diagra,](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/BrushlessFOCHighLevelControlFlow.png)
![FOC Current Control Flow](https://github.com/sahil-kale/basilisk-actuator-control-lib/blob/main/assets/BrushlessFOC_FOCControlFlow_.png)

## Rotor Estimator
### Sensorless FOC
A rotor flux observer is currently implemented for sensorless FOC. Further information about the implementation can be found in `docs/sensorless_foc.md`

### Phase Estimation Control Law
TBC and linked.
The specific API for both of these control loops can be found [here](https://sahil-kale.github.io/basilisk-actuator-control-lib/annotated.html), with further information contained in the `readme.md` inside the respective subfolders.
7 changes: 7 additions & 0 deletions control_loop/bldc/rotor_estimator/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## Rotor Estimator
The BLDC control loops require a way of knowing the rotor position in order to properly commutate the motor. This is done via an implementation of a `ElectricalRotorPosEstimator`, which can provide the control loops with the electrical angle to perform the relevant commutation on.

Documentation surrounding the electrical rotor position estimator can be found here: [Electrical Rotor Position Documentation](https://sahil-kale.github.io/basilisk-actuator-control-lib/classbldc__rotor__estimator_1_1ElectricalRotorPosEstimator.html).

### Sensorless FOC
A rotor flux observer is currently implemented for sensorless FOC. Further information about the implementation can be found in `sensorless_foc.md`
File renamed without changes.

0 comments on commit 8e50a97

Please sign in to comment.