Serin and TMR0


Closed Thread
Results 1 to 7 of 7

Thread: Serin and TMR0

Hybrid View

  1. #1
    yaskolo's Avatar
    yaskolo Guest


    Did you find this post helpful? Yes | No

    Default Timer0,pasue,serin :(

    i am using tmr0 interrupt in picbasic.
    when i use pause,pulsin or serin command interrupt is not work correctly. can you help me for this. how can i use interrupt correctly with serin and pause.
    or if i use asm interrupt code is it work ?.

    thanks

  2. #2
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Those statement you said must be terminated prior to jump to interrupt routines. Using loop of short PauseUs, Using internal USART, create your own PULSIN statement will help.

    Now it depend of your skill level. Usually i don't use PULSEIN, but i use an internal TIMER in counter mode (something like RA4 T0CKIN) with a PAUSE (or pause loop). Same for Usart. Sure that's a bit harder but save a huge amount of codespace. Maybe, i said maybe, Darrel's instant interupt may be of help but i'd never test them.

    Even in assembler, SERIN, PAUSE, PULSEIN, should be terminated prior to jump to an interrupt handler. IMHO so far...
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

Similar Threads

  1. Problem with PBP interrupt and Serin, please help
    By rgregor in forum mel PIC BASIC
    Replies: 0
    Last Post: - 22nd August 2006, 20:02

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