March 28, 2024, 10:01:44 AM

News:

You can now use Vixen to program your Prop-1 and Prop-2 controllers!  Get started quickly and easily, without having to learn PBASIC.  Details in the Library forum.


Wiper Motor & HB25

Started by jssherrard, August 09, 2008, 01:38:01 PM

Previous topic - Next topic

jssherrard

Hi!

I have been using a Prop-1 to power a Monster Guts Wiper Motor through an HB25 following the instructions on Scary Terry's website. Here is an image from Scary Terry showing his setup:



This worked fine for a while, but has since stopped. After reading some additional threads on this forum I believe that this is not the correct way to connect these devices. What is the proper way to connect a Prop-1, HB25 and a Wiper Motor?

I am not particularly experienced with electronics, so please be patient with me!

???

menehune

August 09, 2008, 10:26:36 PM #1 Last Edit: August 09, 2008, 10:28:11 PM by menehune
I would check the power supply powering everything.  The "wall wart" may not have enough current to drive the motor.
There may not enough current available to prevent a brownout of the HB25 when the motor starts under load.

Are any lights illuminating on the Prop?  You should have two lit-one under the power switch and the led in the top right corner next to the V+ terminal.
I believe there is both a power led and a data led on the HB25.  Are any of those lighting when the prop and motor is running?

The ULN may also be interfering with serial communications to the HB25.  Try unplugging the ULN from the socket and see if the motor works correctly.  It is recommended that any serial devices be plugged into the P7 jack on the prop.

JonnyMac

I would normally be inclined to use separate power supplies for the motor and the controller; as indicated above, the motor can draw a lot of current, and can also induce some noise that may be feeding back into the controller causing it to be upset (note: we have quite a lot of power supply filtering on the Prop-1, but there's only so much we can do).

The HB-25 uses a high-going servo-style pulse for control, so unless the ULN input circuit has shorted I wouldn't think that is a problem.
Jon McPhalen
EFX-TEK Hollywood Office

jssherrard

I feel as though I am constantly apologizing for my ignorance, but reading this forum is , for me, like trying to solve a riddle in an alien language... LOL!

;)

So, if I understand correctly, the Scary Terry method is NOT a proper way to connect these devices. Right? Instead I should run a separate power supply to the Wiper Motor via the HB25.

I have read that the HB25 should only be powered on AFTER the Prop-1. Is this correct? If so, what are my options for accomplishing this? Do I need to manually turn them on separately or is there some way to use the Prop-1 to turn on the HB25?

Regarding the ULN, I suspect that I have shorted it and will need to replace it. Everything was working fine for a while using the Scary Terry method, and then... ptptptpt! I have some ULN related questions, but I will ask those in another thread under that topic...

JonnyMac

I wasn't saying that, no; I was saying that given the amount of noise a motor can generate I wouldn't use the same power supply.  Keep in mind that my job for the last 25 years has involved designing products for "Joe consumer" -- this tends to make me a VERY CONSERVATIVE engineer.

I don't know that there any problem vis-a-vis the power-up sequence.  What you need to do, however, is let the HB-25 do its internal initialization before you try to send it commands (see code below for proper sequence).  It's not likely that you popped the ULN, but it doesn't hurt to check.

[Edit] After looking at the demo framework that I'm going to post below I think you should not allow the ULN to interact with the signal for the HB-25 (my apologies to Menehune).  The HB-25 wants to pull that line high to indicate that it's ready, and I don't know that it is able to overcome the pull-down nature of the ULN input circuitry.

' =========================================================================
'
'   File...... HB-25.BS1
'   Purpose...
'   Author....
'   E-mail....
'   Started...
'   Updated...
'
'   {$STAMP BS1}
'   {$PBASIC 1.0}
'
' =========================================================================


' -----[ Program Description ]---------------------------------------------


' -----[ Revision History ]------------------------------------------------


' -----[ I/O Definitions ]-------------------------------------------------

SYMBOL  HB25Chk         = PIN7                  ' P7 in - no SETUP jumper
SYMBOL  HB25            = 7                     ' P7 control


' -----[ Constants ]-------------------------------------------------------


' -----[ Variables ]-------------------------------------------------------

SYMBOL  speed           = B2                    ' 100 to 200


' -----[ Initialization ]--------------------------------------------------

Check_Motor:
  IF HB25Chk = 0 THEN Check_Motor               ' allow HB25 to initialize
  LOW HB25                                      ' set for PULSOUT
  GOSUB Stop_Motor

Setup:



' -----[ Program Code ]----------------------------------------------------

Main:

  END


' -----[ Subroutines ]-----------------------------------------------------

Stop_Motor:
  PAUSE 6                                       ' command hold-off
  PULSOUT HB25, 150                             ' center = stop
  PAUSE 6                                       ' command hold-off
  PULSOUT HB25, 150                             ' insurance command
  RETURN

' -------------------------------------------------------------------------

