Log in

View Full Version : 2016 Bosch motor 6004 RA3 194-06


kprzewodek
16-12-2015, 10:25
Just wanted to start a thread for any questions, feedback, suggestions on this year’s first choice offering for the Bosch motor PN 6004 RA3 194-06. I work for Bosch in the motors division so I am familiar with the technical details on this motor. Also, I’m currently an FRC mentor and have been for the past 15 years (wow how time flies).

Hopefully teams find this a useful addition to the motor options. It’s best for a quick addition without much worry about custom gearing and fits a pocket in the options where you might want more torque than the window and snow blower motors offer. Of course at a cost of speed. With a build in thermal switch it is very unlikely to make magic smoke or destroy itself from overheating. It also has an integrated hall sensor which can be quite useful for position feedback and to give the programming teams something to play with. It’s good to see this option becoming more common in many of the KOP motors.

Some of the other Bosch teams had some initial samples to experiment with so may be able to share some early ideas on how best to utilize.

Interfacing with the start output might be the biggest challenge. Wish we had a hex output:o . Thoughts about 3d printing an interface has been brought up but needs to be experimented with since it may not be strong enough. Another option is if you can find or mill a square 6mm x 6mm steel or Aluminum shaft....or even mill down a hex shaft. It's very important that you have a tight fit since any slop with slowly start to strip out the connection and once that goes it's very hard to repair.

KrazyCarl92
16-12-2015, 11:08
Interfacing with the start output might be the biggest challenge.

I think this causes this motor to fall into a bit of a utility gap. Teams that have the ability to use the star output shaft may find their resources better suited to implementing a more powerful non-backdrive solution or integrating a sensor in a different design.

Last year, Team 20 actuated their forks by installing a BAG motor to the Window Motor gearbox with an encoder integrated between the BAG output shaft and the worm. More power, included sensor integration, and honestly not that much more difficult than dealing with that star output shaft.

Lower resource teams may be scared away by the star output, it is not easy to interface with at all.

I think if this had a 1/2" hex output you would have a lot more interest from teams. One application that comes to mind is the window motor shifters employed by Team 67 (I think they ditched that when they started using pneumatics?). The slow speed won't hurt you, and the added integrated position feedback might make it simpler to integrate.

kprzewodek
16-12-2015, 12:24
Lower resource teams may be scared away by the star output, it is not easy to interface with at all.


Agreed. It's why we opted not to include in the rookie KOP as the second low volume option. Maybe good for a medium resource team as I think there is a fairly simple way to mill a square interface into a hex shaft with a little patience. It's not a star but it gets you part of the way to an optimal solution.

RichQuinn
16-12-2015, 12:52
We received our first two samples of this motor last night and they looked very promising for light loads. I had a whole bunch of questions for you but then I realized most are answered here:

http://files.andymark.com/FRC_Bosch_motor_6_004_RA3_194-06_spec_sheetv1.pdf

One question remaining after reading the specs: Is it possible the output power curve is on an incorrectly labelled axis?

Example:
If you look at the peak power point at 11 N.m, the Input power should be 13V x 6A = 78 Watts.
The output power curve shows ~14W, and doublechecking torque & RPM confirms it at 13.8Watts

I don't expect high mechanical efficiency from a worm drive, but ~18% seems way off. Can you check and/or clarify? (Or correct me if I missed a unit conversion or decimal place.)

Regardless, it looks like a nice, light gearmotor option and the hall effect sensor makes it extra useful over a window motor. The challenge as you point out-- will be the relatively fragile output drive material, so that's a problem for us to solve. Square drive looks like an obvious solution, but more contact area would be better. Can you point us to a specific vehicle usage? We might be able to scrounge junkyard parts for the proper mating 8-point shaft. If the junction has survived automotive durability testing, it has a good shot at surviving FRC duty (if properly applied).

Nebster
16-12-2015, 14:36
Are there any COTS 8 point shafts available? If not, what would you suggest we use? We don't have the machining capabilities to make one out of metal. My first thought was 3D printing, but testing would need to be done to see how much stress a 3D printed shaft/hub could take.

