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.
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.
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
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
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.
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
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
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.
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.
Bookmarks