program crashes: is it my code or the chip?


Closed Thread
Results 1 to 16 of 16

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default Re: program crashes: is it my code or the chip?

    EDIT: I was thinking about why you would think I am writing in C. I realize that the code that clears LATCH1 may seem a little confusing. There is a very specific reason for this. I am not clearing the variable. I am setting the I/O low. LATCH1 turns a latching relay on and it only needs a very short single pulse to actuate. No need to use a PULSE command. I want to turn it off after its job is done because keeping current consumption to a minimum is very important.

    This is also another reason behind my logic for wanting to use a secondary variable for LED1 and LATCH1. The "toggling" of LED1 and LATCH1 are done by LEDon and LEDoff, but after that I want to be able to turn LATCH1 off directly without affecting the LEDon and LEDoff variable. The higher level TOGGLE command does not allow for this.

    And as for BUTTON....I just don't like it. It does not seem that much more difficult to simply write the code out one level down. That way it allows you to customize it more easily. At least that is my inexperienced opinion thus far.
    Last edited by keithv; - 28th March 2014 at 03:00.

Similar Threads

  1. PICKit2 just crashes
    By johnbond in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 26th June 2011, 07:40
  2. Replies: 1
    Last Post: - 22nd May 2011, 19:37
  3. 16f690 crashes
    By Lincoln S. in forum Serial
    Replies: 8
    Last Post: - 26th November 2008, 08:32
  4. Program Code and Program Memory
    By DenFrod in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 8th February 2007, 14:51
  5. problems reading code from chip
    By leland in forum General
    Replies: 4
    Last Post: - 17th October 2004, 10:42

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