kprzewodek
16-12-2015, 16:58
This interfaces with quite a number of GM seats. It's a long list so I'll try to dig that out. It is specifically used for the recliner function in the power seats. I may have a few of these star shafts laying around that I can send if I find enough....maybe cut into pieces. I'll also see if we can find some scrap at our Tier 1.

Regarding efficiency I too was a bit surprised but that's what comes out of our dyno measurments. Actually too much efficiency is a problem in seat and window applications in that you don't want movement as the car bounces about on rough roads. In this motor there's a worm and two stages of spur gears for ~179:1 gear reduction.

topgun
16-12-2015, 17:12
Does anyone have a CAD file for it?

kprzewodek
16-12-2015, 17:22
Does anyone have a CAD file for it?

CAD model for the motor can be found at link through AndyMark. I should point out that there was an error in the first posted model which is currently in the process of being updated. I'll let you know when it is updated.

Bennett548
16-12-2015, 17:34
Have you tried drilling out the star pattern at 3/8" and broaching a key or a 3/8" hex?

This motor seems like a good choice when you would like to use a hobby servo motor, but need much more power (and have a home position sensor). The biggest issue I see with this motor is that it can't support any load on the output. In FRC we love to abuse our motors and gearboxes by hanging way too much weight on them.

Do you know if these will be available from AndyMark after First Choice is over?

bigbeezy
16-12-2015, 21:35
Have you tried drilling out the star pattern at 3/8" and broaching a key or a 3/8" hex?


Would this kind of modification be legal? I know you can modify output shafts on motors but with this being internal does that make it different?

cgmv123
16-12-2015, 22:36
Would this kind of modification be legal? I know you can modify output shafts on motors but with this being internal does that make it different?

Last year's rule says "The mounting brackets and/or output shaft/interface may be modified...". It seems like that modification would be covered by that wording.

MrForbes
16-12-2015, 23:08
how to attach a lever to the motor (just guessing here) get one of these adapters, which you might already have in your toolbox.

http://public.snapon.com/R_RRD/Objects_lg/images/GMB3041.jpg

Insert the square end into the star shaped hole in the motor. Might take some grinding to get it to fit.

then put a 1/4" combination wrench on the hex part of the adapter.

DaveL
17-12-2015, 06:51
Are the internal gears metal?

How much torque can the output shaft experience before breaking an internal component?

Dave

kprzewodek
17-12-2015, 09:08
Are the internal gears metal?

How much torque can the output shaft experience before breaking an internal component?

Dave

Internal gears are all plastic except for the worm. Hard to predict absolute limit since a lot depends on how well it is mounted and how tight the fit to the shaft and if it's a quick or slow force acting on it. These plastic gears will take quite a bit of abuse but something will crack or strip if lets say you have a long lever arm and smash into something.

We have a metal gear option but it was so heavy we decided not to offer it.

kprzewodek
17-12-2015, 09:13
how to attach a lever to the motor (just guessing here) get one of these adapters, which you might already have in your toolbox.

http://public.snapon.com/R_RRD/Objects_lg/images/GMB3041.jpg

Insert the square end into the star shaped hole in the motor. Might take some grinding to get it to fit.

then put a 1/4" combination wrench on the hex part of the adapter.

I did find a few options in a mechanics toolbox where the square part fit exactly. It was a non standard fitting though. Might take a little digging but it's out there. That is a good option for a quick and simple solution.

kprzewodek
17-12-2015, 09:21
Have you tried drilling out the star pattern at 3/8" and broaching a key or a 3/8" hex?

This motor seems like a good choice when you would like to use a hobby servo motor, but need much more power (and have a home position sensor). The biggest issue I see with this motor is that it can't support any load on the output. In FRC we love to abuse our motors and gearboxes by hanging way too much weight on them.

Do you know if these will be available from AndyMark after First Choice is over?

I do have a 3/8" rotary broach and may give that a try. I think it might take too much of the wall out though.

