Udating AVR-GCC

Go To Last Post
24 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

- hope this is the right place for this question --- please move if not.

 

How can I update my avr-gcc?  I have an older version that I use in a DOS box. It works OK, but I've read discussions here about 8.1.

 

From what I can remember when I found this one, the 'installer' just made a folder called avrtoolchain and put everything in there. I didn't bother changing the path because what I do isn't that complicated. This leads me to believe that I could possibly just copy a newer version to the existing location. What I don't know is where I can get it and if there are other files needed as well.

 

Thanks,

 

hj

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'd keep both (so you can rollback). Just use PATH to determine which one is used.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ford2go wrote:
I have an older version that I use in a DOS box. It works OK, but I've read discussions here about 8.1.

...

What I don't know is where I can get it and ...

hopefully

AVR-GCC 8.2.0 for Windows 32 and 64 bit

by 

http://blog.zakkemble.co.uk/avr-gcc-builds/

...

[mid-page, View History button]

History

2018-09-06
CURRENT RELEASE
AVR-GCC updated to 8.2.0
Binutils updated to 2.31.1

 

...

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

gchapman wrote:

AVR-GCC 8.2.0 for Windows 32 and 64 bit

by 

http://blog.zakkemble.co.uk/avr-gcc-builds/

...

[mid-page, View History button]

History

2018-09-06
CURRENT RELEASE
AVR-GCC updated to 8.2.0
Binutils updated to 2.31.1

...

 

The <avr/ioXXX.h> files don't appear to be up-to-date on these.  Missing iom168pb.h, for

example, which is in the latest Arduino release.  <avr/iom328pb.h> isn't in these releases

or Arduino either, and the gcc source tree doesn't appear to have any of these files at all.

 

I have noticed a few errors but before reporting them I'd like to see whether they've already

been fixed.  Is there an official location for obtaining the chip include files?  Also, who would

be the contact for receiving bug reports?

 

Thanks,

 

--Mike

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

On my linux box I just type "apt get update" / "apt get upgrade" to get never versions of most installed programs, and gcc-avr and avr-libc are among those.

