Automatic Toilet Flusher


Closed Thread
Results 1 to 40 of 99

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Posts
    2,405


    Did you find this post helpful? Yes | No

    Default

    Funny that should work. Here's a few things to check.

    Make sure you're using a separate power supply for your servo, and you have a common ground between them. Running a servo from your controller power supply can cause problems if you aren't using a hefty bench type power supply with a lot of filtering to remove motor noise.

    Make sure you're using the correct voltage for your servo. These normally run on 4.8 to 6V. If you're trying to operate your servo from 9V that may be a problem. Most hobby type servos can't handle 9V, and a 5V control pulse from the PIC is going to look pretty weak to a servo operating at 9V.

    I tested the above code example, and it works as expected with a Hitec HS311 servo operating at 5V with a 16F627. Note some servos will move 90 degrees right or left, so you can tweak the value in the Flush routine between 200 to 250 to extend the rotation range.

    My HS311 moves full right with 250, and centers with 150.
    Regards,

    -Bruce
    tech at rentron.com
    http://www.rentron.com

  2. #2
    Join Date
    Jul 2007
    Posts
    67


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Bruce View Post
    Funny that should work. Here's a few things to check.

    Make sure you're using a separate power supply for your servo, and you have a common ground between them. Running a servo from your controller power supply can cause problems if you aren't using a hefty bench type power supply with a lot of filtering to remove motor noise.
    Yep I am using a separate power supply for both and each is filtered

    Make sure you're using the correct voltage for your servo. These normally run on 4.8 to 6V. If you're trying to operate your servo from 9V that may be a problem. Most hobby type servos can't handle 9V, and a 5V control pulse from the PIC is going to look pretty weak to a servo operating at 9V.
    Yep I used 5volts and I even tried it with 6



    I tested the above code example, and it works as expected with a Hitec HS311 servo operating at 5V with a 16F627. Note some servos will move 90 degrees right or left, so you can tweak the value in the Flush routine between 200 to 250 to extend the rotation range.

    My HS311 moves full right with 250, and centers with 150.
    I am using a hi-tec HS-322HD

    And I used another servo which was a futaba S3003
    but it was modified for continues rotation but it was rotating in 90% degree section
    but that was when it was not in contact but when it was in contact it didn't move just like the hs-322HD

  3. #3
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Techbuilder View Post
    but that was when it was not in contact but when it was in contact it didn't move just like the hs-322HD
    You mean in contact with the handle? If so, maybe the servo is not strong enough?
    Dave
    Always wear safety glasses while programming.

  4. #4
    Join Date
    Jul 2007
    Posts
    67


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mackrackit View Post
    You mean in contact with the handle? If so, maybe the servo is not strong enough?
    No contact with the IR led


    Although I figured out that I have to modify the servo to do 180 degrees
    because mine only does 60 degrees, still doesn't explain why it is only going off when it is not in contact with the IR led.

  5. #5
    Join Date
    Jul 2007
    Posts
    67


    Did you find this post helpful? Yes | No

    Default

    Actually if I spin it by hand it spins enough
    so I don't believe that's the problem.

Similar Threads

  1. Automatic 240V / 110V selector
    By The Master in forum Off Topic
    Replies: 5
    Last Post: - 13th October 2008, 00:33
  2. LCD automatic management?
    By ruijc in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 26th September 2008, 11:24
  3. Automatic VB6 to pic serial connection
    By arniepj in forum Code Examples
    Replies: 13
    Last Post: - 10th January 2008, 07:57
  4. Automatic turn off
    By AMay in forum Schematics
    Replies: 22
    Last Post: - 6th February 2006, 12:31

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