Software Support > Automated Projects

Auto rotate from Raspberry Pi/RetroPie ...

<< < (4/8) > >>

DaOld Man:
Ok, first step, hooking up the hardware.
Mrotate uses pins 40 and 38 as the default outputs to the drive.
It uses pins 35 and 37 as the default limit switch inputs.
You can change these in the mrotate_settings.txt file if you want to use different pins. (More info on that later.)
On my test rig, I used a small drive.
For the limit switches I use switches that are normally on until the end of travel is reached, then they open.
Right now Mrotate is set up to only monitor the switches in that fashion. I may give the user the option to change this, if the demand is there.
I also highly encourage you to add 500 ohm resistors (1/8- 1/4 watt), between the inputs and the ground.
This is to protect the RPi, because the pins can be set as inputs or outputs by software, it might harm the Pi if something sets one of your limit switch connected pins as an output and turns it on while connected to ground. The resistors will put a current limit on the circuit if that ever happens. Connecting an output directly to ground is not a good thing.
Here is a fast and dirty hookup diagram. On Mrotate, I have decided to use pin numbers and not GPIO numbers, since they dont match and it's just easier for me to count out the pins to be sure Im connecting to the right ones. I can make this selectable (Pin # or GPIO #) if the demand is there.


Bolthouse:
Hey! Looks like you've been doing some work since I've been gone!

I actually live in Hong Kong and just got back from a 10 week sales trip to the US, so this whole project has been on a shelf during that time. I also have a 2-year old and another on the way in January, so projects like this tend to get shelved for long periods of time anyway.

However, I did take advantage of my time in the US to buy up a variety of parts and tools for my cabinet. Not that you can't get arcade parts and supplies here in HK, but arcade cabinets here are more the Japanese style, which is a far cry from what grew up with in the US. This is to say, I think I've finally acquired all the components to complete the cabinet.

Further to your question of "am I still interested in this project", most definitely! I'm just not to the point of making the monitor rotate yet.

It'll be a slow process of working toward that point, but rest assured, when I get there, you'll be hearing from me.

Thanks for the work you've done on this issue thus far. It definitely won't go to waste!

Bolthouse:
I noticed in your schematic that you have a motor controller between the RPi and the motor itself. I forgot until just now that I will need a motor controller.

While I understand how to physically wire things up, it would be great if someone could recommend a good motor/motor controller that would work well for turning a monitor with the RPi.

My best source for finding specific electronic components in Hong Kong is ... http://hken.rs-online.com/web/

I know it's a bit lazy of me to ask, but if someone more knowledgeable could go onto that site and link me to the proper parts, it would be greatly appreciated.

Alternatively, if there is someone online selling motor/controller kits for rotating arcade cabinet monitors, I would be very interested in that.

Thanks a bunch!

Bolthouse:
Sorry for the flurry of questions. Like I mentioned, I'm just getting back into this project and trying to remember where I left off.

With regard to the motor controllers, I found a previous post of mine where someone recommend the "Pololu Simple Motor Controllers" ... https://www.pololu.com/category/94/pololu-simple-motor-controllers

Anyone have experience with these? They seem to be in line with the hardware I'm already using, but IO'm not really sure how to pair them with an appropriate motor.

With regard to motors, is there a particular voltage, RPM or torque requirement?

I realize that windshield wiper motors are often recommended on this forum, but I'd rather go with just a general purpose DC motor ... rather than re-purposing a motor that was designed for a specific task.

DaOld Man:
Hi Bolthouse!
Welcome back and congrats on the new edition to the family!!

I thought everyone had lost interest in the Pi-rotate project, so I kinda shelved it.
I do need to work on mrotate for Pi again, a few loose ends I need to fasten down, so I will try to get the project back out and dust it off.
May be a few days though cause life is getting in my way.

About the motor controller: Yes you will need a device that can handle the large power (compared to a Pi output) that it will take to run the motor. This device is normally called a drive.
There are several drives available on the market, and if you have time, patience, and the tools you can build it yourself.
However there are so many cheap options out there it may be best just to find what you need and buy it ready made, unless like me, your first hobby was electronics and you enjoy "Building your own".
What type drive do you need? This depends entirely on what type motor you choose.
So you need to choose your motor first.

What type motor? That can be a tough question, or it can be very simple.
You need to figure out how much power you need to turn the monitor.
How heavy is your monitor? What type of bearings or pivot do you plan to use to allow it to turn? How fast do you want it to turn? (Too fast can be dangerous and too slow is frustrating.)
You need decide what type power supply you need for the motor. The power supply must closely match the requirements of the motor, and it must supply the current needed for the motor.
Seems the most common motors used for this purpose, IMHO, are DC brush types, 12 volts DC.
How big the motor is goes back to the second line of this paragraph. Bigger the motor, more work it can do.
But bigger the motor, more power required to run it, more space consumed in your cabinet, and probably more noise when running.
The speed of the motor is important too. Although you can slow a DC brush motor down by decreasing the voltage going to it, you want to make sure it can go as slow as you want it.
If the motor is still too fast (you only need the monitor to turn 90 degrees), you will have to reduce the speed by using gears or pulleys and belts.
It can get complicated mechanical wise. But you can buy DC motors with gearboxes attached that does most of that work for you.

The windshield wiper motor is common because it needs 12 VDC, which can be supplied by an old computer power supply. It has a built on gearbox, which means the output is pretty slow, and it is a strong motor.
I used one on my first rotate project that turns a 19" CRT monitor.
But it is loud when it runs.
Other motors that people have used on here are the tiny motors (forget the name), steppers, and servos.
Steppers and servos require special drives and most likely digital interface with the computer, which Mrotate for Pi will not do.
I used a actuator (screw) motor on my experimental Pi thing for this project.

So I guess you first need to concentrate on how you are actually going to mechanically turn the monitor.
Build the frame for that, see how much force you think will take to move it, then decide on the motor and how you will couple the motor to the monitor, then pick out the motor, the power supply, and the drive. In that order. (I would keep the power supply for the motor separate from the power supply for the Pi.)

I know this seems a lot to chew, but it's not really that bad, I do tend to ramble a lot in my old age LOL.
Just first concentrate on how you are going to perform the act of physically turning the monitor.

We are here to help, several people have done this and I havent heard anyone say they regret it.





Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version