Troubleshooting Linear Actuator with Uno

Hi Arduino Community,

I have a project involving two linear actuators and an Arduino Uno:

1x 18" stroke

1x 6" stroke

The 18" actuator is raising/lowering a monitor on a cable/pulley. The 6" actuator is raising/lowering a smaller/lighter secret compartment in the cabinet I'm building - also on a cable/pulley.

They are powered using a 10A 12v power supply. Power is distributed using simple power distribution board, and a 5v 8-channel relay module. I would include the links but I can only include two as a new user.

I'm using a wiring technique detailed by the site where I got the 18" stroke actuator where you use two SPDT relays instead of one DPDT relay. The power and ground are wired to the NO/NC terminals of one relay, and then those terminals are also connected to the corresponding terminals on the second relay. This mirrors the double-pole attribute.

In the code below, I trigger the actuator using a button. When the button is pressed, a signal is sent to the relay providing current to the actuator, then a delay is set (I will ultimately use millis() once I get everything working). Once the delay is done, I signal the relay to stop the flow of current to the actuator.

My challenge is this:
The 6" actuator works fine. The 18" actuator also works fine when it's lowering the monitor. When the 18" actuator raises the monitor, however, it will sometimes make a small movement at the beginning of each second of the delay, and then not move for the remainder of the second. E.g. if they delay is set for 6000 milliseconds, it will move a total of six times - once at the top of each second of the delay - rather than smooth continuous motion for the 6 seconds.

I assume this has to do with the amount of current being supplied to the actuator, but the power supply provides 10A, and the max draw of the 18" actuator is 4A. I assume other components I'm using wouldn't provide enough resistance, or dilute the current enough to drop it below 4A, so I'm totally at a loss. Could someone please help? I've tried to include a simple schematic detailing the wiring of the 18" actuator as well as the code I'm using to test it. Thanks in advance.

circuit

int k7_signal = 11;
int k8_signal = 12;

int button = 8;

bool extended = false;

void setup() {
  // put your setup code here, to run once:
  pinMode(button, INPUT_PULLUP);
   
  pinMode(k7_signal, OUTPUT); 
  pinMode(k8_signal, OUTPUT);
   
  digitalWrite(k7_signal, LOW);    
  digitalWrite(k8_signal, LOW); 
}

void loop() {
  // put your main code here, to run repeatedly:
  if(digitalRead(button) == LOW){
    if(extended == false){
      digitalWrite(k7_signal, LOW);
      digitalWrite(k8_signal, HIGH);
      delay(6000);
      digitalWrite(k7_signal, LOW);
      digitalWrite(k8_signal, LOW);
      extended = true;
    }else{
      digitalWrite(k7_signal, HIGH);
      digitalWrite(k8_signal, LOW);
      delay(6000);
      digitalWrite(k7_signal, LOW);
      digitalWrite(k8_signal, LOW);
      extended = false;
    }
    
  }

}

Adding the links for the power distribution board, relay module

, and power supply here.

Welcome to the forum

To post images etc you need trust level 1, you can get there by:

  • Entering at least 5 topics
  • Reading at least 30 posts
  • Spend a total of 10 minutes reading posts

Users at trust level 1 can…

  • Use all core Discourse functions; all new user restrictions are removed
  • Send PMs
  • Upload images and attachments

In fact, according to the posted specifications, 10 A at full load. And the start/stall current is quite a bit higher.

The power supply is inadequate. You will need a power supply capable of more than 20 A to run both actuators at the same time.

1 Like

Where did I even get 4A from :man_facepalming: Thank you for catching that!! Just ordered a 20A power supply :grin:

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.