Set_Motor_Speed:
  PAUSE 6                                       ' command hold-off
  PULSOUT HB25, speed                           ' set speed/direction
  RETURN

' -------------------------------------------------------------------------


' -----[ EEPROM Data ]-----------------------------------------------------

Jon McPhalen
EFX-TEK Hollywood Office

menehune

There should be a green power light on the HB25.  Is the red "fault" light on the HB25 illuminating?

Unfortunately I don't have a HB25 so I can't help in much detail.

jssherrard

August 11, 2008, 03:47:34 PM #6 Last Edit: August 11, 2008, 03:56:21 PM by jssherrard
OK... Here is the situation so far:

Both red lights (power & V+) on the Prop-1 are on and the green power light on the HB25 is on. The HB25 fan is running. I have the HB25 connected to P7 and I am using the ULN2003. I have added the following code to the Program section of JonnyMac's demo:

' -----[ Program Code ]----------------------------------------------------

Main:

speed = 180
GOSUB Set_Motor_Speed
PAUSE 2000

speed = 150
GOSUB Set_Motor_Speed
PAUSE 2000

GOTO Main

'-----

Each time the HB25 receives the "PULSOUT HB25, speed" (speed=180) command the motor moves a tiny click forward and then immediately stops...

?

I cannot seem to figure out what I am doing wrong. I tested the motor independantly and it works fine. The Prop-1 seems to work fine. Where do I go from here?

(edited to add: I don't know if this matters, but each time the motor clicks forward, the V+ light flickers...)


JonnyMac

You might want to consult Parallax tech support on the HB-25; seems like the issue is there.  Make sure that you're following all their programming guidelines (as shown in my template code, above), and do disconnect the ULN from the pin you're using to communicate with the HB-25.
Jon McPhalen
EFX-TEK Hollywood Office

menehune

Since the V+ light (on the prop?) flickers when the motor runs, it sounds like the "wall wart" power supply cannot supply enough power.  The supply may be overloaded.  Do you have a large battery (12V, 7AH or a 12V car battery) you can hook to the HB25  and the motor for testing?  Connect the "-" of the prop and the battery together and see if the motor runs correctly. 

It does sound to me like the power supply cannot supply enough current.  The HB25 may be resetting when the supply voltage drops below it's minimum threshold (motor tunrs on & the V+ flicker) then waiting a few seconds ignoring serial commands from the prop in the meantime.

livinlowe

I would agree; try a seperate power supply for the HB25.
Shawn
Scaring someone with a prop you built -- priceless!

jssherrard

Yup, a new power supply is on its way! I will post the results after it arrives. Thanks for the help so far!!!

:)


jssherrard

The new power supply (12vdc 5amp) arrived yesterday and I am testing it now. Fortunately, it seems to be working much better... Yeay!

I have noticed that on occasion when the HB25 receives a "PULSOUT HB25, 150" command, the motor stops as it should; however, the green light and the fan on the HB25 also stop until the next PULSOUT command is given. Is this normal?


JonnyMac

For details on the HB25 you really need to consult our friends at Parallax.  Note, though, that my Stop_Motor routine in the demo above actually sends two pulses just to make sure that everything is in fact stopped and as it should be.
Jon McPhalen
EFX-TEK Hollywood Office

jssherrard

First I want to say THANK YOU for all the help so far...

:)

I have contacted Parallax and I am waiting for a response; however, I thought I would update here as well in case anyone else on this forum encounters similar issues.

Here is the current situation: I received and connected an appropriate power supply to the HB-25. This solved the initial issue. Good so far. I then realized my HB-25 was in "Timeout Mode" so I fixed that as well. Sadly, I still have a problem...

Whenever I send a "PULSOUT" command to the HB-25, the motor only runs at two speeds: on or off.

Any value greater than 150 = FULL ON, any value of 150 or less = OFF.

???

What am I doing wrong now?!?

Here is a brief code example:


- - - - - -


' {$STAMP BS1}
' {$PBASIC 1.0}

SYMBOL HB25 = 7

Startup:

IF PIN7 = 0 THEN Startup
LET DIRS = %10000000
PAUSE 50
PULSOUT HB25, 150
PAUSE 50

Main:

PULSOUT HB25, 160
PAUSE 2000

PULSOUT HB25, 175
PAUSE 2000

PULSOUT HB25, 190
PAUSE 2000

PULSOUT HB25, 150
PAUSE 4000

GOTO Main


- - - - - -


Oddly, this results in 6 seconds of forward movement at THE SAME SPEED and 4 seconds of no movement... Again, any value less than 150 results in no movement instead of the expected reverse direction.

Honestly, I am at a loss here and don't know how to proceed. Waiting for a reply from Parallax...

(argh!)

JonnyMac

Do you have the J1 jumper installed?  Again, this really need to be taken up by Parallax; and don't expect a swift reply on an e-mail (they're busy), but do call 888-512-1024.
Jon McPhalen
EFX-TEK Hollywood Office