SimpleFOClibrary 2.4.0
Loading...
Searching...
No Matches
generic_mcu.cpp File Reference
Include dependency graph for current_sense/hardware_specific/generic_mcu.cpp:

Go to the source code of this file.

Functions

 __attribute__ ((weak)) float _readADCVoltageInline(const int pinA
 
 if (_isset(pinA)) pinMode(pinA
 
 if (_isset(pinB)) pinMode(pinB
 
 if (_isset(pinC)) pinMode(pinC
 

Variables

const void * cs_params
 
return raw_adc *GenericCurrentSenseParams *cs_params adc_voltage_conv
 
const int pinA
 
const int const int pinB
 
const int const int const int pinC
 
 INPUT
 
GenericCurrentSenseParamsparams
 
 return
 
return SIMPLEFOC_CURRENT_SENSE_INIT_FAILED
 

Function Documentation

◆ __attribute__()

__attribute__ ( (weak)  ) const

◆ if() [1/3]

if ( _isset(pinA )

◆ if() [2/3]

if ( _isset(pinB )

◆ if() [3/3]

if ( _isset(pinC )

Variable Documentation

◆ adc_voltage_conv

return raw_adc* GenericCurrentSenseParams* cs_params adc_voltage_conv

◆ cs_params

return cs_params
Initial value:
{
uint32_t raw_adc = analogRead(pinA)

Definition at line 5 of file current_sense/hardware_specific/generic_mcu.cpp.

◆ INPUT

INPUT

◆ params

float float PhaseState void * params
Initial value:
.pins = { pinA, pinB, pinC },
.adc_voltage_conv = (5.0f)/(1024.0f)
}
const int const int const int pinC

Definition at line 18 of file current_sense/hardware_specific/generic_mcu.cpp.

◆ pinA

const int pinA

◆ pinB

const int const int pinB

◆ pinC

const int const int const int pinC
Initial value:
{
_UNUSED(driver_params)
#define _UNUSED(v)
Definition foc_utils.h:14

Definition at line 11 of file current_sense/hardware_specific/generic_mcu.cpp.

◆ return

return

◆ SIMPLEFOC_CURRENT_SENSE_INIT_FAILED

return SIMPLEFOC_CURRENT_SENSE_INIT_FAILED