Q: using MCLR for Input on 12F683


Closed Thread
Results 1 to 40 of 47

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default Beware PULSOUT as a failsafe

    I crashed my RC aircraft using the PULSOUT command.

    PULSOUT is a 'toggle'. Whatever state the pin was in, it will flip for the duration specified in the PULSOUT command. That is bad news if your servo pin gets clobbered and you were expecting it to be low when you called the PULSOUT routine.

    To be safe, you MUST predefine the pin state before calling PULSOUT.

    e.g.

    LOW ServoPin
    PULSOUT ServoPin, 500

    will work every time.

    HTH
    Brian

  2. #2
    Join Date
    Jan 2009
    Posts
    34


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by BrianT View Post
    I crashed my RC aircraft using the PULSOUT command.

    PULSOUT is a 'toggle'. Whatever state the pin was in, it will flip for the duration specified in the PULSOUT command. That is bad news if your servo pin gets clobbered and you were expecting it to be low when you called the PULSOUT routine.

    To be safe, you MUST predefine the pin state before calling PULSOUT.

    e.g.

    LOW ServoPin
    PULSOUT ServoPin, 500

    will work every time.

    HTH
    Brian

    Thanks Brian, I've got the pulsout working...actual pretty good now. Just some issues with getting gpio.2 and gpio.3 to simply operate LED's!

    My code is posted above.

    Cheers,

    John.

Similar Threads

  1. How to MCLR by code for 16F877
    By fbestepe in forum mel PIC BASIC Pro
    Replies: 11
    Last Post: - 26th November 2014, 00:51
  2. 12F683 - Pin1 not working
    By ruijc in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 8th February 2014, 17:38
  3. 16f677a to 12f683
    By ChrisHelvey in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 25th July 2007, 06:16
  4. What does this MCLR instruction mean?
    By bartman in forum General
    Replies: 16
    Last Post: - 30th November 2004, 00:32
  5. I/O pin and MCLR
    By Dwayne in forum FAQ - Frequently Asked Questions
    Replies: 1
    Last Post: - 15th July 2004, 10:52

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