You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Encoder channels `A` and `B` are connected to the Arduino's external intrrupt pins `2` and `3`.
63
+
- Optionally if your encoder has `index` signal you can connect it to any available pin, figure shows pin `4`.
64
+
- The librtary doesnt support the Index pin for now (version v1.1.0)
65
+
#### L6234 breakout board
66
+
- Connected to the arduino pins `9`,`10` and `11`.
67
+
- Additionally you can connect the `enable` pin to the any digital pin of the arduino the picture shows pin `8` but this is optional. You can connect the driver enable directly to 5v.
68
+
- Make sure you connect the common ground of the power supply and your Arduino
69
+
##### Motor
70
+
- Motor phases `a`, `b` and `c` are connected directly to the driver outputs
71
+
- Motor phases `a`,`b`,`c` and encoder channels `A` and `B` have to be oriented right for the algorightm to work. But don't worry about it too much. Connect it in initialy as you wish and then if it doesnt move reverse pahse `a` and `b` of the motor, that should be enogh.
72
+
73
+
74
+
### HMBGC V2.2
75
+
To use HMBGC controller for vector control (FOC) you need to connect motor to one of the motor terminals and connect the Encoder. The shema of connection is shown on the figures above, I also took a (very bad) picture of my setup.
To use HMBGC controller for vector control (FOC) you need to connect motor to one of the motor terminals and connect the Encoder. The shema of connection is shown on the figures above, I also took a (very bad) picture of my setup.
81
+
82
+
83
+
#### Encoder
84
+
- Since HMBGC doesn't have acces to the arduinos external interrupt pins `2` and `3` and additionally we only have acces to the analog pins, we need to read the encoder
85
+
- Optionally if your encoder has `index` signal you can connect it to any available pin, figure shows pin `4`.
86
+
- The librtary doesnt support the Index pin for now (version v1.1.0)
87
+
- L6234 breakout board is connected to the arduino pins `9`,`10` and `11`.
88
+
- Additionally you can connect the `enable` pin to the any digital pin of the arduino the picture shows pin `8` but this is optional. You can connect the driver enable directly to 5v.
89
+
- Motor is connected directly to the driver outputs
90
+
- Make sure you connect the common ground of the power supply and your Arduino
91
+
Motor phases `a`,`b`,`c` and encoder channels `A` and `B` have to be oriented right for the algorightm to work. But don't worry about it too much. Connect it in initialy as you wish and then if it doesnt move reverse pahse `a` and `b` of the motor, that should be enogh.
92
+
93
+
94
+
64
95
65
96
## The code
66
97
The code is organised in two libraries, BLDCmotor.h and endcoder.h. BLDCmotor.h contains all the necessary FOC funciton implemented and encoder.h deals with the encoder. I will make this better in future. :D
0 commit comments