Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Thread

Which C compiler?

Which C compiler?

2005-08-12 by klassasin

Right now, I'm using AVR Studio 4 (assembly) to program my AVRs.  I
know C/C++, so I think I might try some C coding for AVRs.  It looks
relatively easy, and it seems more and more people are using it. 
Which C compiler (cheap/free) would you all recommend?

Re: [AVR-Chat] Which C compiler?

2005-08-12 by david.pallant@prometheanworld.com

A vote here for Imagecraft http://www.imagecraft.com/software/. Very cheap and reliable C compiler. They also have a great email group where the compiler writer is a regular reader and contributor so they are very responsive.

Dave Pallant


AVR-Chat@yahoogroups.com wrote on 12/08/2005 15:53:52:

> Right now, I'm using AVR Studio 4 (assembly) to program my AVRs. �;I
> know C/C++, so I think I might try some C coding for AVRs. �It looks
> relatively easy, and it seems more and more people are using it.
> Which C compiler (cheap/free) would you all recommend?
>
>
>
>
>
> ------------------------ Yahoo! Groups Sponsor --------------------~-->
> Fair play? Video games influencing politics. Click and talk back!
>
.

> --------------------------------------------------------------------~->
>
> �
> Yahoo! Groups Links
>
> <*> To visit your group on the web, go to:
> � � http://groups.yahoo.com/group/AVR-Chat/
>
> <*> To unsubscribe from this group, send an email to:
> � � AVR-Chat-unsubscribe@yahoogroups.com
>
> <*> Your use of Yahoo! Groups is subject to:
> � � http://docs.yahoo.com/info/terms/
> �
>
>
>

Promethean Technologies Group Ltd and or associated and or subsidiary companies�:

The views expressed in this communication may not necessarily be the views held by Promethean Technologies Group Ltd and or associated and or subsidiary companies.

This e-mail is for the exclusive use of the addressee(s). Unauthorised disclosure, copying or distribution is prohibited.

This e-mail message has been swept for the presence of computer viruses.

Promethean Technologies Group Ltd and or associated and or subsidiary companies�accepts no liability for any loss resulting from this email transmission.



*****************************************************************
This email has been checked by the e-Sweeper Service
*****************************************************************

Re: [AVR-Chat] Which C compiler?

2005-08-12 by David Kelly

On Fri, Aug 12, 2005 at 02:53:52PM -0000, klassasin wrote:
> Right now, I'm using AVR Studio 4 (assembly) to program my AVRs.  I
> know C/C++, so I think I might try some C coding for AVRs.  It looks
> relatively easy, and it seems more and more people are using it. 
> Which C compiler (cheap/free) would you all recommend?

