summaryrefslogtreecommitdiffstats
path: root/programmer.h
diff options
context:
space:
mode:
authorJustin Chevrier <jchevrier@gmail.com>2015-02-08 21:58:10 +0000
committerStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>2015-02-08 21:58:10 +0000
commitf3973600404204013c403625a11bf434dade628c (patch)
tree597dd6c02ecd223e56d3088682e1c5314409af1f /programmer.h
parent03d4faca7aed125d48c69dd50119e0ec0bfd5978 (diff)
downloadflashrom-f3973600404204013c403625a11bf434dade628c.zip
flashrom-f3973600404204013c403625a11bf434dade628c.tar.gz
Add support for the Microchip PICkit2 as an SPI programmer
This patch was inspired by the code in AVRDude (open source Atmel AVR programmer) to support the PICkit2 written by Doug Brown [1]. The Dediprog code in flashrom was used as the template for this code with some reference to the ft2232 code as well. [1] - https://github.com/steve-m/avrdude/blob/master/pickit2.c Corresponding to flashrom svn r1881. Signed-off-by: Justin Chevrier <jchevrier@gmail.com> Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Diffstat (limited to 'programmer.h')
-rw-r--r--programmer.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/programmer.h b/programmer.h
index c61f429..913522b 100644
--- a/programmer.h
+++ b/programmer.h
@@ -102,6 +102,9 @@ enum programmer {
#if CONFIG_MSTARDDC_SPI == 1
PROGRAMMER_MSTARDDC_SPI,
#endif
+#if CONFIG_PICKIT2_SPI == 1
+ PROGRAMMER_PICKIT2_SPI,
+#endif
PROGRAMMER_INVALID /* This must always be the last entry. */
};
@@ -480,6 +483,11 @@ extern const struct dev_entry devs_usbblasterspi[];
int mstarddc_spi_init(void);
#endif
+/* pickit2_spi.c */
+#if CONFIG_PICKIT2_SPI == 1
+int pickit2_spi_init(void);
+#endif
+
/* rayer_spi.c */
#if CONFIG_RAYER_SPI == 1
int rayer_spi_init(void);
@@ -564,6 +572,9 @@ enum spi_controller {
#if CONFIG_MSTARDDC_SPI == 1
SPI_CONTROLLER_MSTARDDC,
#endif
+#if CONFIG_PICKIT2_SPI == 1
+ SPI_CONTROLLER_PICKIT2,
+#endif
};
#define MAX_DATA_UNSPECIFIED 0
OpenPOWER on IntegriCloud