cancel
Showing results for 
Search instead for 
Did you mean: 

I deleted my EWARM folder thinking it wasn't necessary. I'm now getting 'error during code generation'

AndrewM
Associate III

I seem to have mistakenly assumed that all relevant data is contained within the .touchgfx project file and that everything else can be regenerated from that.

Is there any way to recover from this?

C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/generators/iar_project_updater.rb:144:in `read': No such file or directory - ../EWARM/TouchGFX.ewp (Errno::ENOENT)
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/generators/iar_project_updater.rb:144:in `project_file_contents'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/generators/iar_project_updater.rb:148:in `project_file_xml'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/generators/iar_project_updater.rb:33:in `check_project_node'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/generators/iar_project_updater.rb:22:in `run'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/generators/update_project.rb:44:in `run'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx/cli/inside.rb:45:in `update_project'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx.rb:16:in `<module:CLI>'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx.rb:9:in `<module:TouchGFX>'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/lib/touchgfx.rb:8:in `<top (required)>'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:55:in `require'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:55:in `require'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/lib/ruby/gems/1.9.1/gems/touchgfx-cli-4.10.0/bin/touchgfx:6:in `<top (required)>'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/bin/touchgfx:22:in `load'
	from C:/TouchGFX/4.10.0/env/MinGW/msys/1.0/Ruby193/bin/touchgfx:22:in `<main>'
  

  

1 ACCEPTED SOLUTION

Accepted Solutions
Martin KJELDSEN
Chief III

Hi @AndrewM​,

Welcome! Let me explain something about how the designer works when it comes to the error you saw. (You're right that satisfying the check for ../EWARM/TouchGFX.ewp would allow code generation/compilation to complete).

The designer has something we call a "Post Generate Command". It's something that the user can fill out him/herself, but... our application templates AND to some extent CubeMX will automatically fill this depending on what you chose as your IDE in the project generation tab.

We have a tool in our environment that can take any extension and evaluate it. In the case of .ewp it will call the IAR project updater and then insert the files that the designer generates (image assets, font assets, screen definitions) into the ewp file at a fixed location. If the file is not there, the updater will fail - I will agree that we could do it more gracefully =)

/Martin

View solution in original post

3 REPLIES 3
AndrewM
Associate III

All good now - I simply copied across the EWARM folder from a different but similar project and it builds now.

I'm still new to TouchGFX so didn't realise EWARM was part of the code gen process on windows - I assumed it was only a product of the process. On linux I can build the simulator and the target binaries without EWARM being present - hence my surprise when I returned to the windows build after removing EWARM and finding errors.

Martin KJELDSEN
Chief III

Hi @AndrewM​,

Welcome! Let me explain something about how the designer works when it comes to the error you saw. (You're right that satisfying the check for ../EWARM/TouchGFX.ewp would allow code generation/compilation to complete).

The designer has something we call a "Post Generate Command". It's something that the user can fill out him/herself, but... our application templates AND to some extent CubeMX will automatically fill this depending on what you chose as your IDE in the project generation tab.

We have a tool in our environment that can take any extension and evaluate it. In the case of .ewp it will call the IAR project updater and then insert the files that the designer generates (image assets, font assets, screen definitions) into the ewp file at a fixed location. If the file is not there, the updater will fail - I will agree that we could do it more gracefully =)

/Martin

AndrewM
Associate III

Hey Martin,

thanks for the info! =)

Cheers,

Andrew