Telescope drive motors that don't...


Closed Thread
Results 1 to 40 of 69

Hybrid View

  1. #1
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    try to increase the delay routine or paste it 2-3 times again to see how better worst it will be.

    Something easy like

    MOVLW HSTEP1
    MOVWF PORTB
    CALL RA_DELAY ; variable loop to time pulses
    CALL RA_DELAY ; variable loop to time pulses
    CALL RA_DELAY ; variable loop to time pulses
    MOVLW HSTEP2
    MOVWF PORTB
    CALL RA_DELAY ; variable loop to time pulses
    CALL RA_DELAY ; variable loop to time pulses
    CALL RA_DELAY ; variable loop to time pulses

    cost nothing to try huh?
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  2. #2
    Join Date
    Mar 2008
    Posts
    17


    Did you find this post helpful? Yes | No

    Default

    Well, I tried!

    In fact I don't have to double up the delay - it's 130x125, so I just alter the values.

    Making the delay shorter (5x5) results in no movement from the motor at all - but I expected that would be too fast...

    Making the delay longer (250x250) results in slower movement, but with the same low torque. It's just as if the L293D is only sending one pulse to the coil, rather than holding the coil on until the next change occurs. Surely if you:

    MOVLW HSTEP1 ;(hstep1 is FF, for example)
    MOVWF PORTB

    this should leave all PORTB pins high until PORTB is changed? Or perhaps the L293D only sends one pulse to the motor, and I need to increase the current or duration on this in some way?

  3. #3


    Did you find this post helpful? Yes | No

    Default

    Silly question. Do you have the VS pin (pin 10) of the L293D parts connected directly to the battery? Or is it connected to the 5V supply? That pin supplies the voltage that actually drives the motors and should not be going through the regulator.
    Tim Barr

  4. #4
    Join Date
    Mar 2008
    Posts
    17


    Did you find this post helpful? Yes | No

    Default

    No, very sensible question!

    The circuit I have assembled is precisely as advertised here: http://telescope.marford.me.uk/Proje...controller.htm .

    You will see that I am using a 16 pin L293D, where VS is pin 8, and this is what is connected directly to the battery positive. So there should be lots of power available to the L293D.

    I think it is unlikely to be a failed L293D either, since the circuit actually contains two PICs driving two seperate L293Ds (with slightly different programming), and both of them display the same problem. This circuit is advertised as a working stepper motor driver, but I am coming to the conclusion that maybe it is not!

  5. #5


    Did you find this post helpful? Yes | No

    Default

    Another silly suggestion. Try turning BOD off. Maybe your regulator isn't rock solid enough and BOD is resetting the PIC. The PIC will run at lower voltages than the BOD is set for. Upper level for BOD is 4.4V. According to the code, portB should be static and not pulsed. If this fixes your problem, maybe you could look for a LVDO regulator only a 400mV drop like a STMicro LD29150.
    Last edited by falingtrea; - 27th March 2008 at 19:51.
    Tim Barr

  6. #6
    Join Date
    Mar 2008
    Posts
    17


    Did you find this post helpful? Yes | No

    Default

    Umm...What's BOD? Are you talking about the regulator? Are you suggesting that I just feed the +5v regulated line from the battery directly, at 6.3V?

    The difference seems to be minimal, and I suspect it will cause no damage, but is that what you mean?

    Incidentally, I have been looking for any possible difference between what I am doing and the published circuit. The only thing I can see is that the regulator is flanked with a couple of 100nf bead capacitors, and I am using 100nf polyester. Interestingly, the data sheet for the 7805 regulator suggests 30mf capacitors, but I am following the published design. Perhaps there is a problem there...?

  7. #7
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    100nF directly at the output + 1 as close as possible of the pic is recommended. 30uF or higher would be nice at it's input. i usually use 10uF tantalum at the output as well as close to the PIC.

    Any current demanding device have their own 47uF (or higher depending) + 0.1 uF as close as possible.

    BOD: Brown-out detect. It's one of those configuration fuses setting for the PIC you're using.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

Similar Threads

  1. MPASM Path & File Name Length Limtation
    By Brian J Walsh in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 14th June 2008, 15:48
  2. Differential Drive Programming
    By shaiqbashir in forum mel PIC BASIC Pro
    Replies: 14
    Last Post: - 30th December 2006, 14:03
  3. motors browning out PIC
    By mbw123 in forum mel PIC BASIC Pro
    Replies: 13
    Last Post: - 17th November 2006, 02:50
  4. CD ROM Motors.
    By Dwayne in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 14th April 2006, 17:59
  5. problems with Servo Motors...
    By saturnX in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 11th March 2006, 01:43

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts