]> sigrok.org Git - libsigrokdecode.git/blame - decoders/avr_pdi/__init__.py
decoders: Various cosmetic/consistency/typo fixes.
[libsigrokdecode.git] / decoders / avr_pdi / __init__.py
CommitLineData
f0349f7f
GS
1##
2## This file is part of the libsigrokdecode project.
3##
4## Copyright (C) 2016 Gerhard Sittig <gerhard.sittig@gmx.net>
5##
6## This program is free software; you can redistribute it and/or modify
7## it under the terms of the GNU General Public License as published by
8## the Free Software Foundation; either version 2 of the License, or
9## (at your option) any later version.
10##
11## This program is distributed in the hope that it will be useful,
12## but WITHOUT ANY WARRANTY; without even the implied warranty of
13## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14## GNU General Public License for more details.
15##
16## You should have received a copy of the GNU General Public License
17## along with this program; if not, see <http://www.gnu.org/licenses/>.
18##
19
20'''
21PDI (Program and Debug Interface) is an Atmel proprietary interface for
2787cf2a
UH
22external programming and on-chip debugging of the device.
23
24See the Atmel Application Note AVR1612 "PDI programming driver" and the
25"Program and Debug Interface" section in the Xmega A manual for details.
f0349f7f
GS
26
27The protocol uses two pins: the RESET pin and one dedicated DATA pin.
28The RESET pin provides a clock, the DATA pin communicates serial frames
29with a start bit, eight data bits, an even parity bit, and two stop bits.
30Data communication is bidirectional and half duplex, the device will
31provide response data after reception of a respective request.
32
33Protocol frames communicate opcodes and their arguments, which provides
34random and sequential access to the device's address space. By accessing
35the registers of internal peripherals, especially the NVM controller,
36it's possible to identify the device, read from and write to several
37kinds of memory (signature rows, fuses and lock bits, internal flash and
38EEPROM, memory mapped peripherals), and to control execution of software
39on the device.
40'''
41
42from .pd import Decoder