summaryrefslogtreecommitdiff
path: root/firmware/src/dfu
diff options
context:
space:
mode:
authorlaforge <laforge@6dc7ffe9-61d6-0310-9af1-9938baff3ed1>2006-12-18 12:32:48 +0000
committerlaforge <laforge@6dc7ffe9-61d6-0310-9af1-9938baff3ed1>2006-12-18 12:32:48 +0000
commit6c6b1878f4e3b9b848f6329e98d27db7b99c212b (patch)
tree43386acccc982edd82cae447a6c495e6fb154ec8 /firmware/src/dfu
parent5200cf56dd9f0c698011c59b96abdb447a76ac1f (diff)
- add new DAC driver (instead of poti) for PICC
- DFU: put all DEBUG_ defines in "#ifdef DEBUG" enclosure - alter GPIO defines for new OpenPICC v0.4 prototype - add new AT91F_DBGU_Fini() function - take care of new inverted USB pullip in OpenPICC v0.4 prototype - fix typo in 'opicc_reg_write' macro - add some more PICC related SSC code NOTE: this firmware is the first version that will _NOT_ run on a OpenPICC v0.3 anymore! (All changes by Henryk Ploetz) git-svn-id: https://svn.openpcd.org:2342/trunk@283 6dc7ffe9-61d6-0310-9af1-9938baff3ed1
Diffstat (limited to 'firmware/src/dfu')
-rw-r--r--firmware/src/dfu/dfu.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/firmware/src/dfu/dfu.c b/firmware/src/dfu/dfu.c
index f5abe46..20778bd 100644
--- a/firmware/src/dfu/dfu.c
+++ b/firmware/src/dfu/dfu.c
@@ -42,8 +42,10 @@
* and therefore have to omit flashing */
//#define DEBUG_DFU_NOFLASH
+#ifdef DEBUG
#define DEBUG_DFU_EP0
//#define DEBUG_DFU_RECV
+#endif
#ifdef DEBUG_DFU_EP0
#define DEBUGE DEBUGP
@@ -78,7 +80,9 @@ static void __dfufunc udp_init(void)
/* Enable UDP PullUp (USB_DP_PUP) : enable & Clear of the
* corresponding PIO Set in PIO mode and Configure in Output */
+#if defined(PCD)
AT91F_PIO_CfgOutput(AT91C_BASE_PIOA, OPENPCD_PIO_UDP_PUP);
+#endif
AT91F_PIO_CfgOutput(AT91C_BASE_PIOA, OPENPCD_PIO_UDP_PUPv4);
}
@@ -899,7 +903,9 @@ void __dfufunc dfu_main(void)
/* End-of-Bus-Reset is always enabled */
/* Clear for set the Pull up resistor */
+#if defined(PCD)
AT91F_PIO_SetOutput(AT91C_BASE_PIOA, OPENPCD_PIO_UDP_PUP);
+#endif
AT91F_PIO_ClearOutput(AT91C_BASE_PIOA, OPENPCD_PIO_UDP_PUPv4);
flash_init();
personal git repositories of Harald Welte. Your mileage may vary