Author Topic: PIC / AVR showdown: which should I use ?  (Read 3810 times)

0 Members and 1 Guest are viewing this topic.

Offline SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17882
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
PIC / AVR showdown: which should I use ?
« on: March 26, 2010, 02:22:27 pm »
Ok now I'm not after starting a fight, but after daves PIC versus AVR blog I got thinking, I have a power management project for vehicles that requires an ADC and PWM output, as it is for a car which has an ever constant variation in operating conditions it needs to operate quikly to adapt, a 12F615 @ 8 MHz just handled this but I wanted to make it a bit more robust, would an AVR uC be better for this sort of thing ? I remeber Dave saying in his blog that AVR's are more efficient although who cares because of the speed of any uC anyhow, well in my case it is the determining factor.

OK so please a civil discussion about this  ;)
 

Offline armandas

  • Frequent Contributor
  • **
  • Posts: 336
  • Country: jp
    • My projects
Re: PIC / AVR showdown: which should I use ?
« Reply #1 on: March 26, 2010, 06:24:45 pm »
I'd like to restate what Dave said: it does not matter. You already got a PIC, and since you run it at only 8 MHz, I'd say get a faster clock.

Get an AVR, when you're ready for something new.
 

Offline SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17882
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: PIC / AVR showdown: which should I use ?
« Reply #2 on: March 26, 2010, 06:30:33 pm »
the faster the pic runs the higher the minimum PWM frequency is, idealy I need a 125 Hz PWM output but can settle for 250, but that means running the pic at 4 MHz, my thought was if the pic takes 4 cycles / instruction and the AVR takes 1 then in a similar situation with the AVR I would have the same PWM frequency but effectively 4 time the code speed,

after looking into it a bit more I think that I may be able to pull it off with a pic which is the best was as I already have the pic's and the programmer and the knowledge needless to say I have already developed the program.
 

Offline David

  • Frequent Contributor
  • **
  • Posts: 279
  • Country: gb
Re: PIC / AVR showdown: which should I use ?
« Reply #3 on: March 26, 2010, 06:56:59 pm »
If you want a quick way to produce a faster clock, use the internal PLL (If its supported).

Dave
David
(United Kingdom)
 

Offline SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17882
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: PIC / AVR showdown: which should I use ?
« Reply #4 on: March 26, 2010, 07:04:53 pm »
how do I do that ? are you refering to chips like the 18F1220 that has a X4 PLL, will the PWM run off the crystal clock and the pic core off the PLL simulataneously ?, if I increase the clock in other devices like the 12F615 I now use the PWM minimum frequency also increases.
 

Offline Anders

  • Contributor
  • Posts: 34
  • Country: se
Re: PIC / AVR showdown: which should I use ?
« Reply #5 on: April 04, 2010, 06:17:24 pm »
I tried AVR’s when I started with micros a few years ago but I found the ADC’s much too slow for many apps. I have used PIC’s ever since and I don’t look back. Hopefully the AVR ADC’s have improved since then but I’m not sure.
Proper Planning Prevents Piss Poor Performance
 

Offline SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17882
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: PIC / AVR showdown: which should I use ?
« Reply #6 on: April 04, 2010, 06:25:52 pm »
well I'm already pic prepared so might as well stick with them
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf