Menu

#25 no MCU-Type

open
nobody
5
2019-10-17
2012-06-07
Curryman
No

I worked in the past with Helios and AVR Plugin for Eclipse 2.3.4 without big problems so far.

Now I decided to change to AVR Plugin 2.4.0 the latest tool chain from ATMEL and Indigo.
I started from scratch and loaded the last Eclipse Indigo Version (win32). I installed it and started with an empty workspace. Then I performed a update check to ensure Eclipse is on the latest version.
Then I loaded avreclipse.2.4.0.final.p2repository.zip unzipped it and stored it on the HDD.
After that I loaded the current ATMEL Tool chain and installed it.

Then I installed the AVR Plugin to Eclipse (Help/Install new Software).
That process worked fine so far.
After installing I restarted Eclipse as recommended.

Now I can see the typical buttons and so on are available and things are looking fine.
Under Window/Preferences/AVR/Paths I keyed in the path to th AVR Toolchain.

AVR-GCC ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
GNU make ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
AVR Header Files ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\avr\include
AVRDude ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
Atmel Part Description Files are not available and so far I know not necessary.

Finally I disabled search for system path at startup and click the button Apply

To be sure everything is correct I restarted Eclipse.

When I now start to create a new C project (File/New/C Project)
For Project name I key in "Test"

Project type:
AVR Cross Target Application
Empty Project

Toolchains:
AVR-GCC Toolchain

Click Button Next
I unselected Debug

Click Button Next

I see the dialogue AVR Target Hardware Properties

Here is the MCU Type: empty and the MCU Frequency (Hz): is 1000000

When I click to the MCU Type nothing is to select.

Related

Support Requests: #25

Discussion

1 2 > >> (Page 1 of 2)
  • Anonymous

    Anonymous - 2012-07-14

    Use programmer and Load from MCU. This is the easiest way.

     

    Last edit: Anonymous 2014-09-14
    • semulum

      semulum - 2014-02-20

      see my full post elsewhere

       

      Last edit: semulum 2014-02-20
  • Thomas Holland

    Thomas Holland - 2012-07-14

    Hi, I think the reason for the missing MCU type lies with the toolchain.
    Some Toolchains by Atmel do not report the supported MCUs when queried with "avr-gcc --target-help".
    Until I get around to find a different way of extracting the known MCUs from the Atmel avr-gcc I have to refer you to a different toolchain, e.g. the old WinAVR toolchain (https://sourceforge.net/projects/winavr/files/) or the really current MHV Toolchain (http://www.makehackvoid.com/project/mhvavrtools) which IIRC requires manual setting of the paths but works great otherwise.

    Cheers,

    Thomas

     
  • Markus Baertschi

    I have the same problem on Linux (Ubuntu). Is there a workaround, like manually provide a list of MCU types ?

    The problem is that the older toolchains do not support the more recent MCUs, like my xmega32A4U.

    Also, in the past I found that listbox a real pain to use, there are just too many MCU types now for it to be practical, I would prefer a simple textfield.

     
  • Markus Baertschi

    One more question. At what moment does the plugin run the 'avr-gcc --target-help' command ?

    I've replaced avr-gcc with a shell script to intercept the --target-help parameter and supply an answer. On the command-line this works, but the plugin does not seem to run the command anymore.

     
  • Thomas Holland

    Thomas Holland - 2012-07-23

    Sorry, but there is currently no easy workaround for this issue. While I would like to fix this issue I basically have no time for working on the plugin anymore.

    A little untested hack that you might want to try is to manually edit the AVR Plugin preferences. They are stored in the .settings Folder of your project, named de.innot.avreclipse.core.prefs and editing should be self explanatory. Just make sure that Eclipse is not running while editing this file.
    If it does not already contain the following lines you can try to just add them

    avrtarget/ClockFrequency=16000000
    avrtarget/MCUType=atmega328p <- change to the MCU id as used by GCC
    avrtarget/perConfig=false
    eclipse.preferences.version=1

    No guaranties that this works but worth a try.

     
    • John Warren

      John Warren - 2013-04-26

      Why can't you just get rid of the drop down selection and let us just enter the MCU type into the field. Simple and I but it's a 5 minute fix.

      Why make this any harder that it should be. This way you don't have to figure out some fancy workaround.

       
  • Thomas Holland

    Thomas Holland - 2012-07-23

    As to your second question -- I just checked with the debugger: "avr.gcc --target-help" is called whenever the list is required for the first time, either on startup when the "AVR Supported MCUs" View is open or when the Project Properties -> AVR -> Target Hardware page is opened.
    Unless the path to the compiler is changed avr-gcc will only be called once and the results are cached.
    BTW if someone wants to fix this bug: the relevant code is located in the file de/innot/avreclipse/core/toolinfo/GCC.java in the method loadMCUList()

     
    • Markus Baertschi

      Was away for a week, so a bit late. Is there a way of forcing the plugin to re-read this ?
      How do I invalidate the cache ?

      At the moment it looks to me like I must re-install Eclipse to re-executa the gcc command. Any better way ?

       
    • Vasi

      Vasi - 2013-05-02

      Hi Thomas,
      The last version of ATMEL avr8 toolchain (for linux at least) is based on avr-gcc 4.7.2 and accepts the option "--target-help". The problem is that the returned list it have a two space characters before "Known MCU names:" string, as " Known MCU names:" and that is the only change which must be made to the parser of the result from console. It will work for both variants of avr-gcc, ATMEL and GNU. Specifically, this line modified as it follows:

              if ("  Known MCU names:".equals(line)) {
      

      See the two spaces introduced inside string.


      EDIT: Just tested and indeed that is the only modification needed. It works perfectly well with avr8-gnu-toolchain-3.4.2.939-linux.any.x86.tar.gz downloaded from ATMEL site! Hopefully, you will read this and will make a little effort to make the change and publish the archive for all who can not do for themselves (I was able to generate the jar file only for the core, as the entire project can't be generated due to some errors).

       

      Last edit: Vasi 2013-05-02
      • Vasi

        Vasi - 2013-05-02

        Still, a good idea is to strip all the space characters from the beginning of every new line (I don;t know java, so I don't know if there is a special function for that).

         
        • xtal

          xtal - 2013-05-25

          The String class in Java provides the trim() method, which removes whitespaces at the start and end of a string.

           
        • xtal

          xtal - 2013-05-25

          I've been struggling with the same issue. Would you be so kind to provide the corrected .jar files? I'm not a plugin specialist in any way so if you could do that I'de appreciate a lot!

           
      • xtal

        xtal - 2013-05-25
         

        Last edit: xtal 2013-05-25
    • Ivica Safranko

      Ivica Safranko - 2014-11-22

      Hallo Thomas,

      the trim() function resolves that bug, my patch attached.

       
  • michaelb

    michaelb - 2012-07-28

    The same is true here.
    Adding the MCUType manually to the prefs works for me. Add least gcc is supplied with the correct options and the generated code and hex works as expected.

    Bug #59 mentions the correct options for gcc. But unfortunatly also the output format of the device list has changed from older gcc versions.

    Using avr-gcc supplied with Atmel Studio 6:

    >avr-gcc --version
    avr-gcc (AVR_8_bit_GNU_Toolchain_3.4.0_663) 4.6.2
    Copyright (C) 2011 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    >avr-gcc --target-help -mlist-devices
    
    [...]
      -mtiny-stack                Change only the low 8 bits of the stack pointer
    
    List of parts supported by avr-gcc:
    at90s2313           __AVR_AT90S2313__
    at90s2323           __AVR_AT90S2323__
    at90s2333           __AVR_AT90S2333__
    at90s2343           __AVR_AT90S2343__
    attiny22            __AVR_ATtiny22__
    attiny26            __AVR_ATtiny26__
    at90s4414           __AVR_AT90S4414__
    [...]
    attiny11            __AVR_ATtiny11__
    attiny12            __AVR_ATtiny12__
    attiny15            __AVR_ATtiny15__
    
    Assembler options
    =================
    [...]
    

    I would have changed GCC.java to make it work, but I'm not able to build the plugin, with Eclipse Indigo Pluginbuilder does not work either, at least not for me :-(

     
  • Veronica

    Veronica - 2012-08-01

    Try:
    avr-gcc "-Wa,--mlist-devices", "--target-help" >C:/mcuList.txt
    and check created file mcuList.txt in your C:/ directory
    You can read how to edit and build the plugin on Polish site http://forum.atnel.pl/topic1275.html#p9923
    or just copy a part of AVR Eclipse Plugin (de.innot.avreclipse.core_2.4.0.201203041437.jar) to your Eclipse/plugins directory and replace the original.
    That file you can find here
    From now on you can select MCU Type.

     

    Last edit: Veronica 2012-09-10
  • Joseph Ma

    Joseph Ma - 2012-08-19

    Hi
    I'm using Indigo win32 and Toolchain 3.4.0.1146.
    I copied that file to Eclipse/plugins and run Eclipse.
    but when i tried to select MCU type from Target Hardware i saw the MCU Type menu disappeared.
    i took a screen shot and attached.
    thanks for help.

     

    Last edit: Joseph Ma 2012-08-19
  • Veronica

    Veronica - 2012-08-20

    Hello Joseph,
    1. Delete Eclipse folder
    2. Remove all previous Java 2 Runtime Environment from the system
    3. Install new Java ( Version 7 Update 5 ) win32
    4. Unpack Eclipse Indigo
    5. Start Eclipse and choose new workspace
    6. Install AVR Eclipse Plugin
    7. Change paths to your toolchain and close Eclipse
    8. Replace the file de.innot.avreclipse.core_2.4.0.201203041437.jar (eclipse/plugins directory)
    9. Start Eclipse and create new project
    I hope it will help you

     

    Last edit: Veronica 2012-08-20
  • John Warren

    John Warren - 2013-04-26

    Why cannot someone fix this bug?

     
  • rg77

    rg77 - 2013-05-07

    Hi,
    I know how tough it is to find spare time for open source.
    But if every user that want's to switch away from the Arduino IDE needs to fix this himself, they simply won't. Many of them don't know how.
    I decided to give up after 1 hour trying. Sad, since I love using eclipse e.g. for Java, Python, ... dev.
    Regards

     
  • Vasi

    Vasi - 2013-05-25

    didn't knew I can post here directly from my email... so this post become redundant.

     

    Last edit: Vasi 2013-05-25
  • xtal

    xtal - 2013-05-25

    I have version 2.4.0 of the plug in and replaced the file but it still doesn't work. Maybe it is necessary to replace another .jar file?

    Thanks Vasi!

     
  • Vasi

    Vasi - 2013-05-25

    No problem, here is the address
    https://sites.google.com/site/funlw65/file-archive/de.innot.avreclipse.core_2.4.0.201203041437.jar?attredirects=0&d=1

    Also, if you can use google to translate from Romanian, here is another
    page that may be useful somehow
    http://myshed.wordpress.com/acasa/evb-4-3-v4-board/programarea-placii-in-c/

    On Sat, May 25, 2013 at 8:32 PM, xtal xtalxtal@users.sf.net wrote:

    I've been struggling with the same issue. Would you be so kind to provide
    the corrected .jar files? I'm not a plugin specialist in any way so if you
    could do that I'de appreciate a lot!


    [support-requests:#25] no MCU-Type

    Status: open
    Labels: Install Problem (example)
    Created: Thu Jun 07, 2012 12:37 PM UTC by Curryman
    Last Updated: Tue May 07, 2013 08:50 AM UTC
    Owner: nobody

    I worked in the past with Helios and AVR Plugin for Eclipse 2.3.4 without
    big problems so far.

    Now I decided to change to AVR Plugin 2.4.0 the latest tool chain from
    ATMEL and Indigo.
    I started from scratch and loaded the last Eclipse Indigo Version (win32).
    I installed it and started with an empty workspace. Then I performed a
    update check to ensure Eclipse is on the latest version.
    Then I loaded avreclipse.2.4.0.final.p2repository.zip unzipped it and
    stored it on the HDD.
    After that I loaded the current ATMEL Tool chain and installed it.

    Then I installed the AVR Plugin to Eclipse (Help/Install new Software).
    That process worked fine so far.
    After installing I restarted Eclipse as recommended.

    Now I can see the typical buttons and so on are available and things are
    looking fine.
    Under Window/Preferences/AVR/Paths I keyed in the path to th AVR Toolchain.

    AVR-GCC ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
    GNU make ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
    AVR Header Files ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR
    Toolchain\avr\include
    AVRDude ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
    Atmel Part Description Files are not available and so far I know not
    necessary.

    Finally I disabled search for system path at startup and click the button
    Apply

    To be sure everything is correct I restarted Eclipse.

    When I now start to create a new C project (File/New/C Project)
    For Project name I key in "Test"

    Project type:
    AVR Cross Target Application
    Empty Project

    Toolchains:
    AVR-GCC Toolchain

    Click Button Next
    I unselected Debug

    Click Button Next

    I see the dialogue AVR Target Hardware Properties

    Here is the MCU Type: empty and the MCU Frequency (Hz): is 1000000

    When I click to the MCU Type nothing is to select.


    Sent from sourceforge.net because you indicated interest in <
    https://sourceforge.net/p/avr-eclipse/support-requests/25/>

    To unsubscribe from further messages, please visit <
    https://sourceforge.net/auth/subscriptions/>

    --
    Vasi

     

    Related

    Support Requests: #25

  • Vasi

    Vasi - 2013-05-25

    No, it should work as it works for me and tested it under Linuxmint Debian
    Testing, openSUSE 12.3, and currently under Vista and Fedora18. It is
    reported to work also for others - a friend of mine followed step by step
    the tutorial from here:
    http://myshed.wordpress.com/acasa/evb-4-3-v4-board/programarea-placii-in-c/

    Don't know your issue but you must restart Eclipse after that .jar
    replacement. Of course, you need to provide the
    correct paths.

    On Sat, May 25, 2013 at 9:28 PM, xtal xtalxtal@users.sf.net wrote:

    I have version 2.4.0 of the plug in and replaced the file but it still
    doesn't work. Maybe it is necessary to replace another .jar file?

    Thanks Vasi!


    [support-requests:#25] no MCU-Type

    Status: open
    Labels: Install Problem (example)
    Created: Thu Jun 07, 2012 12:37 PM UTC by Curryman
    Last Updated: Sat May 25, 2013 05:55 PM UTC
    Owner: nobody

    I worked in the past with Helios and AVR Plugin for Eclipse 2.3.4 without
    big problems so far.

    Now I decided to change to AVR Plugin 2.4.0 the latest tool chain from
    ATMEL and Indigo.
    I started from scratch and loaded the last Eclipse Indigo Version (win32).
    I installed it and started with an empty workspace. Then I performed a
    update check to ensure Eclipse is on the latest version.
    Then I loaded avreclipse.2.4.0.final.p2repository.zip unzipped it and
    stored it on the HDD.
    After that I loaded the current ATMEL Tool chain and installed it.

    Then I installed the AVR Plugin to Eclipse (Help/Install new Software).
    That process worked fine so far.
    After installing I restarted Eclipse as recommended.

    Now I can see the typical buttons and so on are available and things are
    looking fine.
    Under Window/Preferences/AVR/Paths I keyed in the path to th AVR Toolchain.

    AVR-GCC ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
    GNU make ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
    AVR Header Files ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR
    Toolchain\avr\include
    AVRDude ==> C:\Program Files (x86)\Atmel\AVR Tools\AVR Toolchain\bin
    Atmel Part Description Files are not available and so far I know not
    necessary.

    Finally I disabled search for system path at startup and click the button
    Apply

    To be sure everything is correct I restarted Eclipse.

    When I now start to create a new C project (File/New/C Project)
    For Project name I key in "Test"

    Project type:
    AVR Cross Target Application
    Empty Project

    Toolchains:
    AVR-GCC Toolchain

    Click Button Next
    I unselected Debug

    Click Button Next

    I see the dialogue AVR Target Hardware Properties

    Here is the MCU Type: empty and the MCU Frequency (Hz): is 1000000

    When I click to the MCU Type nothing is to select.


    Sent from sourceforge.net because you indicated interest in <
    https://sourceforge.net/p/avr-eclipse/support-requests/25/>

    To unsubscribe from further messages, please visit <
    https://sourceforge.net/auth/subscriptions/>

    --
    Vasi

     

    Related

    Support Requests: #25

1 2 > >> (Page 1 of 2)

Log in to post a comment.