Serial Communication Problem


Closed Thread
Results 1 to 24 of 24

Hybrid View

  1. #1
    leemin's Avatar
    leemin Guest


    Did you find this post helpful? Yes | No

    Exclamation

    ok. thanks for you all previous help. i can work with the USART interrupt with my code already but now i encounter with a new problem.
    im using 16f877a.
    i need to receive a string of command from computer. then execute some function after received a valid command. now i need to execute the blinking effect by toggling the enable pin to let the led on and off continuosly untill another set string of command come in and either stop blinking or continue blinking.
    but now i found out that the blinking sub-routine is a dead loop. when i continuosly execute the blink function and a new string command come in from computer my firmware will hang there.
    any solution for this?
    i need you all suggestion.
    thanks

  2. #2
    Join Date
    Sep 2004
    Location
    Mentor, Ohio
    Posts
    352


    Did you find this post helpful? Yes | No

    Smile

    Hi Leemin,

    It's a great idea to have the micro do as much as possible but sometimes it's necessary to have external hardware do some work to free up the micro to do other things more important. Add a gated pulsing circuit that you only need the micro to turn on and off. This can be a single chip circuit like using a CD4093 or even a CD4060. A CD4060 lets you choose flash rates juct by selecting the appropriate output. These are simple circuits and only require a few discretes to finish the job. Let the micro do the more serious stuff.

    BobK

Similar Threads

  1. Replies: 18
    Last Post: - 4th July 2017, 14:26
  2. serial communication problem
    By kindaichi in forum Serial
    Replies: 13
    Last Post: - 11th March 2010, 16:37
  3. Replies: 5
    Last Post: - 20th March 2006, 01:34
  4. Problem in Serial Communication
    By uuq1 in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 5th June 2005, 07:17
  5. Replies: 8
    Last Post: - 11th November 2004, 20:08

Members who have read this thread : 2

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