Skip to content

Commit

Permalink
DMA for ADC implemented, mbed Ticker removed, files restructured
Browse files Browse the repository at this point in the history
- DMA partly uses ST HAL API (to be improved in further versions)
- When using mbed ticker to trigger ADC, the program might stall --> use own timer instead
- C++ libraries changed to more simple C-style functions and files (better compatibility with plain C environments)
  • Loading branch information
martinjaeger committed Mar 10, 2018
1 parent efa5ac2 commit 4aa51fb
Show file tree
Hide file tree
Showing 25 changed files with 815 additions and 1,114 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
.vscode/c_cpp_properties.json
.vscode/launch.json
.vscode/*.db
.vscode/.browse.c_cpp.db*
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# MPPT Charger Software
Software based on ARM mbed library for the LibreSolar 20 A MPPT solar charge controller

## Important remarks

- Do **not** use mbed Ticker class, as it disturbs the timer settings and might cause the charge controller to crash. In addition to that, it contains a lot of overhead and is not very efficient. Timers should be programmed bare metal. Currently, TIM1 is used for PWM generation and TIM15 to trigger ADC readings.

## State machine in class ChargeController

The charge management is implemented using a state machine with the following states:
Expand Down
60 changes: 0 additions & 60 deletions lib/AnalogValue/AnalogValue.cpp

This file was deleted.

95 changes: 0 additions & 95 deletions lib/AnalogValue/AnalogValue.h

This file was deleted.

170 changes: 0 additions & 170 deletions lib/ChargeController/ChargeController.cpp

This file was deleted.

0 comments on commit 4aa51fb

Please sign in to comment.