4.3.
Embedded Debugger Implementation
SAM HA1G16A Xplained Pro contains an Embedded Debugger (EDBG) that can be used to program and
debug the ATSAMHA1G16A using Serial Wire Debug (SWD). The Embedded Debugger also includes a
Virtual Com port interface over UART, an Atmel Data Gateway Interface over I
2
C and SPI and it includes
four of the SAM HA1 GPIOs. Atmel Studio can be used as a front end for the Embedded Debugger.
4.3.1.
Serial Wire Debug
The Serial Wire Debug (SWD) uses two pins to communicate with the target. For further information on
how to use the programming and debugging capabilities of the EDBG, see
Embedded Debugger
.
Table 4-11. SWD Connections
SAM HA1 Pin
Function
PA30
SWD clock
PA31
SWD data
4.3.2.
Virtual COM Port
The Embedded Debugger acts as a Virtual Com Port gateway by using one of the ATSAMHA1G16A
UARTs. For further information on how to use the Virtual COM port, see
Embedded Debugger
.
Table 4-12. Virtual COM Port Connections
SAM HA1 Pin
Function
PA27
SERCOM1 PAD[0] UART TXD (SAM HA1 TX line)
PA28
SERCOM1 PAD[1] UART RXD (SAM HA1 RX line)
4.3.3.
Atmel Data Gateway Interface
The Embedded Debugger features an Atmel Data Gateway Interface (DGI) by using either an SPI or I²C.
The DGI can be used to send a variety of data from the ATSAMHA1G16A to the host PC. For further
information on how to use the DGI interface, see
Atmel Data Visualizer
and the
EDBG User Guide
.
Table 4-13. DGI Interface Connections when using SPI
SAM HA1 Pin
Function
Shared Functionality
PA18
Slave select (SAM HA1 is Master)
EXT1
PA17
SERCOM3 PAD[1] SPI SCK (Serial Clock)
EXT1
,
EXT3
PA16
SERCOM3 PAD[2] SPI MISO (Master In, Slave
Out)
EXT1
,
EXT3
PA21
SERCOM3 PAD[3] SPI MOSI (Master Out, Slave
In)
EXT3
Table 4-14. DGI Interface Connections when using I
2
C
SAM HA1 Pin
Function
Shared Functionality
PA08
SERCOM2 PAD[0] SDA (Data line)
EXT1
,
EXT3
PA09
SERCOM2 PAD[1] SCL (Clock line)
EXT1
,
EXT3
Atmel SAM HA1G16A Xplained Pro [USER GUIDE]
Atmel-9426A-SAM-HA1G16A-Xplained-Pro_User Guide-10/2016
16
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from