Generating Atmel Studio 7 projects from CMake - does it exist?

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

Hi folks,

 

-------------------------------------------- Introducing myself, saying "Hello" to the community ! --------------------------------------------

 

As I'm a new one on this forum, let me introduce myself rapidly.

I'm a hobbyist who deeply loves OpenSource (and Libre, off course) projects and I try to use them (and contribute) as much as I could.
As a result, I use Linux OSes everyday and try to learn things "the hard way".

It takes time for sure, but I think this approach is greatly rewarding.

I've been developing software for embedded targets mostly for side projects as well as in my daily job, either using C or C++.
I used different platforms throughout the years, such as STM32, AVR8 (off course, that's why I'm here), Texas Instrument's TMS570, ... and discovered embedded programming with Arduino.

 

Coming back to AVRs, I have used AtmelStudio many times in the past, nowadays however I tend to use CMake and avr toolchain directly.
Despite AtmelStudio being a great tool with a lot of features, I like the way CMake works and I just feel more comfortable to work on a full Linux environment.

I also use SimAvr to debug my drivers, and it was fine until I got stuck with TWI hardware simulation, I suppose Atmel's simulator shall be more accurate on those hardware aspects and that is the reason why I'd like to port my project to AtmelStudio.

By the way, I am totally aware that the best simulation tool ... will always be the real target. I recently acquired an AtmelICE just for this, however I think it's a rather good idea to help other use their favorite IDE when using one of my projects as everyone is not always familiar with CMake nor Linux ecosystems.

 

-------------------------------------------- Now let's ask THE question --------------------------------------------

 

Well, I think now is the time for the question!

As a disclaimer, I tried to get an answer on my side, investing time on forums ; I even dove into CMake's source code.
If I'm here, that's because I could not find what I was looking for(...)

 

So let's begin : does anyone know a way to automate conversion of CMake projects to AtmelStudio ones ?

As mentioned above, I could not find a proper CMake generator which targets AtmelStudio (7), and if I can always convert my CMake project to AtmelStudio manually, I was hoping that someone found a way before me.
 

I saw that atsproj files are really close to how VisualStudio writes its own .vcxproj project files (indeed, ATS is a plugin of VisualStudioC++), so I suppose using a CMake generator targeting the right version of VisualStudio will partially do the trick.
However, I do not know about the AtmelStudio project file's specification - I assume Atmel did modify the file's architecture to integrate their own build process.

 

I've seen a lot of good progress from Microsoft dev teams to integrate CMake projects within the VisualStudio development environment in the last years (and it works mostly fine!), however this was done after Atmel released its last version of AtmelStudio.
 

If you reached the end of this post, thank you for your attention! :)

This topic has a solution.
Last Edited: Fri. Sep 4, 2020 - 10:21 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

bebenlebricolo wrote:
I could not find a proper CMake generator which targets AtmelStudio (7)
And there is the issue. Your typical Cmake will say:

Generators

The following generators are available on this platform:
  Unix Makefiles               = Generates standard UNIX makefiles.
  Ninja                        = Generates build.ninja files.
  Watcom WMake                 = Generates Watcom WMake makefiles.
  CodeBlocks - Ninja           = Generates CodeBlocks project files.
  CodeBlocks - Unix Makefiles  = Generates CodeBlocks project files.
  CodeLite - Ninja             = Generates CodeLite project files.
  CodeLite - Unix Makefiles    = Generates CodeLite project files.
  Eclipse CDT4 - Ninja         = Generates Eclipse CDT 4.0 project files.
  Eclipse CDT4 - Unix Makefiles= Generates Eclipse CDT 4.0 project files.
  KDevelop3                    = Generates KDevelop 3 project files.
  KDevelop3 - Unix Makefiles   = Generates KDevelop 3 project files.
  Kate - Ninja                 = Generates Kate project files.
  Kate - Unix Makefiles        = Generates Kate project files.
  Sublime Text 2 - Ninja       = Generates Sublime Text 2 project files.
  Sublime Text 2 - Unix Makefiles
                               = Generates Sublime Text 2 project files.

