You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/10/29 21:17:44 UTC

[GitHub] [incubator-nuttx-apps] uLipe commented on a change in pull request #867: industry/foc: add support for Hall sensor and Qencoder feedback

uLipe commented on a change in pull request #867:
URL: https://github.com/apache/incubator-nuttx-apps/pull/867#discussion_r739536104



##########
File path: include/industry/foc/foc_common.h
##########
@@ -71,6 +71,15 @@ enum foc_ramp_mode_e
   RAMP_MODE_NORMAL    = 3,      /* Normal operation */
 };
 
+/* Angle handler type */
+
+enum foc_angle_type_e
+{
+  FOC_ANGLE_TYPE_INVALID = 0,  /* Reserved */
+  FOC_ANGLE_TYPE_ELE     = 1,  /* Electrical angle */
+  FOC_ANGLE_TYPE_MECH    = 2,  /* Mechanical angle */

Review comment:
       Just adding some extra information, having the number of poles which is tipically given the foc controller is able to convert the mechanical angle into the electrical one.
   
   The only extra requirement that may have to be considered is a initial park and go alignment to keep the IQ + ID pair aligned to a initial known value and consider this offset to the account when converting mechanical into electrical angle.
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org