Emergency: Automatic device that push a button every 30 minutes.

Dear all,

I'm Zakaria a total novice: I'm a bit lost, I never built an arduino before. I may post this in the wrong topic and apologizes in advance.

My problem is simple: I have a remote control with one button on it. I want to build a Arduino robot that push this button every 30 minutes. This is quite an emergency for me the well being of a loved one is at stake.

I have two questions:

  • What ressources do I need to build this kind of robot? (besides the arduino): I tought of stuff like a servomotor, a support to handle the remote, but again what kind of support? The answer of this question will allow me to order all the stuff that I need in one shot.

Do you have in mind simillar project in mind, where I can find inspiration? If so please give me a link.

Thank you in advance for you help.

Zakaria.

A novice Arduino project and an emergency with the well being of a loved one at stake is not a safe combination. You always need to think of worst case scenarios. Electrical, mechanical, software bugs are an inevitable reality in the development of a project even for a professional. If an error causes an LED blinky not lighting up or a robotic toy car turning left instead of right, no big deal. You find the bug, fix it, learn some things, and have fun. When safety is involved the stakes are much higher.

I totally agree with you. There is no safety matter on my project. I would never risk that. The only purpose of my project is to make the person's life easier.

Even in the worst case scenario: imagine that the robot push the button multiples times without stopping, it won't do any arm because the remote reacts under specific conditions. No worries.

Thank you for your reply.

If the remote control is for a TV or similar device, you might be able to use an Arduino with IR sensor to record the signal and an IR LED to play it back periodically. This is simpler than a mechanical button pushing device.

However, some remote controls use unusal signals or different frequencies so may not work with the sensors and software mentioned in the tutorial.

Onizuka:
The only purpose of my project is to make the person's life easier.

Then it's not really an emergency is it?

Delta_G:
Then it's not really an emergency is it?

I want to make his life easier as soon as I can. It is something important for me, understand it like this.

@GdSPORT, thank you for your advices. The fact is I only want to make a robot that push physically a single button in a remote control that is linked by a cable in another machine. I don't want to interact with this remote by another way than it is design for (by pushing the button). I can't get inside, because I don't want to corrupt a well design system.

Get a small servo.
Make the arduino move the servo.
Let the servo arm press the button. - That‘s the easy part.

Combine Arduino, servo and adequate power supply into a unit.
Attach the unit to the remote so the servo arm presses button.
Make it look half good, be reliable and removable. - That‘s the hard part.

(better to open the remote and take it from there...)

If the 30 minute 'threshold is IMPORTANT...

then I would suggest getting an RTC module (Real Time Clock) for the 'timing'.

The rest (and I guess even including the RTC portion) are all very beginning tutorial projects.. do a search..

Do each one separately, then work on combining.

Thank you guys for your feedback.

xl97:
then I would suggest getting an RTC module (Real Time Clock) for the 'timing'.

Can I just use delay ? It is not that bad if it is 35 minutes or 25 minutes. My error margin is pretty wide.

Thank you.

Onizuka:
Thank you guys for your feedback.

Can I just use delay ? It is not that bad if it is 35 minutes or 25 minutes. My error margin is pretty wide.

Thank you.

Nothing else will happen while you use delay(). That may, or may not, matter. You can use the blink without delay philosophy to activate the servo every half hour, give or take a minute, without burying your head in the sand.

Nothing about making a servo press a switch is even remotely complicated, from a programming point of view. The entire issue is a mounting/style problem. As Nike says, Just Do It.

Thank you Pauls. It is my first arduino project, the system is bit complicated to build, but I think I am on the right way.

I'll use a round gear attached to the mini 9g servo motor. This gear will be connected to a linear one (like a stick with cut teeth). I'm just afraid that the torque of my servo is not powerful enough.

Thank you again.

I'm just afraid that the torque of my servo is not powerful enough.

To make a rack push a switch? I can't imagine that it takes much force to press the switch.

It sounds like you are making a rack-and-pinion device.

Yeah that is exactly it. I didn't know this set up was called rack-and-pinion; thanks.

I'll show you guys the final result.

Hello guys, I'm struggling with my code.

I want my servo following those steps.

  • Go to 0° to 180°
  • Wait 2 seconds
  • Go to 180° to 0°
  • At 0° the servo motor stops, completely, I don't want it to hold it's 0° angular position
  • Wait x seconds (One hour actually)
  • Then step one again

I find a way to make one semi-rotation to 0° to 180° and then go back to 180° to 0° with my servo-motor. But I have trouble for the step 4, How to stop it?.... I have putted a delay at the end of the loop, but the servo stays active in its last angular position. However, I want him to make a pause, to stop completely running...

Here is my code:

#include <Servo.h>

Servo monServomoteur;

void setup() {
    
  monServomoteur.attach(9);

}

void loop() {

  for (int position = 0; position <= 170; position++) {
    monServomoteur.write(position);
    delay(15);
  }

   delay(1000);


  for (int position = 170; position >= 10; position--) {
    monServomoteur.write(position);
    delay(15);
  }

delay(10000);

}

Can you guys help with this please?

I cant make sense of what it is you even want to do..

  • Go to 0° to 180°
  • Wait 2 seconds
  • Go to 180° to 0°

and then what?

its not clear from your bullet points..
you claim: "I don't want it to hold it's 0° angular position"
but then go on to say: "Wait x seconds (One hour actually)"

Which is it?
You either want to wait for 1 hour once the servo reaches the 0 position... or not..

If not.. then I think you are missing a step/bullet point before you 1 hour wait.. what is it?

also what do you mean by active?
As in this comment: "but the servo stays active in its last angular position"

However, I want him to make a pause, to stop completely running...

If you want the servo to stop holding a position, you need to detach() the servo. Don't forget to attach() it again when you want to control it.

Onizuka:
However, I want him to make a pause, to stop completely running...

Please do give more clarification here.
Typically, when you tell a servo to move to a particular position, it moves there and then holds the position.
It is not clear what you want.
Do you want it to move to zero and then stay there?
Do you want it to move to zero and then allow it to move whichever way forces might move it?

Why not use a solenoid? Simple, on/off device - control it with a digital output.

It just occurred to me that if all this thing has to do is hit a button every thirty minutes, a 555 timer may be all you need.

First of all, thank you so mush for your feedback.

vinceherman:
Do you want it to move to zero and then stay there?

Yes that is what I want. I want it to go back to 0° and stop for one hour and do the whole process again (Go to 0° to 180° ; Wait 2 seconds ; Go to 180° to 0° ; At 0° the servo motor stops, completely ; Wait One hour ; Then step one again).

When I said I don't want the Servo to "Hold" the position, I thought that Servos consume energy to hold an angular position. For instance, I tought that when I command my servo to go back to 0° It will continue to consume power to lock in and hold the commanded position (0°). I can't consume power for one hour, that's stupid. That is why I asked. But it seems that the servos doesn't work that way. It is more like the stepper motor that works like that.

Thank you for the 555 time tip. But can I just use the Delay() function? I mean... it is ok right? Is there any issue using this function for 1 hour?

Thank you guys. Aggertroll, xl97, PaulS, vinceherman, dougp you're awesome.