while the Windows version of CMake may well have generators for the various Visual Studio I think you'll find that Studio 7 (while based on VS2015) is so "specialist" that no one will ever have developed a generator for it. But take a step back - do you really have some Cmake code for AVR that is so complex that you can't just manually recreate a .atsln for it?

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

Hi, thanks for your reply!

 

As you mentioned, I can effectively do everything by hand.

That's not a big deal, however as my main development platform is Linux, I don't want to manually maintain 2 build systems if I can have a single one.

 

I wonder how different AtmelStudio is compared to its host VisualStudio counterpart.

I don't think Microchip is willing to invest time on this neither, but it would be great to get the file specification, maybe forking a standard VisualStudio Cmake generator and adding the relevant code to account for AtmelStudio differences is possible without developping a generator from scratch (...)

 

 

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

BTW I just checked Cmake on Windows...

Generators

The following generators are available on this platform (* marks default):
  Visual Studio 16 2019        = Generates Visual Studio 2019 project files.
                                 Use -A option to specify architecture.
* Visual Studio 15 2017 [arch] = Generates Visual Studio 2017 project files.
                                 Optional [arch] can be "Win64" or "ARM".
  Visual Studio 14 2015 [arch] = Generates Visual Studio 2015 project files.
                                 Optional [arch] can be "Win64" or "ARM".
  Visual Studio 12 2013 [arch] = Generates Visual Studio 2013 project files.
                                 Optional [arch] can be "Win64" or "ARM".
  Visual Studio 11 2012 [arch] = Generates Visual Studio 2012 project files.
                                 Optional [arch] can be "Win64" or "ARM".
  Visual Studio 10 2010 [arch] = Generates Visual Studio 2010 project files.
                                 Optional [arch] can be "Win64" or "IA64".
  Visual Studio 9 2008 [arch]  = Generates Visual Studio 2008 project files.
                                 Optional [arch] can be "Win64" or "IA64".
  Borland Makefiles            = Generates Borland makefiles.
  NMake Makefiles              = Generates NMake makefiles.
  NMake Makefiles JOM          = Generates JOM makefiles.
  MSYS Makefiles               = Generates MSYS makefiles.
  MinGW Makefiles              = Generates a make file for use with
                                 mingw32-make.
  Unix Makefiles               = Generates standard UNIX makefiles.
  Green Hills MULTI            = Generates Green Hills MULTI files
                                 (experimental, work-in-progress).
  Ninja                        = Generates build.ninja files.
  Ninja Multi-Config           = Generates build-<Config>.ninja files.
  Watcom WMake                 = Generates Watcom WMake makefiles.
  CodeBlocks - MinGW Makefiles = Generates CodeBlocks project files.
  CodeBlocks - NMake Makefiles = Generates CodeBlocks project files.
  CodeBlocks - NMake Makefiles JOM
                               = Generates CodeBlocks project files.
  CodeBlocks - Ninja           = Generates CodeBlocks project files.
  CodeBlocks - Unix Makefiles  = Generates CodeBlocks project files.
  CodeLite - MinGW Makefiles   = Generates CodeLite project files.
  CodeLite - NMake Makefiles   = Generates CodeLite project files.
  CodeLite - Ninja             = Generates CodeLite project files.
  CodeLite - Unix Makefiles    = Generates CodeLite project files.
  Sublime Text 2 - MinGW Makefiles
                               = Generates Sublime Text 2 project files.
  Sublime Text 2 - NMake Makefiles
                               = Generates Sublime Text 2 project files.
  Sublime Text 2 - Ninja       = Generates Sublime Text 2 project files.
  Sublime Text 2 - Unix Makefiles
                               = Generates Sublime Text 2 project files.
  Kate - MinGW Makefiles       = Generates Kate project files.
  Kate - NMake Makefiles       = Generates Kate project files.
  Kate - Ninja                 = Generates Kate project files.
  Kate - Unix Makefiles        = Generates Kate project files.
  Eclipse CDT4 - NMake Makefiles
                               = Generates Eclipse CDT 4.0 project files.
  Eclipse CDT4 - MinGW Makefiles
                               = Generates Eclipse CDT 4.0 project files.
  Eclipse CDT4 - Ninja         = Generates Eclipse CDT 4.0 project files.
  Eclipse CDT4 - Unix Makefiles= Generates Eclipse CDT 4.0 project files.

so a few more generators but .atsln and .cproj files in AS7 are similar but not the same as .sln and .vcxproj files in VS2015. Atmel included a whole bunch of options for their own AVR building system that are of no relevance to MSVC. A typical .sln for VS2017 looks like:

D:\c\testfp>type testfp.sln

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.28307.705
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "testfp", "testfp\testfp.vcxproj", "{E77CFD1D-3CFB-415E-94C7-BC93E923832B}"
EndProject
Global
        GlobalSection(SolutionConfigurationPlatforms) = preSolution
                Debug|x64 = Debug|x64
                Debug|x86 = Debug|x86
                Release|x64 = Release|x64
                Release|x86 = Release|x86
        EndGlobalSection
        GlobalSection(ProjectConfigurationPlatforms) = postSolution
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Debug|x64.ActiveCfg = Debug|x64
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Debug|x64.Build.0 = Debug|x64
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Debug|x86.ActiveCfg = Debug|Win32
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Debug|x86.Build.0 = Debug|Win32
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Release|x64.ActiveCfg = Release|x64
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Release|x64.Build.0 = Release|x64
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Release|x86.ActiveCfg = Release|Win32
                {E77CFD1D-3CFB-415E-94C7-BC93E923832B}.Release|x86.Build.0 = Release|Win32
        EndGlobalSection
        GlobalSection(SolutionProperties) = preSolution
                HideSolutionNode = FALSE
        EndGlobalSection
        GlobalSection(ExtensibilityGlobals) = postSolution
                SolutionGuid = {21266B01-804D-4E81-A928-7BD4F1BFFFCF}
        EndGlobalSection
EndGlobal

while a .atsln for AS7 looks like:

D:\test>type test.atsln

Microsoft Visual Studio Solution File, Format Version 12.00
# Atmel Studio Solution File, Format Version 11.00
VisualStudioVersion = 14.0.23107.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{54F91283-7BC4-4236-8FF9-10F437C3AD48}") = "test", "test\test.cproj", "{DCE6C7E3-EE26-4D79-826B-08594B9AD897}"
EndProject
Global
        GlobalSection(SolutionConfigurationPlatforms) = preSolution
                Debug|AVR = Debug|AVR
                Release|AVR = Release|AVR
        EndGlobalSection
        GlobalSection(ProjectConfigurationPlatforms) = postSolution
                {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Debug|AVR.ActiveCfg = Debug|AVR
                {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Debug|AVR.Build.0 = Debug|AVR
                {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Release|AVR.ActiveCfg = Release|AVR
                {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Release|AVR.Build.0 = Release|AVR
        EndGlobalSection
        GlobalSection(SolutionProperties) = preSolution
                HideSolutionNode = FALSE
        EndGlobalSection
EndGlobal

So the SLN/ATSLN ar quite similar but the .vcxproj looks like:

D:\c\testfp\testfp>type testfp.vcxproj
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <ItemGroup Label="ProjectConfigurations">
    <ProjectConfiguration Include="Debug|Win32">
      <Configuration>Debug</Configuration>
      <Platform>Win32</Platform>
    </ProjectConfiguration>
    <ProjectConfiguration Include="Release|Win32">
      <Configuration>Release</Configuration>
      <Platform>Win32</Platform>
    </ProjectConfiguration>
    <ProjectConfiguration Include="Debug|x64">
      <Configuration>Debug</Configuration>
      <Platform>x64</Platform>
    </ProjectConfiguration>
    <ProjectConfiguration Include="Release|x64">
      <Configuration>Release</Configuration>
      <Platform>x64</Platform>
    </ProjectConfiguration>
  </ItemGroup>
  <PropertyGroup Label="Globals">
    <VCProjectVersion>15.0</VCProjectVersion>
    <ProjectGuid>{E77CFD1D-3CFB-415E-94C7-BC93E923832B}</ProjectGuid>
    <Keyword>Win32Proj</Keyword>
    <RootNamespace>testfp</RootNamespace>
    <WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
  </PropertyGroup>
  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
    <ConfigurationType>Application</ConfigurationType>
    <UseDebugLibraries>true</UseDebugLibraries>
    <PlatformToolset>v141</PlatformToolset>
    <CharacterSet>Unicode</CharacterSet>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
    <ConfigurationType>Application</ConfigurationType>
    <UseDebugLibraries>false</UseDebugLibraries>
    <PlatformToolset>v141</PlatformToolset>
    <WholeProgramOptimization>true</WholeProgramOptimization>
    <CharacterSet>Unicode</CharacterSet>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
    <ConfigurationType>Application</ConfigurationType>
    <UseDebugLibraries>true</UseDebugLibraries>
    <PlatformToolset>v141</PlatformToolset>
    <CharacterSet>Unicode</CharacterSet>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
    <ConfigurationType>Application</ConfigurationType>
    <UseDebugLibraries>false</UseDebugLibraries>
    <PlatformToolset>v141</PlatformToolset>
    <WholeProgramOptimization>true</WholeProgramOptimization>
    <CharacterSet>Unicode</CharacterSet>
  </PropertyGroup>
  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
  <ImportGroup Label="ExtensionSettings">
  </ImportGroup>
  <ImportGroup Label="Shared">
  </ImportGroup>
  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
  </ImportGroup>
  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
  </ImportGroup>
  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
  </ImportGroup>
  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
  </ImportGroup>
  <PropertyGroup Label="UserMacros" />
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
    <LinkIncremental>true</LinkIncremental>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
    <LinkIncremental>true</LinkIncremental>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
    <LinkIncremental>false</LinkIncremental>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
    <LinkIncremental>false</LinkIncremental>
  </PropertyGroup>
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
    <ClCompile>
      <Optimization>Disabled</Optimization>
      <SDLCheck>true</SDLCheck>
      <PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
      <ConformanceMode>true</ConformanceMode>
      <PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
    </ClCompile>
    <Link>
      <SubSystem>Console</SubSystem>
      <GenerateDebugInformation>true</GenerateDebugInformation>
    </Link>
  </ItemDefinitionGroup>
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
    <ClCompile>
      <PrecompiledHeader>Use</PrecompiledHeader>
      <WarningLevel>Level3</WarningLevel>
      <Optimization>Disabled</Optimization>
      <SDLCheck>true</SDLCheck>
      <PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
      <ConformanceMode>true</ConformanceMode>
      <PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
    </ClCompile>
    <Link>
      <SubSystem>Console</SubSystem>
      <GenerateDebugInformation>true</GenerateDebugInformation>
    </Link>
  </ItemDefinitionGroup>
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
    <ClCompile>
      <Optimization>MaxSpeed</Optimization>
      <FunctionLevelLinking>true</FunctionLevelLinking>
      <IntrinsicFunctions>true</IntrinsicFunctions>
      <SDLCheck>true</SDLCheck>
      <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
      <ConformanceMode>true</ConformanceMode>
      <PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
    </ClCompile>
    <Link>
      <SubSystem>Console</SubSystem>
      <EnableCOMDATFolding>true</EnableCOMDATFolding>
      <OptimizeReferences>true</OptimizeReferences>
      <GenerateDebugInformation>true</GenerateDebugInformation>
    </Link>
  </ItemDefinitionGroup>
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
    <ClCompile>
      <PrecompiledHeader>Use</PrecompiledHeader>
      <WarningLevel>Level3</WarningLevel>
      <Optimization>MaxSpeed</Optimization>
      <FunctionLevelLinking>true</FunctionLevelLinking>
      <IntrinsicFunctions>true</IntrinsicFunctions>
      <SDLCheck>true</SDLCheck>
      <PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
      <ConformanceMode>true</ConformanceMode>
      <PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
    </ClCompile>
    <Link>
      <SubSystem>Console</SubSystem>
      <EnableCOMDATFolding>true</EnableCOMDATFolding>
      <OptimizeReferences>true</OptimizeReferences>
      <GenerateDebugInformation>true</GenerateDebugInformation>
    </Link>
  </ItemDefinitionGroup>
  <ItemGroup>
    <ClInclude Include="pch.h" />
  </ItemGroup>
  <ItemGroup>
    <ClCompile Include="main.c" />
    <ClCompile Include="pch.cpp">
      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
    </ClCompile>
    <ClCompile Include="testfp.cpp">
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
    </ClCompile>
  </ItemGroup>
  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
  <ImportGroup Label="ExtensionTargets">
  </ImportGroup>
</Project>

and a .cproj for AS7 looks like:

D:\test\test>type test.cproj
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="14.0">
  <PropertyGroup>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectVersion>7.0</ProjectVersion>
    <ToolchainName>com.Atmel.AVRGCC8.CPP</ToolchainName>
    <ProjectGuid>dce6c7e3-ee26-4d79-826b-08594b9ad897</ProjectGuid>
    <avrdevice>ATmega328P</avrdevice>
    <avrdeviceseries>none</avrdeviceseries>
    <OutputType>Executable</OutputType>
    <Language>CPP</Language>
    <OutputFileName>$(MSBuildProjectName)</OutputFileName>
    <OutputFileExtension>.elf</OutputFileExtension>
    <OutputDirectory>$(MSBuildProjectDirectory)\$(Configuration)</OutputDirectory>
    <AssemblyName>test</AssemblyName>
    <Name>test</Name>
    <RootNamespace>test</RootNamespace>
    <ToolchainFlavour>Native</ToolchainFlavour>
    <KeepTimersRunning>true</KeepTimersRunning>
    <OverrideVtor>false</OverrideVtor>
    <CacheFlash>false</CacheFlash>
    <ProgFlashFromRam>true</ProgFlashFromRam>
    <RamSnippetAddress>0x20000000</RamSnippetAddress>
    <UncachedRange />
    <preserveEEPROM>true</preserveEEPROM>
    <OverrideVtorValue>exception_table</OverrideVtorValue>
    <BootSegment>2</BootSegment>
    <ResetRule>0</ResetRule>
    <eraseonlaunchrule>0</eraseonlaunchrule>
    <EraseKey />
    <AsfFrameworkConfig>
      <framework-data xmlns="">
        <options />
        <configurations />
        <files />
        <documentation help="" />
        <offline-documentation help="" />
        <dependencies>
          <content-extension eid="atmel.asf" uuidref="Atmel.ASF" version="3.40.0" />
        </dependencies>
      </framework-data>
    </AsfFrameworkConfig>
    <avrtool>
    </avrtool>
    <avrtoolserialnumber>
    </avrtoolserialnumber>
    <avrdeviceexpectedsignature>0x1E950F</avrdeviceexpectedsignature>
    <com_atmel_avrdbg_tool_atmelice>
      <ToolOptions>
        <InterfaceProperties>
          <JtagDbgClock>0</JtagDbgClock>
          <JtagEnableExtResetOnStartSession>false</JtagEnableExtResetOnStartSession>
          <JtagInChain>false</JtagInChain>
          <JtagDevicesBefore>0</JtagDevicesBefore>
          <JtagDevicesAfter>0</JtagDevicesAfter>
          <JtagInstrBitsBefore>0</JtagInstrBitsBefore>
          <JtagInstrBitsAfter>0</JtagInstrBitsAfter>
          <JtagSelectedDeviceIndexInChain>0</JtagSelectedDeviceIndexInChain>
          <JtagDaisyChainDevices>Device/TAP with ID 0x4958703F,1230532671,4</JtagDaisyChainDevices>
        </InterfaceProperties>
        <InterfaceName>JTAG</InterfaceName>
      </ToolOptions>
      <ToolType>com.atmel.avrdbg.tool.atmelice</ToolType>
      <ToolNumber>J41800104894</ToolNumber>
      <ToolName>Atmel-ICE</ToolName>
    </com_atmel_avrdbg_tool_atmelice>
    <avrtoolinterface>
    </avrtoolinterface>
    <avrtoolinterfaceclock>0</avrtoolinterfaceclock>
    <UseGdb>False</UseGdb>
    <UseGdbCustomPath>False</UseGdbCustomPath>
    <AdditionalModules>
    </AdditionalModules>
    <com_atmel_avrdbg_tool_simulator>
      <ToolOptions>
        <InterfaceProperties>
        </InterfaceProperties>
        <InterfaceName>
        </InterfaceName>
      </ToolOptions>
      <ToolType>com.atmel.avrdbg.tool.simulator</ToolType>
      <ToolNumber>
      </ToolNumber>
      <ToolName>Simulator</ToolName>
    </com_atmel_avrdbg_tool_simulator>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
    <ToolchainSettings>
      <AvrGccCpp>
  <avrgcc.common.Device>-mmcu=atmega328p -B "%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\gcc\dev\atmega328p"</avrgcc.common.Device>
  <avrgcc.common.optimization.RelaxBranches>True</avrgcc.common.optimization.RelaxBranches>
  <avrgcc.common.outputfiles.hex>True</avrgcc.common.outputfiles.hex>
  <avrgcc.common.outputfiles.lss>True</avrgcc.common.outputfiles.lss>
  <avrgcc.common.outputfiles.eep>True</avrgcc.common.outputfiles.eep>
  <avrgcc.common.outputfiles.srec>True</avrgcc.common.outputfiles.srec>
  <avrgcc.common.outputfiles.usersignatures>False</avrgcc.common.outputfiles.usersignatures>
  <avrgcc.compiler.general.ChangeDefaultCharTypeUnsigned>True</avrgcc.compiler.general.ChangeDefaultCharTypeUnsigned>
  <avrgcc.compiler.general.ChangeDefaultBitFieldUnsigned>True</avrgcc.compiler.general.ChangeDefaultBitFieldUnsigned>
  <avrgcc.compiler.symbols.DefSymbols>
    <ListValues>
      <Value>NDEBUG</Value>
    </ListValues>
  </avrgcc.compiler.symbols.DefSymbols>
  <avrgcc.compiler.directories.IncludePaths>
    <ListValues>
      <Value>%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\include</Value>
    </ListValues>
  </avrgcc.compiler.directories.IncludePaths>
  <avrgcc.compiler.optimization.level>Optimize for size (-Os)</avrgcc.compiler.optimization.level>
  <avrgcc.compiler.optimization.PackStructureMembers>True</avrgcc.compiler.optimization.PackStructureMembers>
  <avrgcc.compiler.optimization.AllocateBytesNeededForEnum>True</avrgcc.compiler.optimization.AllocateBytesNeededForEnum>
  <avrgcc.compiler.optimization.DebugLevel>Default (-g2)</avrgcc.compiler.optimization.DebugLevel>
  <avrgcc.compiler.warnings.AllWarnings>True</avrgcc.compiler.warnings.AllWarnings>
  <avrgcc.compiler.miscellaneous.DoNotDeleteTemporaryFiles>True</avrgcc.compiler.miscellaneous.DoNotDeleteTemporaryFiles>
  <avrgcccpp.compiler.directories.IncludePaths>
    <ListValues>
      <Value>%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\include</Value>
    </ListValues>
  </avrgcccpp.compiler.directories.IncludePaths>
  <avrgcccpp.linker.libraries.Libraries>
    <ListValues>
      <Value>libm</Value>
    </ListValues>
  </avrgcccpp.linker.libraries.Libraries>
  <avrgcccpp.assembler.general.IncludePaths>
    <ListValues>
      <Value>%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\include</Value>
    </ListValues>
  </avrgcccpp.assembler.general.IncludePaths>
</AvrGccCpp>
    </ToolchainSettings>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
    <ToolchainSettings>
      <AvrGccCpp>
  <avrgcc.common.Device>-mmcu=atmega328p -B "%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\gcc\dev\atmega328p"</avrgcc.common.Device>
  <avrgcc.common.optimization.RelaxBranches>True</avrgcc.common.optimization.RelaxBranches>
  <avrgcc.common.outputfiles.hex>True</avrgcc.common.outputfiles.hex>
  <avrgcc.common.outputfiles.lss>True</avrgcc.common.outputfiles.lss>
  <avrgcc.common.outputfiles.eep>True</avrgcc.common.outputfiles.eep>
  <avrgcc.common.outputfiles.srec>True</avrgcc.common.outputfiles.srec>
  <avrgcc.common.outputfiles.usersignatures>False</avrgcc.common.outputfiles.usersignatures>
  <avrgcc.compiler.general.ChangeDefaultCharTypeUnsigned>True</avrgcc.compiler.general.ChangeDefaultCharTypeUnsigned>
  <avrgcc.compiler.general.ChangeDefaultBitFieldUnsigned>True</avrgcc.compiler.general.ChangeDefaultBitFieldUnsigned>
  <avrgcc.compiler.symbols.DefSymbols>
    <ListValues>
      <Value>DEBUG</Value>
    </ListValues>
  </avrgcc.compiler.symbols.DefSymbols>
  <avrgcc.compiler.directories.IncludePaths>
    <ListValues>
      <Value>../some/place/to/look/for/lcd/headers</Value>
      <Value>%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\include</Value>
    </ListValues>
  </avrgcc.compiler.directories.IncludePaths>
  <avrgcc.compiler.optimization.level>Optimize (-O1)</avrgcc.compiler.optimization.level>
  <avrgcc.compiler.optimization.PrepareFunctionsForGarbageCollection>False</avrgcc.compiler.optimization.PrepareFunctionsForGarbageCollection>
  <avrgcc.compiler.optimization.PrepareDataForGarbageCollection>False</avrgcc.compiler.optimization.PrepareDataForGarbageCollection>
  <avrgcc.compiler.optimization.PackStructureMembers>True</avrgcc.compiler.optimization.PackStructureMembers>
  <avrgcc.compiler.optimization.AllocateBytesNeededForEnum>True</avrgcc.compiler.optimization.AllocateBytesNeededForEnum>
  <avrgcc.compiler.optimization.DebugLevel>Default (-g2)</avrgcc.compiler.optimization.DebugLevel>
  <avrgcc.compiler.warnings.AllWarnings>True</avrgcc.compiler.warnings.AllWarnings>
  <avrgcc.compiler.warnings.Pedantic>True</avrgcc.compiler.warnings.Pedantic>
  <avrgcc.compiler.miscellaneous.OtherFlags>-std=gnu99 -H -fverbose-asm</avrgcc.compiler.miscellaneous.OtherFlags>
  <avrgcc.compiler.miscellaneous.DoNotDeleteTemporaryFiles>True</avrgcc.compiler.miscellaneous.DoNotDeleteTemporaryFiles>
  <avrgcccpp.compiler.directories.IncludePaths>
    <ListValues>
      <Value>%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\include</Value>
    </ListValues>
  </avrgcccpp.compiler.directories.IncludePaths>
  <avrgcccpp.compiler.optimization.level>Optimize debugging experience (-Og)</avrgcccpp.compiler.optimization.level>
  <avrgcccpp.compiler.optimization.PrepareDataForGarbageCollection>False</avrgcccpp.compiler.optimization.PrepareDataForGarbageCollection>
  <avrgcccpp.compiler.miscellaneous.DoNotDeleteTemporaryFiles>True</avrgcccpp.compiler.miscellaneous.DoNotDeleteTemporaryFiles>
  <avrgcccpp.linker.libraries.Libraries>
    <ListValues>
      <Value>libm</Value>
    </ListValues>
  </avrgcccpp.linker.libraries.Libraries>
  <avrgcccpp.linker.optimization.GarbageCollectUnusedSections>False</avrgcccpp.linker.optimization.GarbageCollectUnusedSections>
  <avrgcccpp.linker.miscellaneous.LinkerFlags>-Wl,-print-gc-sections</avrgcccpp.linker.miscellaneous.LinkerFlags>
  <avrgcccpp.assembler.general.IncludePaths>
    <ListValues>
      <Value>%24(PackRepoDir)\Atmel\ATmega_DFP\1.4.351\include</Value>
    </ListValues>
  </avrgcccpp.assembler.general.IncludePaths>
</AvrGccCpp>
    </ToolchainSettings>
    <PostBuildEvent>
    </PostBuildEvent>
  </PropertyGroup>
  <ItemGroup>
    <Compile Include="main.c">
      <SubType>compile</SubType>
    </Compile>
  </ItemGroup>
  <Import Project="$(AVRSTUDIO_EXE_PATH)\\Vs\\Compiler.targets" />
</Project>

SO as you can see there's almost no commonality between these.

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

I did exactly the same thing in the meantime and came to the same conclusion...
Lots of custom groups and properties such as :

<preserveEEPROM>true</preserveEEPROM>
...
<avrgcc.common.outputfiles.hex>

 

which somehow reminds me about the way STM32CubeIde works...

 

By the way, I could not see ANY "CMake" related tag on Microchip knowledge base neither.

Definitively not the tool manufacturers are willing to promote nor ease the migration from!

 

It would take time to gather enough knowledge on that file system to be able to translate generated VisualStudio projects into it.

Might really be time consuming, albeit not impossible.

 

Thanks for your time, it seems like a dead-end for now so I'll stick with the manual project recreation instead for the moment.

 

 

 

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

bebenlebricolo wrote:
By the way, I could not see ANY "CMake" related tag on Microchip knowledge base neither.
What you can do (and I have done previously as an experiment) is use Cmake for AVR but don't try to get it to generate solution/project files but just get it to generate GNU make Makefiles (ie "-G "Unix Makefiles"") then either build at the command line with "make" or tell AS7 to "use external Makefile" so it's own project stuff is ignored.

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

bebenlebricolo wrote:
I suppose Atmel's simulator shall be more accurate on those hardware aspects ...
It's in two forms (Linux shared object, Windows DLL)

atbackend.exe has a fair AVR GDB interface that will be made more complete.

bebenlebricolo wrote:
... after Atmel released its last version of AtmelStudio.
Latest version wink

Maybe the follow-on to Atmel Studio 7 will be Visual Studio and Visual Studio Code extensions that have a GDB proxy.

Reasons :

  • a more complete Visual Studio experience
  • some (most?) operators prefer Visual Studio
  • GDB is present in a lot of third party IDE

 


AVR simulators, open source | AVR Freaks

AVR CLI Assembly Debugger Project | AVR Freaks

MPLAB Snap and atbackend | AVR Freaks

Isolated Shell for Visual Studio 2019? - Developer Community

GPS: Viewing assembly code with avr-gdb | Development Log | Developers | AdaCore

GitHub - AdaCore/gps: GNAT Studio is a powerful and lightweight IDE for Ada and SPARK.

 

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

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

gchapman wrote:

Latest version 

 

Haha nice catch! Looks like reviewing my own post was not so efficient smiley !

gchapman wrote:
It's in two forms (Linux shared object, Windows DLL)

 

atbackend.exe has a fair AVR GDB interface that will be made more complete.

That's nice! I honestly did not know it did exist on Linux, I'll check this out.

clawson wrote:

What you can do (and I have done previously as an experiment) is use Cmake for AVR but don't try to get it to generate solution/project files but just get it to generate GNU make Makefiles (ie "-G "Unix Makefiles"") then either build at the command line with "make" or tell AS7 to "use external Makefile" so it's own project stuff is ignored.

 

Thanks for that idea, I came across it today and did not have the opportunity to test it yet, but might be a good starting point.

 

I agree concerning the "future" - if I may say - of AVR development, especially when it comes to Visual Studio Code as it is a much lighter tool than Visual Studio, but that is another debate!

 

 

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

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

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

bebenlebricolo wrote:
I've seen a lot of good progress from Microsoft dev teams to integrate CMake projects within the VisualStudio development environment in the last years ...
likewise at third parties

VisualGDB 5.5 RC1 is Out | Sysprogs

by Ivan Shcherbakov

September 14, 2020

...

 

Multi-Target Projects

One big limitation of the MSBuild-based Embedded project layout is the requirement to have only one target (e.g. application or static library) per project. 

...

The Embedded CMake Project Subsystem addresses this by decoupling project-level settings (e.g. toolchain, debug interface) from the target definitions (e.g. defining static libraries and references between them).

...

 

Multiple Platforms

Another limitation of MSBuild projects is that the .vcxproj file must explicitly list all relevant source files in order for them to appear in Solution Explorer. This makes it virtually impossible to target multiple devices from the same project. Embedded CMake projects don’t have this limitation. A single project can instantiate multiple BSPs, and have each target explicitly reference one of them. Or have multiple platforms, each one targeting a different device. Or even have a Simulation platform that will build the code using the MinGW toolchain:

...

VisualGDB - Version History

 


CMake

MSBuild - Visual Studio 2015 | Microsoft Docs

 

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