Oscillator stops when touching with a wire


Closed Thread
Results 1 to 24 of 24

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default

    Hey Skimask,

    Thanks for your reply !

    I'm still struggling how to do it. If i use a tight loop with timeout which receives character by character, i'm afraid if only one bit is send (my famous glitch ), the timeout statement won't work and the endless loop will start (untill additional information is received)

    I'm going to try it and will keep you in touch. If you remember you other suggestion, you're more than welcome

    Take care

    Wilbert

  2. #2


    Did you find this post helpful? Yes | No

    Default

    If i look in the manuel on page 135 (serin2) "if the serial input pin stays in the idle state during the timeout time, the program will exit the SERIN2 command and jump to label". In my case, the input pin doesn't stay idle because it received one glitch ...

    Same for Debugin on page 58 ...

    Hum, i don't see it yet how i can solve it

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


    Did you find this post helpful? Yes | No

    Default

    Pull-up or pull-down resistor is an easy to test Solution?
    Steve

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

  4. #4
    Join Date
    Sep 2003
    Location
    Vermont
    Posts
    373


    Did you find this post helpful? Yes | No

    Default

    It sounds like static electricity is the culprit here. I understand touching an input, but the ground should be somewhat immune to the phenomena. It sounds like there is a ground loop in the connections. Look for multiple lines connected to ground in the same run of cable. Touching one will cause an imbalance. So if the shield is connected to ground, and another line in the cable is, this could cause a problem. The simplest fix is to not connect the shield on one end of the cable. While it sounds counter intuitive, it might be the cause, or one of them.
    Ron

  5. #5
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Wilbert Ingels View Post
    If i look in the manuel on page 135 (serin2) "if the serial input pin stays in the idle state during the timeout time, the program will exit the SERIN2 command and jump to label". In my case, the input pin doesn't stay idle because it received one glitch ...
    The fix might be something as simple as:
    Code:
    loop:
    datagood = 0
    SERIN2 (((your code here with the shortest timeout possible, timeoutlabel, etc.etc....)))
    datagood = 1
    goto overtimeoutlabel
    timeoutlabel: if datagood = 0 then goto loop  'data was bad, try again
    overtimeoutlabel: continue code here....
    if it does glitch, you check 'datagood'. If datagood is 0, then it glitched or didn't receive what you wanted and try again

    Aside from that, I agree with the other guys, ya gotta find the root cause of the glitches...

  6. #6


    Did you find this post helpful? Yes | No

    Default

    Hey Guys,

    Thanks for the feedback !

    Yesterday, i've changed the RS485 chips. I was using SN75176 and i've changed them for MAX481 and the glitched are gone. It seems that SN75176 is more sensible and thus in my case less usable in my application. The MAX481 untill now never gave one glitch. I'm working now on the timing aspects because these seems different between SN75176 and MAX481.

    I've also went into more detail in how PBP works. I understand the little drawbacks (in terms of serial communication) of the language better now but i must say that, the longer i work with PBP, the more enthusiastic i am. It is a great language and a fantastic tool.

    Take care

    Wilbert

Similar Threads

  1. 1 Wire Search Routine
    By Dave in forum Code Examples
    Replies: 3
    Last Post: - 4th March 2016, 07:39
  2. Need Single wire serial LCD converter example
    By polymer52 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 16th December 2009, 02:30
  3. 24c16 vs 24lc256 and serial wire identification
    By inspired4real in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 14th October 2008, 17:37
  4. Looking for low Wattage heater wire
    By jmgelba in forum Off Topic
    Replies: 1
    Last Post: - 21st November 2005, 18:22
  5. RPM with wire and PIC
    By Dwayne in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 14th December 2004, 20: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