Studio 7.0.1417 can't find device in io.h

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

I just installed the latest Studio (1417).  Can't compile.  The preprocessor seems to find the io.h file but the io.h file can't find the device. 

 

The device I specify in the Build > Device is there but it appears the device doesn't get passed to the preprocessor.

 

I noticed something in the Build > toolchain that doesn't exist in my Studio 6.2.  The field is blank.  Could this be the problem?

 

Here is the device being set:

 

 

Here is the empty field:

 

 

 

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

steve17 wrote:
I just installed the latest Studio (1417).  Can't compile.  The preprocessor seems to find the io.h file but the io.h file can't find the device. 

Complete build output?

steve17 wrote:
Device is [set in the project properties] but it appears the device doesn't get passed to the preprocessor.

The build system should pass a -mmcu option to the compiler with the actual device name as its value. (Check this looking at the complete build output.) It should result in a preprocessor symbol being defined. You can test it in your main.c, with something like this at the very beginning:

#ifndef defined (__AVR_ATxmega256A3BU__)
#warning "MCU model not defined!"
#endif

 

Have you tried simply "wiggling" the device model in the project settings? (Change to something else, then change back.)

 

Is it the  same when you set up a new empty project with the same device?

Happy 75th anniversary to one of the best movies ever made! Rick Blane [Bogart]: "Of all the gin joints, in all the towns, in all the world, she walks into mine."

 

"Some questions have no answers."[C Baird] "There comes a point where the spoon-feeding has to stop and the independent thinking has to start." [C Lawson] "There are always ways to disagree, without being disagreeable."[E Weddington] "Words represent concepts. Use the wrong words, communicate the wrong concept." [J Morin] "Persistence only goes so far if you set yourself up for failure." [Kartman]

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

Thanks Johan.  Yes, the problem is the lack of the -mmcu option.  Why does this keep happening to me?   It happened a year ago with an earlier version of Studio 7.0.  Now I remember I have to put -mmcu in 3 places.  Compiler, linker, and assembler.

 

Could it be because I  use the offline installer?  The on-line installer is always recommended.  Why is that?

 

I prefer offline installs because I often install stuff on several OS installations on a couple of computers.  I'm testing this thing now on a Win10 installation I use for testing on my secondary computer.

 

I'm still running Studio 6.2 on my main computer because 7.0 had a bug with links and folders.  Maybe it's fixed in this version.  Hope springs eternal.

 

P.S.  Changing the device didn't help.  I feed Studio with a 6.2 project which it upgrades.  I haven't tried a new project.  Studio should come with a warning:  THIS SOFTWARE CAN BE HAZARDOUS TO YOUR HEALTH.

Last Edited: Sun. Aug 13, 2017 - 12:12 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Okay, it looks like the bug in earlier versions of 7.0 has been fixed.  It was worth the torment.  I was doubtful because I saw no mention of this fix in the version release notes.