L298N Motor Driver using pwm code not working..


Closed Thread
Results 1 to 15 of 15

Hybrid View

  1. #1
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612


    Did you find this post helpful? Yes | No

    Default Re: L298N Motor Driver using pwm code not working..

    Hi,
    To change the speed you to execute the HPWM command. What I'm "objecting" against is this:
    Code:
    Main:
    HPWM.....
    HPWM.....
    Goto Main
    When you do it this your trying to update the PWM generator thousands of time per second. What happens when you update it faster then the frequency it's outputting? I don't know the answer.

    In the ISR, determine what duty cycles to send to each motor and execute the HPWM command there. That way you'll update the speed once each interrupt instead of thousands of times per second.

    /Henrik.

  2. #2
    Join Date
    Jun 2011
    Location
    Philippines
    Posts
    223


    Did you find this post helpful? Yes | No

    Default Re: L298N Motor Driver using pwm code not working..(Solved)

    Hi Henrik...many thanks for the kindly explaination...appreciate it very much...got it now.

    regards,
    tacbanon
    Last edited by tacbanon; - 1st October 2012 at 10:17.

Similar Threads

  1. Replies: 2
    Last Post: - 7th August 2012, 16:16
  2. Motor driver problem w/ HPWM
    By Amoque in forum General
    Replies: 2
    Last Post: - 21st May 2011, 20:51
  3. L293 motor driver options?
    By Ron Marcus in forum Off Topic
    Replies: 0
    Last Post: - 5th December 2006, 15:39
  4. Stepping motor Driver
    By mesamune80 in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 8th August 2006, 04:36
  5. Driver code for 14 segment LED display
    By Durward Searcy in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 12th December 2004, 20:08

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