You definitely need to mount this to a completely supported shaft since that acts as the output and second support. If you use the motor to support the shaft then you will most likely have problems.

We decided to offer in limited amounts to get a feel if teams will use them. If there is enough demand then we may be able to consider another order. This is a high volume production motor so it's fairly easy to order more if needed.

HumblePie
17-12-2015, 11:19
We received our first 2 motors yesterday. It looks like the internal star pattern will also accept a 6mm square key (I measured 6.05mm). Oversized key stock (+0/+0.08 tolerance) will probably fit nicely (in stock at McMaster-Carr). I'm also thinking about modifying a 1/4" bore AndyMark hub to accept the 6mm square. Thoughts?

MrForbes
17-12-2015, 11:29
The reason I suggested putting a wrench on the output of this motor, is because of the speed at which it rotates. There really isn't much use for a shaft, is there?

kprzewodek
17-12-2015, 12:58
As long as what you are driving is fully supported there really isn't much need for a shaft I guess.

kprzewodek
17-12-2015, 13:15
Seems like broaching a 3/8" hex still leaves some meat on the gear. Think I'll try and see how it holds up.

HumblePie
18-12-2015, 10:36
I laid out one concept for packaging this motor that would fully support the load by sandwiching 2 mounting plates around (1 or 2) piece(s) of 1" square tube. The motor has only one (slotted) mounting hole, so I added a bore to locate on one of the motor bosses and provide some "clocking" of the motor. The drive shaft is a piece of 1/2" hex milled down to a 6mm square on one end. Another option would be to use a 3/8" hex all the way, so I'm curious to see Kevin's results on broaching the motor out to a 3/8" hex.

If there's interest, I'd happily share the CAD file. I got one quote online for waterjet cutting the plates, and it looks like about $100 to make 10 pieces.

topgun
18-12-2015, 16:43
I am interested in the CAD file. SolidWorks format hopefully.

kprzewodek
18-12-2015, 17:06
That's a nice robust design. I'll experiment over the weekend with broaching a hex and see how it goes.

For a less robust way of doing it I've had success 3D printing a hub inside two plates that you can mount an arm. Simplifies a bit in that you can eliminate bearings.

D.gimon
19-12-2015, 21:48
Hi Kevin,

Seeing as you work for Bosch, is there a source for connectors for last year's Bosch donated spindle motor (PN 6 004 RA3 353-01) which also has Hall signal pins? Looking at the provided PDFs, the motor connectors look very similar.
Can you confirm that the harness will work on both motors?

Thanks,
Dan

kprzewodek
20-12-2015, 01:15
It's the same connector. I can send you some if you PM me your address.

HumblePie
23-12-2015, 13:43
I am interested in the CAD file. SolidWorks format hopefully.

Well, let's give it a shot.....

I modified the original plate to better serve as a corner gusset if you should choose to use it that way.

I then saved the Solidworks file as a Parasolid and zipped it. The link (to get around the 5MB limit) is here:

https://app.box.com/s/lcv76duqngz2pukh9qdnlgqz7i5hlqq1

Let me know what you think, and Merry Xmas to all......

kprzewodek
06-01-2016, 08:52
I was able to broach a 3/8" hex and it appears to work quite well. I haven't put the motor through FRC type durability testing yet but so far that seems to be a good option.

Actually the rotary broach that I have goes about 3/4 of the way through the gear however I was able to carefully tap a hex shaft the remaining distance by making sure the gear was supported.

For those on the fence about investing in a linear or rotary broach I would highly recommend as we have used several times over the years. The nice thing about a rotary broach is that the main investment is the tool holder (~$300) and then you can add a wide range of cutting inserts for around $40 a piece.

Dad1279
19-01-2016, 15:10
The square 'neck' of a 1/4" carriage bolt fits.

Ryan_Todd
19-01-2016, 15:33
Hey all, following up on Kevin's behalf here.

(Full disclosure: like Kevin, I am also both a Bosch associate and a longtime member of Bosch-sponsored FRC Team 862.)


