How do I give a radio control car autonomous control


Closed Thread
Results 1 to 40 of 191

Hybrid View

  1. #1
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Yes, install the PicKit software
    Load the HEX into it and and click write. You can turn the power on and off from there also.
    There should be a PDF manual with the PicKit or you can get it from Micrchips web site.
    Dave
    Always wear safety glasses while programming.

  2. #2
    Join Date
    Jan 2009
    Location
    California, USA
    Posts
    323


    Did you find this post helpful? Yes | No

    Default

    Yep, like Dave sez... load up the PICKit software.

    The user guide for the PICKit should get you started.

    Then it's time to start writing soem simple programs like "Blinky LED" to get a feel for how stuff works.

    That 16F887 should be great for your little car. Lots of I/O, 2 HPWM channels, plenty of pins that support ADC to read your sensors.

    You mentioned earlier that you have no 'scope, just an old voltmeter. That should be fine for most troubleshooting. You might want to watch Craigslist or Ebay for a used scope. For low speed stuff you can also use a voltage divider on the microphone input of your soundcard, and use a program like Audacity or similar to capture your waveforms for viewing.

    You're gonna have fun. Load up that PICKIT software and get it going!


    steve

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


    Did you find this post helpful? Yes | No

    Default My problem is not PICkit software it is PICBASIC

    Guys,

    Last week I had PICkit Assembly code and HI-TECH C code working.

    I plucked down $250 for PICBASIC. This is what is not working. It compiles but refuses program. It says that it can not find the programmer. I think its programs are duplicates of what came with the Debug Express package. Some how they are getting confused.

    I have a second RC car. It is toy level. Both drive wheels and steering are driven by motors. It is easy to control such a car by PIC. All it needs to do is ON and OFF forward, ON and OFF reverse, ON and OFF steer left, ON and OFF steer right. OFF + OFF makes it steer straight. The steering mechanism has a physical limit mechanism. Controlling the above can be done with four DPDT switches. The car carries 7.5 volts worth of AA batteries.

    Back to getting PIC BASIC working..

    Thanks,
    Ken

  4. #4
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    If the code is compiling look in your project directory for a HEX file. If one is there then MCS and PBP are working. I would not bother with trying to get MCS to run the PicKit2. Use the PicKit2 software for putting the code in the chip.

    Make sure each project has a directory of it's own.

    So let us know if you have a HEX file after you hit F9 in MCS.
    Dave
    Always wear safety glasses while programming.

  5. #5
    Join Date
    Jan 2009
    Location
    California, USA
    Posts
    323


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Kenjones1935 View Post
    It is easy to control such a car by PIC. All it needs to do is ON and OFF forward, ON and OFF reverse, ON and OFF steer left, ON and OFF steer right. OFF + OFF makes it steer straight. The steering mechanism has a physical limit mechanism. Controlling the above can be done with four DPDT switches.
    Hmmm. Just off the top of my head, I should think you'd only need 2 DPDT relays (1 for forward/reverse, 1 for left/right) and 2 SPST relays, one to turn power on and off to each motor.

    Actually, since your 16F887 has 2 HPWM channels, all you need are the 2 DPDT relays for forward/reverse and left/right, and 2 MOSFETS, one on the "low side" of each motor. Now you can use your HPWM channels for ON/OFF control with the added benefit of having SPEED CONTROL on both motors!

    Change your motor speed with a single line of code!

    Just a thought....

    steve

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


    Did you find this post helpful? Yes | No

    Default I am upset!!

    I was doing fine with Assembly and HI-TECH C code.

    I thought it would be best to go for PICBASIC. I could not find on the Microcode WEB site the $100 PICBASIC product. The only thing available is the $250 PICBASIC PRO package.

    It does not work at all!!

    The paper manual is useless regarding installation. For example one of the installation windows asks me if I want the compiler in my "environmental path". I have not used DOS since the 1990's. Frankly I forgot what my environmental path is, er was... No comment on this in the Copyright @2009 microEngineering Labs, Inc. manual

    I installed everything. It could not find the compiler.

    I uninstalled everything Microchip. MPLAB ide V9.30 refused to uninstall per my XP "remove program" feature. I finally deleted the whole C:\Programs Files\microcode directory.

    Then, with only the PICBASIC disk in my CD reader I installed PBP again.

    All seemed OKAY until I tried the simplest of tests - write, compile and build BLINK.BAS.

    I succeeded in moving BLINK.BAS into my workspace. The COMPILE and BUILD said,

    "Could not spawn language tool. Check command line options (5)"

    What th' ?? The free software has been easier to install and understand and better documented than the $250 package.

    Any idea in my computer where there is a file that will explain that compiler comment?

    Ken

  7. #7
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Can you tell us exactly what does not work? Do not take this the wrong way. Ut it could be a number of things.

    For starters you said in another post that the code compiled. Now it does not work at all???

    Are you using Micro Code Studio for the code editor?

    And who is "Microcode WEB" ? I hope you did not buy from someone that is not authorized.
    Dave
    Always wear safety glasses while programming.

  8. #8
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Ken,
    I did not mean to sound harsh in the above post.

    I will pit together some screen shots tonight to help you get started.
    Make sure you have Pic Basic Pro, Micro Code Studio and MPLAB installed in the default directories and we will get you going. They should all be on the Pic Basic CD.

    What operating system are you running ?
    Dave
    Always wear safety glasses while programming.

Similar Threads

  1. Car radio (Car radio and electronics support forum)
    By freewillover in forum Forum Requests
    Replies: 1
    Last Post: - 1st July 2009, 20:41
  2. Remote Car Starter Safety
    By CocaColaKid in forum General
    Replies: 8
    Last Post: - 22nd November 2005, 10:10

Members who have read this thread : 1

You do not have permission to view the list of names.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts