Open FFBoard
Open source force feedback firmware
voltagesense.h File Reference

Go to the source code of this file.

Functions

int32_t getIntV ()
 
int32_t getExtV ()
 
void brakeCheck ()
 
void setVSenseMult (float vSenseMultiplier)
 
void setupBrakePin (uint32_t vdiffAct, int32_t vdiffDeact, int32_t vMax)
 
float adcValToVoltage (uint32_t adcval)
 
int32_t getChipTemp ()
 

Function Documentation

◆ adcValToVoltage()

float adcValToVoltage ( uint32_t  adcval)

Converts an adc reading to millivolts using the internal calibration and reference voltage Requires ADC_INTREF_VOL and VSENSE_ADC_RES

Definition at line 46 of file voltagesense.cpp.

◆ brakeCheck()

void brakeCheck ( )

Definition at line 62 of file voltagesense.cpp.

◆ getChipTemp()

int32_t getChipTemp ( )

Helper function implementation for getting the chip temperature if read via internal ADC channel __weak defined and can be overridden in chip dependent code

Definition at line 96 of file voltagesense.cpp.

◆ getExtV()

int32_t getExtV ( )

Definition at line 58 of file voltagesense.cpp.

◆ getIntV()

int32_t getIntV ( )

Definition at line 53 of file voltagesense.cpp.

◆ setupBrakePin()

void setupBrakePin ( uint32_t  vdiffAct,
int32_t  vdiffDeact,
int32_t  vMax 
)

◆ setVSenseMult()

void setVSenseMult ( float  vSenseMultiplier)

Definition at line 29 of file voltagesense.cpp.