Intro

On January 14th, Kevin asked me to spend some time torture testing one of these motors. I was able to jury-rig a fairly decent test setup, and gathered a pretty good chunk of data; at the end of the evening, I explored to see what it would take to break one of these motors altogether. Here's a summary of the test rig:

http://lightningrobotics.com/gallery/thumb/6192.jpg (http://lightningrobotics.com/gallery/image/6192.jpg)
(click to zoom)
Motor output gear broached to 3/8" hex, as described by Kevin
Standard 3/8" hex shaft used as output
Shaft supported by 3/8" hex bearings on either side of the motor
Bearings, in turn, supported by a pair of old 4" VexPro wheels clamped in a vise
Motor allowed to float freely in the space between the wheels
Appropriate spacing ensured with polypropylene spacers
PWM control through custom "electrical test bech" rig
Power supplied by fully-charged 2015 battery (swapped halfway through the evening)
2 ft wire from battery to PD board
4 ft 8 inches of wire from Victor to motor
Assorted methods used for getting torque off the shaft, described below
Stall Torque Test

http://lightningrobotics.com/gallery/thumb/6193.jpg (http://lightningrobotics.com/gallery/image/6193.jpg)
(click to zoom)
Sought to determine what kind of torque a typical FRC team could reasonably expect to get out of this motor in real-world conditions (bearing friction, side loads, etc.)
Plotted real-world output torque at stall against PWM control percentage
Motor was driven "clockwise" (as defined on the motor data sheet); resistive force was applied in a "counterclockwise" direction until a stall condition was achieved
Used small wrench on output shaft to transfer torque
Used spring force gauge to measure output force
Multiple data points taken & averaged for each stated value
Reported torque = (measured force) x (3.75" lever arm)
3.2 ft-lbs to back-drive without any power applied (not brake mode)
2.0 ft-lbs to stall at 20% pwr
6.6 ft-lbs to stall at 40% pwr
10.2 ft-lbs to stall at 60% pwr
13.3 ft-lbs to stall at 80% pwr
13.6 ft-lbs to stall at 100% pwr
Motor Overheating Test (part 1)

http://lightningrobotics.com/gallery/thumb/6196.jpg (http://lightningrobotics.com/gallery/image/6196.jpg)
(click to zoom)
Used the FRC-standard "anecdotal touch test" to estimate how much abuse it would take to begin to damage one of these motors via overheating
This is a fully sealed motor like the CIM and mini-CIM, so it is necessarily designed to be far more tolerant of stalling out than (for example) a Fisher-Price motor
This category of motor will still suffer degraded performance if you let them get too hot
Rule of thumb:
If a motor is too hot to hold, then its performance is temporarily degraded; it needs to cool down before it will regain full performance
If even a quick tap of the finger on the surface of the motor is painful, then its performance is permanently degraded
Motor was driven "clockwise" (as defined on the motor data sheet); resistive force was applied in a "counterclockwise" direction
Test setup featured adjustable resistance
Hex shaft runs through hole drilled in wood block
C-clamp to squeeze wood against shaft
Torque measured using spring gauge at fixed distance along length of board
Wood wore away over time, so the compression needed frequent adjustment
Full pwr, no load
5 mins: "Pleasantly warm to the touch"
10 mins: "Very warm"
Allowed to cool (10 mins)
Full pwr, 4 ft-lb average load
5 mins: "Very warm"
10 mins: "Hot, but not yet painful to touch"
Allowed to cool (10 mins)
Full pwr, 8 ft-lb average load
5 mins: "Hot, but not yet painful"
10 mins: Test aborted, resistance board fully eaten through
Allowed to cool (15 mins)
Motor Overheating Test (part 2)

http://lightningrobotics.com/gallery/thumb/6197.jpg (http://lightningrobotics.com/gallery/image/6197.jpg)
(click to zoom)
With the adjustable-friction rig destroyed, any further tests could only be achieved with a longer lever arm
No suitable supplies were readily available, so it was decided to skip straight ahead to the stall condition
A large wrench was fitted to the shaft, long enough for the edges of the vise to act as end stops for the motor's rotation
Motor was alternately driven "clockwise" and "counterclockwise" (as defined on the motor data sheet) at 100% power
Approximately 90 degrees of output shaft rotation before the end stops were reached
Whenever an end stop was reached, the motor was allowed to stall at full power for three seconds
After stalling for three seconds, the direction was immediately reversed
This process was repeated for 2 minutes and 30 seconds
The "anecdotal touch test" was performed repeatedly upon the conclusion of this test sequence
A motor in stall tends to build up heat in its core faster than it can be transferred to the outside shell
First test, immediately upon the conclusion of the 2:30 test sequence: "Hot, but not yet painful"
Peak temperature of external shell of motor: "Just barely too hot to hold"
Once the motor was allowed to cool back down, no difference was noted in the motor's performance vs. before the overheating test was performed
Death Test

(No picture for this one yet; sorry!)
With all of that done, it was time for something a bit more... Aggressive.
The large wrench from the previous configuration was left in place
The spring force gauge was brought back and used to back-drive the unpowered motor
The motor was successfully back-driven in both directions with up to 21 ft-lbs of torque
No signs of damage thus far
This clearly wasn't doing the trick, so low power was applied to the motor causing it to rotate "counterclockwise" (as defined on the motor data sheet)
Using the large wrench and force gauge again, an attempt was made to back-drive the motor again
No back-driving was possible against the powered motor
A peak of 27 ft-lbs was reached before something started snapping
With each snap, the output shaft rotated a short distance opposite to the motor's rotation
No loose teeth could be heard jostling around within the gearbox, however, and the motor ran perfectly normal (even at stall!) thereafter
Thus, it is reasonable to conclude that the observed failure mode was the result of the deformation of teeth within the motor's attached gearbox
Presumably, continued operation in the 20+ ft-lb range would eventually cause performance to degrade below the range of normal operation
Upon investigation, the hex shaft had rotated approximately 20 degrees relative to the hex broached output gear before the failure occurred
It is therefore possible that the resulting deformation of the output gear may have played a role in the observed failure
The use of the stock 8-pointed spline shaft may therefore stave off failure to an even higher torque level, but that is just speculation
I hope to crack open the motor in question and confirm these hypotheses, but right now we're in the middle of building a robot!
Conclusion

This motor could handle a stall condition with the best of 'em, and withstood 2x its own stall torque before giving way. Even when it did "break", it still continued operating normally for applied torques up to and including its stall torque.

All in all, I have no reservations at all about recommending this motor for use in any application that warrants a motor with torque/speed ratings in this range:
Deploying a collector
Rotating a turret
Winding up a catapult
Manipulating the Portcullis, Drawbridge, Cheval de Frise, and/or Sally Port
Et cetera

MrForbes
19-01-2016, 15:43
thanks!

kprzewodek
19-01-2016, 16:16
Thanks Ryan!

I should point out that there is a thermal switch built into this motor. If you are running close to or at stall for long periods of time you will most likely trip the thermal switch. It will reset over a period of time but you would notice intermittent operation. Not to worry its doing it job to prevent catastrophic meltdown.

Ryan_Todd
20-01-2016, 08:30
...there is a thermal switch built into this motor...

Well then, now I'm surprised that I never managed to trip it!

Perhaps a Round Two of testing is warranted, just keeping the motor in stall until the thermal switch trips and confirming that the motor retains its original performance characteristics after it has been allowed to cool back down.

Either way, that makes these motors seem practically rookie-proof... ::safety::

kprzewodek
20-01-2016, 09:58
Well then, now I'm surprised that I never managed to trip it!

Hold it at stall for around 5s and it should trip. Less/more depending on existing temperature. This switch is based on internal temperature alone.

Either way, that pretty much settles the question that these motors are rookie-proof... ::safety::

Careful. Don't think it's "anyone" proof. Mount correctly to keep side loading minimized and you should be ok.

Dad1279
20-01-2016, 10:50
Does anyone know where to buy more?

kprzewodek
20-01-2016, 12:02
Does anyone know where to buy more?

Since we supply this motor "as required" by a particular Tier 1 we don't stock inventory and have it setup as a stock item in our system. We're trying to get a feel it teams find this useful this year. If it is we can look into something in future years. I'll do my best to donate replacement parts as needed but we cannot charge anything for it since we donate this to FIRST.

adciv
20-01-2016, 12:50
Two questions for you.
A) What does "Tier 1" mean? As opposed to "Tier 2"? (Not looking for names, just meanings)

