]> rtime.felk.cvut.cz Git - fpga/rpi-motor-control.git/blobdiff - pmsm-control/test_sw/pmsm_state.h
Correct typo in rpi-mc-1 mapping to Ti AM437x based RICO board.
[fpga/rpi-motor-control.git] / pmsm-control / test_sw / pmsm_state.h
index b1946a653b2a0bfd07aa797cef97be942089bb23..47401d8f9e4d7eb9e169fcceb7c7342ad3537054 100644 (file)
@@ -49,6 +49,10 @@ struct rpi_state{
 
        void (*main_commutator)(struct rpi_state*);     /* primarni komutator */
        void (*main_controller)(struct rpi_state*);     /* primarni regulator */
+
+       char error;                     /* detekce chyboveho stavu */
+
+       int8_t h1_old,h2_old,h3_old;    /* stare hodnoty hallu */
 };
 
 /**
@@ -71,4 +75,19 @@ inline void setCommutationOn(struct rpi_state*);
  */
 inline void setCommutationOff(struct rpi_state*);
 
+/**
+ * Turn on speed regulation.
+ */
+inline void setRegulationSpeed(struct rpi_state*);
+
+/**
+ * \brief Turn on position regulation
+ */
+inline void setRegulationPos(struct rpi_state*);
+
+/**
+ * \brief Turn off regulation.
+ */
+inline void setRegulationOff(struct rpi_state*);
+
 #endif /*PMSM_STATE*/