Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Pic Programming software

Status
Not open for further replies.

grrr_arrghh

New Member
Hi.

I've decided to 'take the leap' in pic, and will buy probably buy the P16PRO40 from Quasar (only £10!), but need some software to go with it.

I have seen software, thats free to download, like Nigels, but I was remembering our school electronics lessons *sigh* where they kept going on about a method of programming PICs, that was very simple.

The code would look something like this, I think...

01 Pin4 High
02 Delay020
03 Pin4 Low

in its simplest form, anyway. I reckon I could understand that, without to much trouble, so can anyone recommend a free downloadable pic progger that will allow me to program in whatever language that it...?

Also, with pic progging hardware, some connect via serial, and some via parallel. Is this where the difference ends?

Cheers,

Tim
 
grrr_arrghh said:
I have seen software, thats free to download, like Nigels, but I was remembering our school electronics lessons *sigh* where they kept going on about a method of programming PICs, that was very simple.

The code would look something like this, I think...

01 Pin4 High
02 Delay020
03 Pin4 Low

in its simplest form, anyway. I reckon I could understand that, without to much trouble, so can anyone recommend a free downloadable pic progger that will allow me to program in whatever language that it...?

You can use Winpicprog, all that WPP does is upload a .HEX (a 'machine code' file) file to the pic trough your P16PRO40 hardware. The creation of this .HEX file is done with a compiler, a programming language. You've got diffirent options: assembler, C compilers, Basic compilers and some compiler that your school uses. But basically, every one of them will output a .HEX file at the end wich is what WPP uploads.

grrr_arrghh said:
Also, with pic progging hardware, some connect via serial, and some via parallel. Is this where the difference ends?
All that parallel programmers do is 'bit bang' the IO lines to the pic directly and the programming signals are created directly by the pc.

Most good serial programmers have a controller on board, The pc sends the data to the controller on the programmer board, and it's the controller that does the actual programming.
Except JDM, wich is a exception. It uses the handshaking lines of the serial port to bit bang the IO lines, in a way very similar to the parallel ones, except that it uses the serial port itself as a power supply. Because some serial ports don't supply enough voltage JDM tends to give problems on some computers.

I think parallel ones are the best, because they are a straigt interface to the pc. Support for new pic's only requires an update of the upload software. while adding new pic's to a serial one with onboard processor sometimes requires the onboard processor to be reprogrammed.
 
Exo said:
The creation of this .HEX file is done with a compiler, a programming language. You've got diffirent options: assembler, C compilers, Basic compilers and some compiler that your school uses.
Oh. Ok, so are there programs that could help a beginer to write the code, and then output it as a .hex file? Or would I have to write the code myself (using whatever tutorials etc that I could find), then use a compiler to turn it into a .hex file, and then use some like WPP to upload it to the chip?

thanks,

Tim
 
I would suggest downloading MPLAB IDE from microchip's website, Look and learn from Nigel's tutorials and other examples on the net and start your programming in assembler.

Whatever higher language you want to use, C, basic or any other, you cannot effectivly program if you don't have a grasp on the basic design and concepts of the pic. And the only way to get to know any CPU is to learn it's assembly
 
having read , and various things found on the net, I have a couple of questions.

The code in Nigel's tutorial, (which he also has available for download in .asm format) are written in what language?

MPLAB will quite happily take the .asm files and export them as .hex files, but it also has a 'build' option. The help file confused me even more when i looked this up, so can anyone explain what this is/does?

Cheers,

Tim
 
grrr_arrghh said:
The code in Nigel's tutorial, (which he also has available for download in .asm format) are written in what language?

They are in MicroChip assembler, hence the .ASM at the end. This is what PIC's use, any other language simply produces assembler than assembles it to produce a HEX file.

MPLAB will quite happily take the .asm files and export them as .hex files, but it also has a 'build' option. The help file confused me even more when i looked this up, so can anyone explain what this is/does?

I never use MPLAB (I also found it very confusing, it does a great deal more than I want to!), I just use the assembler part of it, MPASM for Windows, this takes the .ASM file and assembles it to give a .HEX file for loading into WinPicProg.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top