As of August 2020 the site you are on (wiki.newae.com) is deprecated, and content is now at rtfm.newae.com.

Difference between revisions of "Simulating the XMEGA Target Code"

From ChipWhisperer Wiki
Jump to: navigation, search
Line 18: Line 18:
 
From the File --> Open menu, select Open Object File For Debugging:
 
From the File --> Open menu, select Open Object File For Debugging:
  
[[File:sim1_openobject.png|400px]]
+
[[File:sim1_openobject.png]]
  
 
== Simulating ==
 
== Simulating ==
 +
 +
[[File:sim2_selectelf.png]]
 +
 +
[[File:sim3_saveproject.png]]
 +
 +
[[File:sim4_selectxmega.png]]
 +
 +
[[File:sim5_openfile.png]]
 +
 +
[[File:sim6_setbreakpoint.png]]
 +
 +
[[File:sim7_selecttoolA.png]]
 +
 +
[[File:sim8_selecttoolB.png]]
 +
 +
[[File:sim9_startdebug.png]]
 +
 +
[[File:sim10_insertcall.png]]
 +
 +
[[File:sim11_reload1.png]]
 +
 +
[[File:sim11_reload2.png]]
 +
 +
[[File:sim12_pstatus.png]]
 +
 +
[[File:sim13_cyclecount.png]]
 +
 +
[[File:sim14_resettozero.png]]
 +
 +
[[File:sim15_bpnothit.png]]
 +
 +
[[File:sim16_stepin.png]]
 +
  
 
== Timing ==
 
== Timing ==

Revision as of 05:13, 3 June 2016

This page describes how to simulate the XMEGA target code in order to determine the length of time AES takes. This was designed for the CHES CTF 2016, but may be valuable in other circumstances.

Required Tools

You will require the following tools:

  • Atmel Studio 7
  • avr-gcc (suggested to use WinAVR, but you can actually build with Atmel Studio)

Simulating

The following assumes you have an EXTERNAL build environment (such as WinAVR, or avr-gcc). If you'd like to use Atmel Studio to build the project, see instructions at the end of this page.

Opening Object File

To begin, we'll be opening the existing .elf file. This file contains all the debug information created during the build process.

From the File --> Open menu, select Open Object File For Debugging:

Sim1 openobject.png

Simulating

Sim2 selectelf.png

Sim3 saveproject.png

Sim4 selectxmega.png

Sim5 openfile.png

Sim6 setbreakpoint.png

Sim7 selecttoolA.png

Sim8 selecttoolB.png

Sim9 startdebug.png

Sim10 insertcall.png

Sim11 reload1.png

Sim11 reload2.png

Sim12 pstatus.png

Sim13 cyclecount.png

Sim14 resettozero.png

Sim15 bpnothit.png

Sim16 stepin.png


Timing

Building