Setepper Motor with tilt sensor

Hello everyone!
I am developing a university project where I want to implement in a canoe a system that gives balance to whoever is using the canoe (counterweight). The idea is to implement two tilt sensors, each one will indicate which way the canoe is tilting (vertical axis). After knowing if the canoe is tilting left or right, the stepper motor will be activated. This stepper motor is also attached to a weight that serves to counterbalance the canoe. The tilt sensor detects which way the canoe is leaning and the motor moves the counterweight to rock the canoe.

I leave below an attached video I found on the internet with an example of what I wanted. I wish you could help me with the code.

Thanks!
I hope you can help me!

Exemple

Please read the forum posting guidelines before asking questions.


Always show us a good schematic of your proposed circuit.
Show us a good image of your ‘actual’ wiring.
Give links to components.


In the Arduino IDE, use Ctrl T or CMD T to format your code then copy the complete sketch.

Use the </> icon from the ‘posting menu’ to attach the copied sketch.

Highly unlikely a stepper will do what you want, but to determine that, we need to know a few more things

The ‘weight’ of the mass being moved.
The distance the mass is being moved.
The time required to transit from end to end limits.
How many cycles during the expected recharge interval ?

With these, you’ll be a lot closer to identifying the motor and mechanism, and from that you’ll know what sort of power supply is needed.

Get ready for the bill !

Could use an inexpensive AC/DC power supply with extension cord.

image

This project is just a small scale prototype to serve as an example, meaning it doesn't have to be perfect.
I would just like to have your help if possible

I have to work with the Super Started Kit UNO R3 Project and the 37 Sensor Kit V2.0

That little stepper is far too slow and weak to move a significant mass, but it could serve as a learning tool about stepper operation.

To balance a canoe dynamically will require moving a large weight very rapidly, with large power draw and is completely out of the question as a beginner project.

But you can learn about how these systems work by looking at published projects. Search for "arduino balance beam" for example.

When you run into something you don’t understand volunteers here will review what you are doing and try to explain where you are going wrong.

Remember what you learned in school about the reaction to every action. In order to move your weight rapidly, you need to apply an opposite force to your canoe. That will tilt the canoe even further while the weight is moving.

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