PBP projects for R/C models


Closed Thread
Results 1 to 40 of 772

Hybrid View

  1. #1
    Join Date
    Feb 2006
    Location
    Gilroy, CA
    Posts
    1,530


    Did you find this post helpful? Yes | No

    Default 5 ch RC PWM measurement with pass through

    I made some progress with 5 channel PWM measurement using a single pin. Curently 5 RC channels are being measured using capture on a PIC12f683. Right now, only one channel is being passed through, but it is possible to get a max of 4 channel pass through on this chip. Bruce gave me the idea of measuring all 5 channels on one pin with his remote code learning thread: http://picbasic.co.uk/forum/showthread.php?t=12555

    I need to work on getting channel 1 to be recognized as channel 1. Somehow, I need to check for a low on CCP1 for 3ms or so (between channel 5 and channel1). Anyone got a suggestion on how to do this?

    Right now, you have to restart the circuit a few times to get channel 1 output to be channel 1 input. It sometimes selects channel2,3,4 or 5 (depends when you turn the chip on, and which rise it sees first). But the output now is pretty rock solid, no jitters.

    I tried to label my ASM pretty well, but I need to work on this overall, especially the variables.

    total words used = 275

    http://scalerobotics.com/PWMpassthrough.html

  2. #2
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Wink

    Hi,

    Ok, it's not PBP ... But it does the trick.

    http://www.rcgroups.com/forums/showthread.php?t=576165

    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  3. #3
    Join Date
    Feb 2006
    Location
    Gilroy, CA
    Posts
    1,530


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Acetronics View Post
    Hi,

    Ok, it's not PBP ... But it does the trick.

    http://www.rcgroups.com/forums/showthread.php?t=576165

    Alain
    Thanks Alain (was that for me, or Ken??),

    But I currently am able to encode 1 channel while decoding 5 channels with the below code:

    http://scalerobotics.com/PWMpassthrough.html

    And soon should be able to add 3 outputs, and have 4 encoded channels out, while decoding 5 channels in with the pic12f683 (and 3 diodes).

    But, what I can't get my head around is how to ensure the CCP1 interrupt starts the first time on RC channel 1 (first pulse). It needs to look for a low of 3ms or so, to ensure channel 1 is looking at channel 1.

    Oh .... and I need to do this in ASM.

    Thanks for any help you can offer.
    Last edited by ScaleRobotics; - 9th February 2010 at 19:20.

  4. #4
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Wink

    Hi,

    Sorry ... I didn't verify the link ... ( Xtal wrote both enc and dec ...)

    those ones are real decoders

    Alain
    Attached Files Attached Files
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  5. #5
    Join Date
    Feb 2006
    Location
    Gilroy, CA
    Posts
    1,530


    Did you find this post helpful? Yes | No

    Default

    Thank you very much Alain, just what I was looking for!

    Need to see how they do their "sync gap", but I notice he has a number of other enhancements as well ... interesting.

    Walter
    Last edited by ScaleRobotics; - 9th February 2010 at 22:28.

  6. #6
    Join Date
    Nov 2009
    Location
    Fitchburg, Mass
    Posts
    483


    Did you find this post helpful? Yes | No

    Talking Been Preoccupied

    Thanks everyone for working on the RC PWM problems.

    Meanwhile I have built a autonomous toy car from the ideas voiced by fritsl in Lets Built Robots.

    The DPDT switches work. I have two separate battery packs. The power for the servo and the wheels shares nothing with the power for the PIC and other logic. Not even the ground circuit! This should keep the noise down.

    I am using the LED's on the PICkit2 to help debug. At least I can know which routines have been visited. I wish I could figure out a way to know what are in my variables. The USB programmer can read and write all memory locations. Where do I read about real time debugging?

    Oh, yes, my new PIC16F887 book arrived via air mail at the Fitchburg, MA Post Office. It is published by MIKROELEKTRONIKA d.o.o in Belgrade, Serbia. How small the world has become.

  7. #7
    Join Date
    Nov 2009
    Location
    Fitchburg, Mass
    Posts
    483


    Did you find this post helpful? Yes | No

    Thumbs down Setting break points??

    That's the word I have been looking for.

    Is there a mechanism in PBP for setting break points.

    Once that is done, is there an easy way using PICkit 2 Programmer to read the contents of a particular register?

    Ken

Similar Threads

  1. PBP Book
    By Bruce in forum Off Topic
    Replies: 83
    Last Post: - 4th October 2021, 12:55
  2. PBP Extensions, What are they?
    By PJALM in forum PBP Extensions
    Replies: 9
    Last Post: - 28th September 2021, 11:26
  3. Compiler differences between PBP 2.33 & 2.46
    By nikopolis in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 2nd May 2006, 19:01
  4. Newby- PBP wont compile for 18F (MPLAB)
    By jd76duke in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 17th December 2005, 23:30
  5. Making PBP code more modular
    By forgie in forum General
    Replies: 30
    Last Post: - 25th October 2005, 16:24

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