B) Do you have a state space model of the motor you could share? I'd like to be able to simulate motors mathematically for some control system development & feedback tuning but getting the parameters can be difficult.

MrForbes
20-01-2016, 13:01
Is this a car part? If so, what car does it fit? :)

kprzewodek
20-01-2016, 13:45
Is this a car part? If so, what car does it fit? :)

It's used in a seat shared across many GM vehicles for the recliner function. The list is quite extensive. The GM alpha is one:

https://en.wikipedia.org/wiki/GM_Alpha_platform

kprzewodek
20-01-2016, 13:50
Two questions for you.
A) What does "Tier 1" mean? As opposed to "Tier 2"? (Not looking for names, just meanings)

Sorry I forget this is a common term for the auto industry but not so much for the everyone else. Tier 1 is first customer to the auto makers (we call OEM's). Tier 2 supplies to Tier 1, etc..

B) Do you have a state space model of the motor you could share? I'd like to be able to simulate motors mathematically for some control system development & feedback tuning but getting the parameters can be difficult.

Not sure what you mean by "state space model". If you mean performance data you can find on Andy mark.

http://firstchoicebyandymark.com/fc16-059

MrForbes
20-01-2016, 14:21
I wonder how one translates GM part numbers to Bosch part numbers? besides ordering one and looking at it?

