Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
2.1. Lipo Singe Cell Monitor
#Description This is a DIY LiPo cell monitoring solution which can be included as an AddOn to this project. Enabling the AddOn code will increase the teensy's functionality, allowing the teensy pins A0 to A5(6S Lipo) to be used to connect a DIY built voltage divider resistor network. Theoretically it is possible to use more pins (A0 to A11) to monitor up to a 12S LiPo. We currently test up to 6S successfully with two decimal places of precision.
If connecting the lipo balancer plug to your teensy, it will be important to divide all lipo-cell voltage outputs to a value <= 3,3V.
##Example for an full 6S Lipo(25,2V):
|LipoCell||Voltage||R1 in series to cell||R2 to gnd||software divider 13bit|
All needed resistors found in E24 series. If you use other resistors all dividers must recalculated.
The default dividers are defined in LSCM.h, but do not edit here. Use lscm.setCustomCellDivider funktion to set dividers properly.
##Setup LSCM To get LSCM working correct you should setup MAXCELLS in MavLink_FrSkySPort.ino to a corresponding value for your lipo.
- 2S Lipo =>
#define MAXCELLS 2
- 3S Lipo =>
#define MAXCELLS 3
- 4S Lipo =>
#define MAXCELLS 4
- 5S Lipo =>
#define MAXCELLS 5
- 6S Lipo =>
#define MAXCELLS 6
You should also evaluate if the default divider match to your use resistor network. You can check this bye checking voltage values are displayed correct on your Taranis. If it doesn´t match please recalculate them and set new values with lscm.setCustomCellDivider funktion
- search for lscm.setCustomCellDivider in MavLink_FrSkySPort.ino
- uncomment it and set it like in the example shown
- lscm.setCustomCellDivider(1905.331599479, 929.011553273, 615.667808219); // This is an example for three cells
##Wiring (Teensy 3.0, 3.1, 3.2, LC):
![Lipo Network Wiring](https://raw.githubusercontent.com/Clooney82/MavLink_FrSkySPort/s-c-l-v-rc-opentx2.1/images/Wiring - Resistor Network.jpg)