Re: My hat is off to Microchip and their CEO!

formatting link

Sigh, I've been in that type of meeting before. Not as Mr Head, of course.

Reply to
DJ Delorie
Loading thread data ...

What's the PIC architecture like these days?, I heard it was always pretty messy in terms of memory and a real pain to program in assembly.

Still it can't be much worse than some of the MAXQ series.

Reply to
Mark Harriss

Tons better. They have the PIC18 series which is more C friendly than the old 16 series, the 16 bit PIC24 series which is quite nice, and the new 32 bit PIC32 series based on a MIPS 4K core. Plus the dsPIC too. And why would you want to program in assembler anyway for all but niche areas?

Even the old 16 series is not messy if you use a good C compiler, it takes care of any issues for you.

Dave.

--
================================================
Check out my Electronics Engineering Video Blog & Podcast:
http://www.eevblog.com
Reply to
David L. Jones

You order ones with enough memory internally. The ones I've used were USB connected and the easiest programming I've ever done. The external pins are all either built in or macros in a .h file. I honestly never checked

-- Les Cargill

Reply to
Les Cargill

That?s because you don?t have a MBA ;D

Cheers

Reply to
Martin Riddle

And *that* is why I refuse to get an MBA :-)

Reply to
DJ Delorie

There are really several PIC architectures.. the 12-bit instruction, (PIC16F54, PIC12F509 etc.) the 14-bit instruction (most other PIC16F,

16 bit instructions (PIC18) (PIC17 is a dead end), the PIC24/DSPIC, and the PIC32. They've also extended the instruction sets in a couple of families. The 12-bit type is the most limiting, but also the most parsimonious with resources. Even C can't hide the ugliness there, but in most cases you won't notice or care because the tasks are relatively simple. For example, IIRC constant arrays can't exceed a page in size (256 bytes).

IThe PIC18 is quite pleasant to program in assembler... just use access ram for everything you can, and you don't have to think much about banking. About the only thing I miss is an indexed plus offset addressing mode, and I think they have that in the extended instruction set mode, but I have not played with that (there are some trade-offs or it would not have to be another mode).

As to the C vs. asm question.. well, if you have to have a USB or Ethernet (or Bluetooth) stack then you're in C territory. For less than 16 k bytes of program memory, assembler probably deserves a look, especially if you're not doing C-like things. And it depends on the skill set and prior experience the programmer has, as well as whether it's worth wringing out what is usually a Even the old 16 series is not messy if you use a good C compiler, it takes

The Hitech C compiler (even the free 'lite' one) works pretty well, though I've found some irritating bugs. It will even generate useful code for the 12-bit instruction chips.

Best regards, Spehro Pefhany

--
"it\'s the network..."                          "The Journey is the reward"
speff@interlog.com             Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog  Info for designers:  http://www.speff.com
Reply to
Spehro Pefhany

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.