http://parts.ganleygm.com/p/Cadillac__CTS/Recline-motor-Seat-Motor/48158774/15894214.html

kprzewodek
20-01-2016, 16:12
I wonder how one translates GM part numbers to Bosch part numbers? besides ordering one and looking at it?

http://parts.ganleygm.com/p/Cadillac__CTS/Recline-motor-Seat-Motor/48158774/15894214.html

I am not aware of a GM number with this motor, however, if we provide as a replacement part there must be. I'll have to check with our after-market group since I don't deal on that side of things. That is an option although quite expensive to go that way.

MrForbes
20-01-2016, 23:17
It would be nice to get a part number for one of them, but it's also possible that it's similar to many other seat recliner motors (I never knew there was such a thing! but I drive 50+ year old cars all the time) that might be useful.

$50 is a reasonable price for a nice slow powerful gear motor

kprzewodek
21-01-2016, 14:04
It would be nice to get a part number for one of them, but it's also possible that it's similar to many other seat recliner motors (I never knew there was such a thing! but I drive 50+ year old cars all the time) that might be useful.

They're pretty standard throughout the industry. Different picture going back 50yrs. The output profile varies quite a bit. This one provides one of the more FRC friendly interfaces. Maybe one of these days the auto industry will catch onto the hex craze.

FYI, the end motion of the seat recline is a result of the pretty low gearing in the motor and additional gearing in the seat mechanism.

I'll do my best to dig up the part number.

kprzewodek
25-01-2016, 10:39
I wonder how one translates GM part numbers to Bosch part numbers? besides ordering one and looking at it?

http://parts.ganleygm.com/p/Cadillac__CTS/Recline-motor-Seat-Motor/48158774/15894214.html

Turns out this one particular model is an exception and is not our motor. May have been an old design that carried over because this is no longer considered a replacement part. Since these are so deeply tucked inside the seat the cost of labour to replace the motor probably exceeds the benefits you would get.

We're looking into options for providing as a "purchase as needed" item but can't make any promises until we work through the details involved.