(I realize the're not the latest / greatest versions, but these are good enough for me).

 

If you want the latest / greatest versions then use a web browser and go to the Microchip site.

From what I've read on this forum Microchip is apparently maintaining a gcc version for AVR and it is downloadable from their site.

Apart from avrgcc itself you will also need the version of libc that fits with your compiler version, but this might be a single download from Microchip.

16:42 The links from the page on "16:36" seems to have all the tools (for different OS-es) combined in a single download.

 

And while you're at it, support programs such as avr-size avr-objcopy make are probably also part of the (windows?) download.

Just curios what windoze users have to go through:

16:17 Browser is already running..

16:18 Microchip site.

16:19 Found some release notes: http://ww1.microchip.com/downloads/en/DeviceDoc/avr8-gnu-toolchain-3.6.1.1752-readme.pdf

16:21 "Development environment" for a random AVR processor gives links to commercial stuff (development kits etc) https://www.microchip.com/wwwproducts/en/ATTINY814

16:24 Search for "avrgcc" does not get many nor usefull hits. https://www.microchip.com/sitesearch/search/All/avrgcc

16:26 In the document from 16:19 A download link on page 3 (to www.atmel.com) gets redirected to the main page from microchip. Dead end.

16:28 http://www.microchip.com/sitesearch/search/All/gnu%20goolchain%20avr seems to get results for some avr32 only.

16:31 cc 4.9 (revision 221220) is mentioned in the release notes pdf fro Atmel Studio 7.

16:34 Search for "compiler" gets me som MPlab-XC https://www.microchip.com/sitesearch/search/All/compiler?&mns=compiler&mnc=All

16:36 Search for "compiler avr" finally seems to lead to the right page with download links for the toolchains: https://www.microchip.com/mplab/avr-support/avr-and-arm-toolchains-(c-compilers)

 

So that's 20 minutes of searching for what is a single line typed in a terminal for me.

1/4 of that is maybe for writing down the steps I followed, and it could be faster still if I had more experience on the Microship site.

And then there is the trust issue.

I implicitly trust any software I install via apt.

Software downloaded from the microchip site is probably also trustworthy if it's via https etc...

Would you trust some software downloaded from some blog of zakkemble? (Mentioned in #3) ?

 

16:48 Have Fun.

Doing magic with a USD 7 Logic Analyser: https://www.avrfreaks.net/comment/2421756#comment-2421756

Bunch of old projects with AVR's: http://www.hoevendesign.com

Last Edited: Sun. Sep 9, 2018 - 02:51 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

avr-mike wrote:
Is there an official location for obtaining the chip include files?
Yes

Atmel Studio

  • [what's the directory?]
  • Microchip Packs Repository, an atpack file is a zip file

MPLAB X 5.05 and sub

  • <MPLAB X IDE install directory>\v5.xx\packs

avr-mike wrote:
Also, who would be the contact for receiving bug reports?
One in the GCC team in the Free Software Foundation.

https://gcc.gnu.org/bugs/

 


Microchip Packs Repository

Atmel Packs

http://packs.download.atmel.com/

http://www.microchip.com/mplab/mplab-x-ide

in 'Readme for MPLAB X IDE.htm' :

...

 

11 What's New in v5.05

REMINDER : New Project format – The new project format in v5.00 and greater supports packs which contain versioned device information. Packs can be found under <MPLAB X IDE install directory>\v5.xx\packs. 

...

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

avr-mike wrote:
<avr/iom328pb.h> isn't in these releases or Arduino either, ...
IIRC, Arduino doesn't have any mega328PB boards though third parties do.

https://www.avrfreaks.net/forum/pb-megaavr-announced#comment-2267091

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Paulvdh wrote:
Would you trust some software downloaded from some blog of zakkemble? (Mentioned in #3) ?
Some of the ways around that issue are

  • App-V in Windows 8.1 Enterprise, Windows Server 2012 R2, and subsequent of both
  • containers in Windows 10 (Pro and sub) and Windows Server 2016

 

https://docs.microsoft.com/en-us/windows/application-management/app-v/appv-getting-started

https://docs.microsoft.com/en-us/virtualization/windowscontainers/about/

https://blogs.msdn.microsoft.com/webdev/2017/09/07/getting-started-with-windows-containers/

Mouser Electronics

Bench Talk

Containers: Similar To Virtual Machines For Embedded

by Lynnette Reese

August 4, 2017

https://www.mouser.com/blog/containers-similar-to-virtual-machines-for-embedded-development

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Vagrant is one multi-platform way.

https://www.vagrantup.com/

https://app.vagrantup.com/boxes/search

('Provider' below the search box, 'more' pull-down menu : Docker, Hyper-V, ...

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

avr-mike wrote:

gchapman wrote:

AVR-GCC 8.2.0 for Windows 32 and 64 bit

by 

http://blog.zakkemble.co.uk/avr-gcc-builds/

...

[mid-page, View History button]

History

2018-09-06
CURRENT RELEASE
AVR-GCC updated to 8.2.0
Binutils updated to 2.31.1

...

 

The <avr/ioXXX.h> files don't appear to be up-to-date on these.  Missing iom168pb.h, for

example, which is in the latest Arduino release.  <avr/iom328pb.h> isn't in these releases

or Arduino either, and the gcc source tree doesn't appear to have any of these files at all.

 

I have noticed a few errors but before reporting them I'd like to see whether they've already

been fixed.  Is there an official location for obtaining the chip include files?  Also, who would

be the contact for receiving bug reports?

 

Thanks,

 

--Mike

 

But surely this is a v8 from the FSF mainline not the Atmelchip private branch so it always lags device support by a year or two. That's the whole thinking behind DFPs 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There is another source of recent versions: https://sourceforge.net/projects...

 

The chip support is more up to date, but not the compiler itself. I have kind of made a hybrid of the two plus Atmel (I mean Microchip) official stuff to get support for the xtinies.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

For anyone else trying to find the latest include files, here's a procedure:

 

  • download the pack files from http://packs.download.atmel.com
  • add a .zip extension to the filenames (which end in .atpack)
  • put the .zip in an empty directory because it unzips in place
  • use unzip filename on Mac or whatever your system requires
  • files are in ./include/avr

 

This thread was helpful (I don't know how to link to it) --> "Atmel Part Description Files"

 

The errors I had noticed in the PB parts (ACSRB is at 0x2F, not 0x0F) have

already been corrected.

 

--Mike

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

avr-mike wrote:
This thread was helpful (I don't know how to link to it) --> "Atmel Part Description Files"
https://www.avrfreaks.net/forum/atmel-part-description-files

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I wrote some instructions for installing the device update "packs" in a normal cli avr "toolchain" here: https://www.avrfreaks.net/commen...

 

Given the general lack of interest in AVR 8bit micros within the general gcc community, it's not at all clear to me that using a version of gcc newer than the Atmel-distributed versions is a good idea...

 

Atmel "toolchain" installs: https://www.microchip.com/mplab/avr-support/avr-and-arm-toolchains-(c-compilers)

Atmel "packs" repository:  http://packs.download.atmel.com/

 

Last Edited: Mon. Sep 10, 2018 - 02:16 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks for the link to your instructions.

 

My "IDE" has always been vim + grep + less, and for AVR I occasionally have to

press either the Compile checkmark or Upload arrow on the Arduino software.

Adding chips to Arduino is possible but a pain so I might invest some effort in

going completely cli....

 

--Mike

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

westfw wrote:
Atmel "toolchain" installs: https://www.microchip.com/mplab/...(c-compilers)
404 (IIRC, was a tiny104 Xplained Nano, now a PIC18F46K42 Xpress)

https://www.microchip.com/mplab/avr-support/avr-and-arm-toolchains-(c-compilers)

 

Edit: 404's offer

 

"Dare to be naïve." - Buckminster Fuller

Last Edited: Mon. Sep 10, 2018 - 01:39 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

El Tangas wrote:
I have kind of made a hybrid of the two plus Atmel (I mean Microchip) official stuff to get support for the xtinies.
That will be mix of at least two licences :

  • FSF - GPLv3 with GCC runtime library exception
  • Microchip - Apache v2

That's usually not a issue other than some customers balk at any GPL.

If GPL is a no-go then a few of the several (many?) options are :

  • GCC maintenance (dual license)
  • Microchip (xc8-gcc)

 

https://github.com/gcc-mirror/gcc

https://www.embecosm.com/ due to https://www.avrfreaks.net/forum/ok-use-mmcuattiny84-instead-84a#comment-1151476

https://www.avrfreaks.net/forum/come-join-us-mplab-now-supports-avrs?page=2#comment-2504476

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

404

Grr.  Fixed.  It's hard to tell which URLs will be treated as URLs automatically, and which need to be wrapped up with the "link" button.  I guess the automatic stuff doesn't like punctuation like "()"

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Grr.  Fixed.  It's hard to tell which URLs will be treated as URLs automatically, and which need to be wrapped up with the "link" button.  I guess the automatic stuff doesn't like punctuation like "()"

I >>NEVER<< trust automatic links.

 

Unless I'm on my mobile and am too lazy to enable the desktop interface :)

"Experience is what enables you to recognise a mistake the second time you make it."

"Good judgement comes from experience.  Experience comes from bad judgement."

"Wisdom is always wont to arrive late, and to be a little approximate on first possession."

"When you hear hoofbeats, think horses, not unicorns."

"Fast.  Cheap.  Good.  Pick two."

"We see a lot of arses on handlebars around here." - [J Ekdahl]

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

gchapman wrote:
That will be mix of at least two licences :

  • FSF - GPLv3 with GCC runtime library exception
  • Microchip - Apache v2

 

Yeah, there are more licences, the header files use a version of the BSD licence, as does the rest of avr-libc.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Paulvdh wrote:
Would you trust some software downloaded from some blog of zakkemble? (Mentioned in #3) ?
Zak's website is not secure.

It's much easier now to obtain the certificate then enable TLS.

NuGet has signed packages; apparently likewise for Paket.

Chocolatey is curated but would take Zak awhile to be able to post trusted packages.

Microchip 3.5.4 AVR GCC is in NuGet.

 

http://blog.zakkemble.co.uk/avr-gcc-builds/

Let's Encrypt - Free SSL/TLS Certificates

https://letsencrypt.org/

https://docs.microsoft.com/en-us/nuget/reference/signed-packages-reference

https://fsprojects.github.io/Paket/credential-providers.html

https://chocolatey.org/faq#what-is-a-trusted-package

https://www.nuget.org/packages?q=avr

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks -- I just scanned this and it looks as if it will take a while to check it all out, but I'll get there.

 

Appreciate all of the responses,

 

hj

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

AVR-GCC 8.2.0 for Windows 32 and 64 bit – Zak's Electronics Blog ~*

(1/4 page, View History button)

2019-05-19
CURRENT RELEASE
AVR-GCC updated to 9.1.0

...

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'd also consider SprinterSB's builds from here .. Even though not bleeding edge

https://sourceforge.net/projects...

 

/Bingo

Last Edited: Tue. May 21, 2019 - 05:51 PM