mirror of
https://github.com/DCC-EX/CommandStation-EX.git
synced 2025-07-28 09:53:45 +02:00
current trip values on PROG depending on state
This commit is contained in:
@@ -76,6 +76,9 @@ int MotorDriver::getCurrentRaw() {
|
||||
return analogReadFast(currentPin);
|
||||
}
|
||||
|
||||
unsigned int MotorDriver::convertToMilliamps( int raw) {
|
||||
unsigned int MotorDriver::raw2mA( int raw) {
|
||||
return (unsigned int)(raw * senseFactor);
|
||||
}
|
||||
int MotorDriver::mA2raw( unsigned int mA) {
|
||||
return (int)(mA / senseFactor);
|
||||
}
|
||||
|
Reference in New Issue
Block a user