I'll do my best to offer replacement parts to teams that have received through first choice.

cedwards
16-02-2016, 17:17
Hello, our team has decided that they would like to use this on an elevator component. We have a few questions on how we can implement this motor to its fullest.

1) Wiring. We have the motor +/- and have been driving them. However, we are not sure how to wire the two addition wires (additional to the motor power) to gain access to the internal encoder (Hall effect sensor?).

2) If this is a hall effect sensor what part of the RoboRio do we plug it into? Is it digital or analog?

3) If the "encoder" that is in this motor is a hall effect sensor what component do our programmers use to get information from it to base position on. Is this a Counter object?

Thanks all, and happy last week of build!

kprzewodek
16-02-2016, 17:25
1) Wiring. We have the motor +/- and have been driving them. However, we are not sure how to wire the two addition wires (additional to the motor power) to gain access to the internal encoder (Hall effect sensor?).

There is a spec sheet that will help you with this. http://files.andymark.com/FRC_Bosch_motor_6_004_RA3_194-06_spec_sheetv2.pdf. Let me know if you need further clarification. The hall does need to be powered because it is isolated from the motor power circuit.


2) If this is a hall effect sensor what part of the RoboRio do we plug it into? Is it digital or analog?

It is an analog signal.


3) If the "encoder" that is in this motor is a hall effect sensor what component do our programmers use to get information from it to base position on. Is this a Counter object?

It basically provides one pulse per armature rotation. There are 179 armature rotations for each output gear rotation.

-Kevin

cedwards
16-02-2016, 17:45
Thanks Kevin
The hall does need to be powered because it is isolated from the motor power circuit.


So we can hook up a pwm cable that runs from the analog breakout from the roborio. Black wire (ground) to Pin #4, Red wire (positive 5v?) to Pin #2 with a R-200Ohm resistor. Finally the White wire is just cut off and goes to nothing?.

Does that sound correct?

The rest of this makes a bit more sense now that I know we are indeed dealing with a hall effect sensor.

Thanks much.

eccmaster
16-02-2016, 18:43
I would like to buy this motor any good sources to buy this exact model?

Thank you in advance

kprzewodek
16-02-2016, 23:45
Thanks Kevin


So we can hook up a pwm cable that runs from the analog breakout from the roborio. Black wire (ground) to Pin #4, Red wire (positive 5v?) to Pin #2 with a R-200Ohm resistor. Finally the White wire is just cut off and goes to nothing?.

Does that sound correct?

Thanks much.

Seems right although some have had issues getting the roborio to pick up the signal at 5V. The difference between peaks and valleys is less than when your putting 12 V through which this hall it is really designed for. If you have success getting 5V to work please let me know.

kprzewodek
17-02-2016, 10:11
I would like to buy this motor any good sources to buy this exact model?

Thank you in advance

Please read previous post in this thread addressing this question.

kprzewodek
17-02-2016, 15:09
As mentioned you must supply a power source for the hall circuit since it doesn't feed of the motor power inputs.

