Hello,
for my project I need PID control of speed / rpm of small DC motor.
I have these parts:
-
MakeBlock Orion based on Arduino Uno - http://learn.makeblock.cc/orion/ and http://learn.makeblock.cc/learn/images/Makeblock_Orion_Pin.png . Or I can use Arduino, it is good solution for me, too. But I prefer MakeBlack Orion as its red ports support 12V.
-
Motor with encoder - http://www.makeblock.cc/optical-encoder-motor-25-6v-185rpm/
-
Encoder driver - http://www.makeblock.cc/me-encoder-motor-driver/ - it connects to red port of MakeBlock Orion, then it is possible to use this API for motor control - http://learn.makeblock.cc/api-documentation-of-me-encoder-motor/ - but I would like to make my own PID control, for example using this library http://playground.arduino.cc/Code/PIDLibrary . Maybe this encoder drive will not be needed.
Here is general library for MakeBlock - https://github.com/Makeblock-official/Makeblock-Library
So I need to read/detect rpm of the motor for feedback to provide appropriate output of controller. I would like to as how to start. Now I do not know to which pin should I supply PWM signal and how to read rpm of motor from encoder (this can be made using API for Me encoder motor which I mentioned).
Thank you for your help.