aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSelene ToyKeeper2017-03-18 18:52:09 -0600
committerSelene ToyKeeper2017-03-18 18:52:09 -0600
commitba71d216803199f6447f4f9ec309d3c89ef775a2 (patch)
treeb9f9cb45212e1af90bb9d2767a29b59f4fbfe213
parentAdded _delay_4ms() thing from new smaller biscotti. Will need it for crescendo. (diff)
downloadanduril-ba71d216803199f6447f4f9ec309d3c89ef775a2.tar.gz
anduril-ba71d216803199f6447f4f9ec309d3c89ef775a2.tar.bz2
anduril-ba71d216803199f6447f4f9ec309d3c89ef775a2.zip
Fixed LVP. Verified it works on FET+1 and attiny25. Added presets for MTN17DDm FET+1.
Moved FAST/PHASE definitions to tk-attiny.h. These are really a per-layout option so it's better there.
-rw-r--r--tk-attiny.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/tk-attiny.h b/tk-attiny.h
index 4058fea..98552e3 100644
--- a/tk-attiny.h
+++ b/tk-attiny.h
@@ -73,6 +73,9 @@
//#define TEMP_DIDR ADC4D
#define TEMP_CHANNEL 0b00001111
+#define FAST 0xA3 // fast PWM both channels
+#define PHASE 0xA1 // phase-correct PWM both channels
+
#endif // FET_7135_LAYOUT
#ifdef TRIPLEDOWN_LAYOUT
@@ -106,6 +109,9 @@
//#define TEMP_DIDR ADC4D
#define TEMP_CHANNEL 0b00001111
+#define FAST 0xA3 // fast PWM both channels
+#define PHASE 0xA1 // phase-correct PWM both channels
+
#endif // FET_7135_LAYOUT
#ifdef FERRERO_ROCHER_LAYOUT
@@ -118,6 +124,8 @@
* ----
*/
// TODO: fill in this section, update Ferrero_Rocher code to use it.
+#define FAST 0x23 // fast PWM channel 1 only
+#define PHASE 0x21 // phase-correct PWM channel 1 only
#endif // FERRERO_ROCHER_LAYOUT
#ifdef NANJG_LAYOUT
@@ -131,6 +139,10 @@
#define ADC_PRSCL 0x06 // clk/64
#define PWM_LVL OCR0B // OCR0B is the output compare register for PB1
+
+#define FAST 0x23 // fast PWM channel 1 only
+#define PHASE 0x21 // phase-correct PWM channel 1 only
+
#endif // NANJG_LAYOUT
#ifndef PWM_LVL
If you find this content useful please consider a small donation via bitcoin: bitcoin:1mxKyQsHHugqRxPKgwaA7wUwJEGCNthn2?amount=0.001&message=Donation Scraping git contents via cgit is very resource intensive. The continued hosting of these git repositories is entirely financed by your bitcoin contributions. For donations of a least 1 mBTC you include your IP address in the message of your bitcoin donation. This will remove this message in the future for requests from your IP, which will significantly reduce token usage. In any case, any contributions to bitcoin address 1mxKyQsHHugqRxPKgwaA7wUwJEGCNthn2 are very welcome. Thanks in advance for you contribution to a self-sustaining ecosystem.