Just as a reference I made a comparison of reading the hall signal with 12V and 6V input (power supply wouldn't go any lower). At 12V the difference from peak to valley is ~3.9V. It's ~1.6V with 6V input. May explain why the Robo Rio is having trouble reading at the lower voltage.

cedwards
18-02-2016, 15:12
Today after hooking up the oscilloscope we were able to verify a few things and start getting values to count.

Wiring
We took a standard PWM cable and connected as follows:
Red wire to the 200 Ohm resistor and then to Pin #2 of the motor.
The White wire connects to the motor side of the resistor/Pin #2.
Then Black wire to Pin #4.

Plugged this into an Analog Channel on the RoboRio (5V power supply).

Code
We used a AnalogTrigger (Java) to tie into the analog signal and set its limits based off the values we were getting from the oscilloscope.

AnalogTrigger trigger = new AnalogTrigger(0);
trigger.setLimitsVoltage(3.5, 5.0);
boolean inWindow = trigger.getInWindow();

The next steps will be to keep track of this count and setup equations to be able to set the angle of the mechanism. Hope this is useful if other teams are looking to use these motors and its hall effect sensor.

SLAB-Mr.Thomas
21-02-2016, 19:38
Saw a typo above; it's 174.9:1 gearing, of course.

Here's a sample C++ code using the counter so no ticks of the encoder are missed.



// Position of BOSCH AHC-2 12V 6004.RA3.194-06 174.9:1 gear w/ encoder 1 tick per motor revolution on roboRIO analog 5 volt bus
// FRC Team 4237 Lakeshore High School
// Sample program merely rotates 1 revolution then reverses for 1 revolution and does so forever.

#include "WPILib.h"

class Robot: public SampleRobot
{
public:
Robot();
void OperatorControl();
float CheckDirectionChange(float);
int GetPosition();
private:
CANTalon* mCANTalon; // motor
AnalogTrigger mAnalogTrigger; // create an encoder pulse trigger
Counter* mCounter; // count the encoder pulse triggers in current direction
float mSpeedPrevious; // to remember previous direction
int mPosition; // position accumulator to remember previous position before last direction change
};

Robot::Robot() : mAnalogTrigger(0)
{
mCANTalon = new CANTalon(0);
mAnalogTrigger.SetLimitsVoltage(3.5, 3.8); // values higher than the highest minimum (pulse floor), lower than the lowest maximum (pulse ceiling)
mCounter = new Counter(&mAnalogTrigger);
mSpeedPrevious = 0.;
mPosition = 0;
}

float Robot::CheckDirectionChange(float NewSpeed)
{
// update position accumulator if changing direction
// encoder doesn't know the direction so we have to remember the direction for it
if ((mSpeedPrevious < 0 && NewSpeed >= 0) || (mSpeedPrevious >= 0 && NewSpeed < 0))
{
mPosition = GetPosition(); // changing directions so save what we have
mCounter->Reset(); // and start counting in the new direction
mSpeedPrevious = NewSpeed; // return input speed for ease of use (may include it in the Set() argument => Set(CheckDirectionChange(speed)))
}
return NewSpeed;
}

int Robot::GetPosition()
{
// position from previous direction change plus what's been accumulated so far in this direction
if (mSpeedPrevious >= 0)
return mPosition + mCounter->Get(); // been going forward so add counter

return mPosition - mCounter->Get(); // been going backward so subtract counter
}

void Robot::OperatorControl()
{
bool blockForward, blockReverse; // soft limit switches for this example
int mPos=0;
float speed = 1.0; // initial speed for this example
mCounter->Reset();

// example back and forth nearly 1 revolution (174.9)

while(IsEnabled() && IsOperatorControl())
{
mPos = GetPosition();
printf("Position %d, Speed %f\n", mPos, speed);

if (mPos >= 175) blockForward = true; // example check for at limit switch
else blockForward = false;

if (mPos <= 0) blockReverse = true; // example check for at limit switch
else blockReverse = false;

if (blockForward) speed = -1.; // example if at a limit switch go back the other way
if (blockReverse) speed = +1.;

// call CheckDirectionChange with same speed as Set() with (or before or after) every motor Set() to update position if reversing direction
mCANTalon->Set(CheckDirectionChange(speed)); // refresh or change speed, update position if changing direction

Wait(0.01); // ticks won't be lost but wait less to see them all here and respond faster
}
}

START_ROBOT_CLASS(Robot)

kprzewodek
22-02-2016, 09:09
Thanks cedwards and SLAB-Mr.Thomas for sharing your results. Looks like your having success getting this to work with 5V. I'll try to get the spec sheet updated once we have a confirmation this is working ok with the CRio and we aren't missing too many counts.

ICE_Bear
22-02-2016, 19:28
We are a team using this motor. we would like to get more of them. is there a team or a place we can go to get it?

kprzewodek
03-03-2016, 10:19
If anyone needs spare motors we have another order in process. These will be distributed through AndyMark as a donated item.