I'm trying to build a project with a bunch of motors so I thought I would start simple with a simple motor I got in a kit.
I have a DBH-12V motor controller...that took a while to figure out the details as there is no clear datasheet on it.
I came up with the following wiring (no idea how to insert attachment)
Picture attached shows setup.
I wrote a look that increments from 1 to 256 the value to AnalogWrite to a PWM output.
I measure the voltage and it does go from 0 to 5v
The issue is that the motor starts at 0 and gets faster (UNTIL 1.38V), it then slows down and stays constant.
The loop does a count down from 5V (its still at slow constant speed) until it hits 1V and then it speeds up a bit until starts getting near 0 which stops it.
Why would the motor not keep going faster ?
Thanks for any help
You have neglected to post details of all the hardware. That means links to datasheets or product pages, in particular we know nothing about your motor or your power supply, or what actual model motor controller you
have, "DBH-12V" is not very specific it seems.
(And it should go without saying to post your code).
Please read the post at the start of any forum , entitled "How to use this Forum".
OR http://forum.arduino.cc/index.php/topic,148850.0.html.
Then look down to item #7 about how to post your code.
It will be formatted in a scrolling window that makes it easier to read.
Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?
void setup() {
// put your setup code here, to run once:
#define PWM_M1 3
pinMode(PWM_M1, OUTPUT);
#define CURRENT_M1 A2
pinMode(CURRENT_M1, INPUT);
Serial.begin(38400, SERIAL_8N1);
}
void loop() {
// put your main code here, to run repeatedly:
int current;
for (int i = 0; i <= 255; i++) {
analogWrite(PWM_M1, i);
Serial.print("Motor input:");
Serial.print(i);
Serial.print(" Current Sense:");
delay(100);
current = analogRead(CURRENT_M1);
Serial.println(current);
}
i did put a current meter in series with the motor and it tops out at about .85A and then it drops down to about .45A (even though the input voltage keeps increasing)
Hello,
I bet you'll not coming that soon to ask an other question ..
That's how i like forums... you ask something and locals just ask you questions in return (that are not mandatory).. just cause they like it that way ..