understanding the pulse.


Closed Thread
Results 1 to 37 of 37

Hybrid View

  1. #1
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    I was measuring it before not connected to anything. Just connected to the ground pin and the probe to the signal pin.

    I think I have enough to get me started now tho.

    Bit confused about the signal its putting out, looking at the scope I can see what I need to do but using the pulsin data its kinda jumpy.

    I have done the standard servos like mentioned above 1-2 ms constant freq but this signal is not a constant freq it seems. On the scope it looks like the width and freq changes.

    Standard servo I don't remember the exacts but like 100 to 225 or something that would be the pulse width.
    Can you explain what I should be reading on the pulsin when the freq changes?

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


    Did you find this post helpful? Yes | No

    Default

    and how fast does it change?

    will this help to do few reading and do and average... but reject those which are to away of the midpoint...

    How about using count... or an internal timer?

    what's the most important? the frequency or the duty cycle?

    sorry i don't know anything in RC receiver..
    Steve

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

  3. #3
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by geckogrotto View Post
    I was measuring it before not connected to anything. Just connected to the ground pin and the probe to the signal pin.

    I think I have enough to get me started now tho.

    Bit confused about the signal its putting out, looking at the scope I can see what I need to do but using the pulsin data its kinda jumpy.

    I have done the standard servos like mentioned above 1-2 ms constant freq but this signal is not a constant freq it seems. On the scope it looks like the width and freq changes.

    Standard servo I don't remember the exacts but like 100 to 225 or something that would be the pulse width.
    Can you explain what I should be reading on the pulsin when the freq changes?
    The frequency isn't changing, although it might look like it is changing based on what the rest of the servo's are doing. In other words, say you've got 4 servos...1-3 are all at one end with a pulse width of 1ms and the 4th servo is the one you're playing with. It'll look like one thing on the 'scope. Then if servo's 1-3 go to the other extreme at 2ms, the signal off the 4th servo will look like something else on the 'scope.

    It might be a bit jumpy because the input frequency is 'only' 50hz or so, and it's supposed to vary a little bit. Play around with your trigger and 'sweep delay' if you have one on your 'scope. You should be able to get it to smooth out. I've got a Tek 2246A, 4 channel 'scope, I can plug 4 servo's into it at once and be able to see the pulse's on all 4 and they are all steady. But, I have to play with the trigger and sweep delay a bit before they steady out.

  4. #4
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    skimask, I don't think this is the case.
    This isn't a standard servo im working with, When I measure a signal from a standard servo I see what your talking about and it works as expected.

    Here is a little pic to help explain I hope.


    I don't know how to figure out to read the signal because is moving around unlike the standard servo signal.

    Mister_e
    Will reply to you in another post
    Attached Images Attached Images  

  5. #5
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    >>and how fast does it change?
    Looks like its repeating every 14ms on one end and 6.5 on the other end.

    >>will this help to do few reading and do and average... but reject those >>which are to away of the midpoint...

    I'm not sure if that would work here

    >>How about using count... or an internal timer?
    I am not sure how to do that with the signal im getting.

    >>what's the most important? the frequency or the duty cycle?
    In this case I think its the frequency that matters. But I don't know how to get the freq from picbasic.

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


    Did you find this post helpful? Yes | No

    Default

    only the duty cycle change, Ton+Toff remain the same. so using Pulsin to read it should work. case not, the internal timer would be perfect...

    Code:
    ' just a snip... not the whole thing...
    while InputIO=0 : wend ' wait for rising edge
    Start timer
    Whiel InputIO=1 : wend ' wai for falling edge
    stop timer
    copy Timer register to a variable
    enjoy!
    Or use an interrupt to start and stop the timer and dump the results to a variable.
    Steve

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

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


    Did you find this post helpful? Yes | No

    Default

    >>How about using count... or an internal timer?
    I am not sure how to do that with the signal im getting.
    forget the frequency, from your picture, it's only the dutycycle that change.

    >>what's the most important? the frequency or the duty cycle?
    In this case I think its the frequency that matters. But I don't know how to get the freq from picbasic.
    to get frequency, you could use COUNT, but in your case it should always be the same.
    Steve

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

  8. #8
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    forget the frequency, from your picture, it's only the dutycycle that change.
    are you sure? I don't know much about reading the scope but to me it looks like between signal 3 and 4 on my picture the freq of the pulse is changeing but not on 1 -2. I need to get this to work on the 2 and 3 example.

    Am I reading the scope wrong?

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


    Did you find this post helpful? Yes | No

    Default

    can you do some screen capture of it?

    Sorry but i have to ask, Do you know the difference between DutyCycle and frequency?

    F.EDIT : SORRY... yeah seems the last one is different.

    can't tell you if it's normal or what... the only thing i see is to do some error trapping, frequency/duty cycle, averaging etc etc etc.
    Last edited by mister_e; - 26th February 2007 at 03:38.
    Steve

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

  10. #10
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by geckogrotto View Post
    skimask, I don't think this is the case.
    This isn't a standard servo im working with, When I measure a signal from a standard servo I see what your talking about and it works as expected.

    Here is a little pic to help explain I hope.


    I don't know how to figure out to read the signal because is moving around unlike the standard servo signal.
    (reference the picture from the earlier post)
    That's what my picture on my 'scope looked like when I had the 4 channels plugged in. If the first servo's pulse changed, the rest of the pulses changed with it (i.e. the 2-4 pulses slid back and forth) if I was triggering off Channel 1. and I was using a standard Futaba FM RX for aircraft.

    What kind of servo is it? What brand or whatever?

  11. #11
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    If your look at the pic there are 2 sets of signals.
    top 2 are 1 signal(standard futaba)
    bottom 2 are the 2nd signal (unknow)

    The first 2 are from a standard servo signal. Thats normal futaba whatever.
    No matter how long the pulse is the peaks start at a set interval.

    The 2nd 2 are from off brand cheapo thing. It if you notice looks different than the top 2 at the same settings. When the low shrinks the pulses get closer.

    I'm getting it now tho.

  12. #12
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    Oh I think we may be comparing two seprate things skimask.
    I'm looking at just one servo channel not all of them at once like I think you are.

  13. #13
    Join Date
    Aug 2006
    Posts
    91


    Did you find this post helpful? Yes | No

    Default

    Ok that works like a charm measuring the freq will let me know exactly where the stick is

    Thanks for all the help!


    You guys rule.

  14. #14
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by geckogrotto View Post
    Oh I think we may be comparing two seprate things skimask.
    I'm looking at just one servo channel not all of them at once like I think you are.
    Well, ya, I get what you've got cooking (I think)...but what I'm saying is that I'm looking at 4 channels at once on 4 seperate channel's on the 'scope. If the first channel's pulse width gets lengthened, the rest of the channels get slid back a bit, and vice-versa if the pulse width gets shortened.
    BUT...if I look at the total string (i.e. the whole string of channels as they are all received with all the data on one line), at the end of the chain (in my case 8 channels), there's always a sync pulse of at least 4ms that 'resets' the receiver back to channel 1. So, if each channel's pulse width is 2ms with 8 channels, that's 16ms + a 4ms sync pulse. And there is also an 'inter-servo' (for lack of a better phrase) time of a few us or so. So, if you're looking, or maybe just concentrating on one channel, it may appear that the frequency changes a little bit because the pulse width is changing. It can change a little bit, but overall, it will keep happening at a rate of about 50hz.

    Wait a minute... I forgot what you were trying to do in the first place...what's the end result supposed to be?

Similar Threads

  1. Pulse Capture and byte building
    By boroko in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 21st July 2009, 01:59
  2. Single digit 7 Seg LED clock - PIC16F88
    By thirsty in forum Code Examples
    Replies: 4
    Last Post: - 17th July 2009, 08:42
  3. Replies: 3
    Last Post: - 13th September 2008, 17:40
  4. Better understanding PULSIN
    By Wirecut in forum mel PIC BASIC
    Replies: 12
    Last Post: - 29th June 2008, 10:17
  5. Pulse Frequency Multiplication
    By jamie_s in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 21st August 2005, 10:39

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