mirror of https://github.com/rusefi/bldc.git
Merge branch 'master' into dev_fw_5_03
This commit is contained in:
commit
93b405add9
|
@ -85,8 +85,8 @@ When making updates it is easy to break things for different configurations. In
|
|||
|
||||
=== Other guidelines ===
|
||||
|
||||
* Use single precition floating point operations, as the FPU in the STM32F4 is 32 bits only. Double precision operations can take up to 50 times (!) longer.
|
||||
- float instead if double
|
||||
* Use single precision floating point operations, as the FPU in the STM32F4 is 32 bits only. Double precision operations can take up to 50 times (!) longer.
|
||||
- float instead of double
|
||||
- Use the math library functions ending with f (sinf, cosf, powf, fabsf etc.)
|
||||
|
||||
* Make sure that the code compiles without warnings.
|
||||
|
@ -94,7 +94,7 @@ When making updates it is easy to break things for different configurations. In
|
|||
* Avoid dynamic memory allocation if possible, so that the RAM usage is known at compile time.
|
||||
|
||||
* If the code crashed randomly, use the ChibiOS state checker:
|
||||
http://www.chibios.org/dokuwiki/doku.php?id=chibios:articles:state_checker
|
||||
https://www.chibios.org/dokuwiki/doku.php?id=chibios:documentation:books:rt:kernel_debug#system_state_checks
|
||||
|
||||
|
||||
=== Be patient, and don't take criticism personally ===
|
||||
|
|
|
@ -1439,6 +1439,10 @@ float mcpwm_foc_get_vq(void) {
|
|||
* @param current
|
||||
* The locking open loop current for the motor.
|
||||
*
|
||||
* @param print
|
||||
* Controls logging during the detection procedure. Set to true to enable
|
||||
* logging.
|
||||
*
|
||||
* @param offset
|
||||
* The detected offset.
|
||||
*
|
||||
|
@ -1447,6 +1451,10 @@ float mcpwm_foc_get_vq(void) {
|
|||
*
|
||||
* @param direction
|
||||
* The detected direction.
|
||||
*
|
||||
* @param inverted
|
||||
* Is set to true if the encoder reports an increase in angle in the opposite
|
||||
* direction of the motor.
|
||||
*/
|
||||
void mcpwm_foc_encoder_detect(float current, bool print, float *offset, float *ratio, bool *inverted) {
|
||||
mc_interface_lock();
|
||||
|
|
Loading…
Reference in New Issue