avr-gcc is very good. The WinAVR package makes it painless to get
running on Microsoft platforms (let me condition that with "as painless
as it gets there.")

To be used properly one can not be afraid of Makefiles altho adequate
examples are provided in avr-libc.

-- 
David Kelly N4HHE, dkelly@HiWAAY.net
========================================================================
Whom computers would destroy, they must first drive mad.

Re: Which C compiler?

2005-08-12 by brewski922

My favorite C compiler for Atmel AVRs is CodeVisionAVR. One of the 
big things I like about CV is the CodeWizard.

You can DL and checkout the evaluation version at
http://www.hpinfotech.ro/html/download.htm

To me the big draw to WinAVR is that it is free. The time spent using 
it is very costly "to me".

Mike


--- In AVR-Chat@yahoogroups.com, Thomas Keller <tkeller1@n...> wrote:
> On Fri, 2005-08-12 at 10:16 -0500, David Kelly wrote:
> [ additional text removed for brevity]
> > avr-gcc is very good. The WinAVR package makes it painless to get
> > running on Microsoft platforms (let me condition that with "as
> > painless
> > as it gets there.")
> 
>    I have a few complaints about avr-gcc, though.   One is that it
> doesn't geenrate very tight code.  Try the -S option, and take a 
look at
> the assembly source the code generator is outputting.  Not very
> efficient.
> 
>    In particular, they use r24-r25 to load every variable 
referenced,
> then transfer to values to other registers for operastions.  
Wasteful of
> time, and program memory space (which, on most AVRs, is severely
> restricted).  There is also a fiar amount of manipulation of vlaues 
that
> may well be necessary, but I have been unable to determine why, or 
gfor
> what.  In very simple programs (test cases) involving something as
> simple as adding two values together, there will be numerous rotate 
and
> shift instructions which, for the life of me, I cannot identify the
> purpose of.
> 
>    Granted, being unwilling (or, as in my case, unable to afford 
to) pay
> the price of a commercial product, one shouldn't complain too loudly
> about the free product's blemishes.
> 
>    I have been very frsutrated trying to get the emulators and such 
to
> work under linux, though.   Since my WinBlows box died, I have only 
this
> old P-II/333 with 64 MB of RAM, and I haven't been able to get 
anything
> but avr-gcc to actually work.  I have tried several of 
the "programmer"
> packages, witgh my ETT ET-JRavr, to no avail.  I also have an "AVR 
Lite"
> board that doesn't seem to work with anyof these programs.
> 
>   Speaking of the ET-JRavr, I have a small problem perhaps someone 
here
> cam assist me with:  I purchased this board on eBay, complete with
> documentation CD.  It arrived exactly as advertised (I have no 
room,,
> technical.y, for complaint).  Only one problem.  The documentation 
on
> the CD is all written in Thai!  No English options.  I have 
communicated
> with ETT in Thailand several times via email, with no respoinse (I 
have
> a sneaking suspicion no one in their home office speaks/reasds 
English).
> 
>   Further research yileded the information that an outfit named
> FutureLec also sells this board.  I have emailed them at least 1/2 
dozen
> times, also with no response.   I need English lnagueg 
documentation on
> this developmebtboard, if I am to make any use of it at all.
> 
>   It offers many amenitys, including every I/O pin being availabel 
at at
> least one header.  In has 5 8 pin DIP sockets for a real-time clock
> chip, an ADC chip, and some serial EEROMS (I assume).  Again, 
without
> data, I have no ideas what I can plug into these sockets.  I has a
> header fo an LCD display, for various forms of serial and parallel 
I/O,
> for PWM output, analog input, etc., etc.  It is amazingly 
complete.  If
> only I had some idea how to use all these features.  *sad grin*
> 
>   Can anyone on the list assist me in this?  I have this marvelous 
CD
> full of wonderful documentation in Thai (which is joyous to look 
at, so
Show quoted textHide quoted text
> cursive and festive), which is 100% useless to me.
> 
> Thanks in advance 
> 
> tom

Re: [AVR-Chat] Which C compiler?

2005-08-12 by Thomas Keller

On Fri, 2005-08-12 at 10:16 -0500, David Kelly wrote:
[ additional text removed for brevity]
> avr-gcc is very good. The WinAVR package makes it painless to get
> running on Microsoft platforms (let me condition that with "as
> painless
> as it gets there.")

   I have a few complaints about avr-gcc, though.   One is that it
doesn't geenrate very tight code.  Try the -S option, and take a look at
the assembly source the code generator is outputting.  Not very
efficient.

   In particular, they use r24-r25 to load every variable referenced,
then transfer to values to other registers for operastions.  Wasteful of
time, and program memory space (which, on most AVRs, is severely
restricted).  There is also a fiar amount of manipulation of vlaues that
may well be necessary, but I have been unable to determine why, or gfor
what.  In very simple programs (test cases) involving something as
simple as adding two values together, there will be numerous rotate and
shift instructions which, for the life of me, I cannot identify the
purpose of.

   Granted, being unwilling (or, as in my case, unable to afford to) pay
the price of a commercial product, one shouldn't complain too loudly
about the free product's blemishes.

   I have been very frsutrated trying to get the emulators and such to
work under linux, though.   Since my WinBlows box died, I have only this
old P-II/333 with 64 MB of RAM, and I haven't been able to get anything
but avr-gcc to actually work.  I have tried several of the "programmer"
packages, witgh my ETT ET-JRavr, to no avail.  I also have an "AVR Lite"
board that doesn't seem to work with anyof these programs.

  Speaking of the ET-JRavr, I have a small problem perhaps someone here
cam assist me with:  I purchased this board on eBay, complete with
documentation CD.  It arrived exactly as advertised (I have no room,,
technical.y, for complaint).  Only one problem.  The documentation on
the CD is all written in Thai!  No English options.  I have communicated
with ETT in Thailand several times via email, with no respoinse (I have
a sneaking suspicion no one in their home office speaks/reasds English).

  Further research yileded the information that an outfit named
FutureLec also sells this board.  I have emailed them at least 1/2 dozen
times, also with no response.   I need English lnagueg documentation on
this developmebtboard, if I am to make any use of it at all.

  It offers many amenitys, including every I/O pin being availabel at at
least one header.  In has 5 8 pin DIP sockets for a real-time clock
chip, an ADC chip, and some serial EEROMS (I assume).  Again, without
data, I have no ideas what I can plug into these sockets.  I has a
header fo an LCD display, for various forms of serial and parallel I/O,
for PWM output, analog input, etc., etc.  It is amazingly complete.  If
only I had some idea how to use all these features.  *sad grin*

  Can anyone on the list assist me in this?  I have this marvelous CD
full of wonderful documentation in Thai (which is joyous to look at, so
cursive and festive), which is 100% useless to me.

Thanks in advance 

tom

ATMega Disassembler?

2005-08-12 by Mark Jordan

Is there some free disassembler for the ATMEGA family?

	Thanks.
	Mark

Re: [AVR-Chat] ATMega Disassembler?

2005-08-12 by Jeffrey Engel

--- Mark Jordan <mark@cpovo.net> wrote:

> 
> Is there some free disassembler for the ATMEGA
> family?
> 
> 	Thanks.
> 	Mark

You can load the .hex file into AVR Studio and it will
display the disassembly.

Jeff Engel
Arlington, TX


Happiness is - positive intake manifold pressure.


		
____________________________________________________
Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs

Re: [AVR-Chat] Re: Which C compiler?

2005-08-12 by David Kelly

On Fri, Aug 12, 2005 at 06:22:39PM -0000, brewski922 wrote:
> My favorite C compiler for Atmel AVRs is CodeVisionAVR. One of the 
> big things I like about CV is the CodeWizard.

One of the things I DON'T like about any embedded development system is
hidden magical wizards and libraries. While it could make things easier,
too often it only makes things harder.

For example I posted earlier this week here or elsewhere my ee_writes()
routine. Originally wrote my own without thinking to look in avr-libc. I
desired control over variable usage and IRQ. Later looked in avr-libc
and found that routine would have been acceptable but mine was in C and
only 2 oe 4 bytes larger. Mine stayed.

I feel the same way about printf() and malloc(). As a general rule they
have no place in the projects I undertake.

Will shortly be importing an 802.15.4 MAC layer in a project. Suspect
many of my biases will have to be thrown out the window to accommodate
that mass of foreign code. Will be P.O.'ed if I find printf() in it.

-- 
David Kelly N4HHE, dkelly@HiWAAY.net
========================================================================
Whom computers would destroy, they must first drive mad.

Re: [AVR-Chat] ATMega Disassembler?

2005-08-12 by David Kelly

On Fri, Aug 12, 2005 at 04:31:57PM -0300, Mark Jordan wrote:
> 
> 	Is there some free disassembler for the ATMEGA family?
> 
> 	Thanks.
> 	Mark

This thread was discussing selection of C compilers. Why did you reply
to that thread and edit the subject? Why didn't you open a new message?

So I won't tell you that "avr-objdump -DS" (comes in WinAVR and other
sources) disassembles and leaves original source code as comments. I use
this suffix rule in my Makefile and always generate a .list file as a
matter of course when building my project:

.elf.list:
	avr-objdump -DS $< > $@

The options above are a bit nasty as they attempt to disassemble the
data sections as well.

-- 
David Kelly N4HHE, dkelly@HiWAAY.net
========================================================================
Whom computers would destroy, they must first drive mad.

Re: [AVR-Chat] ATMega Disassembler?

2005-08-12 by Mark Jordan

Thanks, it worked.
	Mark
Show quoted textHide quoted text
On 12 Aug 2005 at 12:45, Jeffrey Engel wrote:

> --- Mark Jordan <mark@cpovo.net> wrote:
> 
> > 
> > Is there some free disassembler for the ATMEGA
> > family?
> > 
> > 	Thanks.
> > 	Mark
> 
> You can load the .hex file into AVR Studio and it will
> display the disassembly.
> 
> Jeff Engel
> Arlington, TX
> 
> 
> Happiness is - positive intake manifold pressure.
> 
> 
> 
> ____________________________________________________
> Start your day with Yahoo! - make it your home page 
> http://www.yahoo.com/r/hs 
> 
> 
> 
> 
> 
> Yahoo! Groups Links
> 
> 
> 
> 
> 
> 
> 
>

Re: [AVR-Chat] Which C compiler?

2005-08-12 by John Samperi

At 03:15 AM 13/08/2005, you wrote:
>Can anyone on the list assist me in this?  I have this marvelous CD
>full of wonderful documentation in Thai (which is joyous to look at, so
>cursive and festive), which is 100% useless to me.

If you know C then a few lessons in Thai may just do the trick...
they are pretty much similar to me :-)


Regards

John Samperi

******************************************************
                         Ampertronics Pty. Ltd.
   11 Brokenwood Place Baulkham Hills, NSW 2153 AUSTRALIA
          Tel. (02) 9674-6495       Fax (02) 9674-8745
                Email: samperi@ampertronics.com.au
                  Website  http://www.ampertronics.com.au
* Electronic Design   * Custom Products   * Contract Assembly
******************************************************

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.