 |
| Author |
Message |
|
|
Posted: Apr 30, 2012 - 06:46 PM |
|

Joined: Apr 09, 2012
Posts: 27
|
|
| where can I find a detailed reference of how to write C for AVR GCC? I read that AVR GCC is ported GCC and I'm trying to learn how to port code from codevision. I have found the codevision manual, but can't seem to find an AVR GCC equivalent (except the normal GCC manual)... |
|
|
| |
|
|
|
|
|
Posted: Apr 30, 2012 - 07:09 PM |
|

Joined: Nov 17, 2004
Posts: 13840
Location: Vancouver, BC
|
|
Look for the avr-libc manual.
The main differences are ISR declarations, the "PORTC.x" construct, and the handling of flash/eeprom variables. |
_________________ Regards,
Steve A.
The Board helps those that help themselves.
|
| |
|
|
|
|
|
Posted: Apr 30, 2012 - 07:32 PM |
|

Joined: Feb 12, 2005
Posts: 16314
Location: Wormshill, England
|
|
I just run a sed script to convert between CodeVision and avr-gcc. However you always need to do some hand-editing.
You write C for avr-gcc in conjunction with the avr-gcc manual.
You write C for CodeVision in conjunction with the CodeVision manual.
When you installed avr-gcc you also installed the documentation. You can always Google an online version.
No, the avr-gcc docs are not as well organised as the CV docs. But hey-ho, it is free.
David. |
|
|
| |
|
|
|
|
|
Posted: Apr 30, 2012 - 07:35 PM |
|


Joined: Jul 18, 2005
Posts: 62314
Location: (using avr-gcc in) Finchingfield, Essex, England
|
|
|
Quote:
No, the avr-gcc docs are not as well organised as the CV docs. But hey-ho, it is free.
And it's within the remit of anyone who cares to modify them into a "better" form. That's the nature of collaboratively developed software. |
_________________
|
| |
|
|
|
|
|
|
|