From: Tobias Date: Thu, 13 Apr 2017 10:57:05 +0000 (+0200) Subject: Clean Simple Counter DS2423 X-Git-Url: https://git.smho.de/?a=commitdiff_plain;h=59518e632e2269fece0ce6a518e519b3a617ad16;p=owSlave2.git Clean Simple Counter DS2423 --- diff --git a/DS2423/DS2423.c b/DS2423/DS2423.c index ccc2d30..6a37778 100644 --- a/DS2423/DS2423.c +++ b/DS2423/DS2423.c @@ -32,7 +32,6 @@ // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #define _4_COUNTERS_ -//#define _EEPROM_SAVE_ #define _CPULLUP_ #define F_CPU 8000000UL @@ -43,13 +42,6 @@ #include -#if defined(__AVR_ATtiny25__)||defined(__AVR_ATtiny45__) || defined(__AVR_ATtiny85__) - -#if defined(_4_COUNTERS_)&&defined(_EEPROM_SAVE_) -#error on ATtinyX5 you can not enable four counters and EEPROM save -#endif -#endif - extern void OWINIT(); @@ -91,20 +83,6 @@ volatile counters_t counters; volatile uint8_t istat; -#if defined(__AVR_ATtiny25__)||defined(__AVR_ATtiny45__) || defined(__AVR_ATtiny85__) -#define PCINT_VECTOR PCINT0_vect -#define PIN_REG PINB -#define PIN_DDR DDRB -#define PIN_CH2 (1<2 1 - - - - - - - - - - + + + + + + + + + + com.atmel.avrdbg.tool.atmelice diff --git a/common/OWDS2423.S b/common/OWDS2423.S index 32be7dc..32b4156 100644 --- a/common/OWDS2423.S +++ b/common/OWDS2423.S @@ -38,7 +38,7 @@ #include "../common/OWCRC16.s" .extern pack,45 -.extern counters,8 +.extern counters,16 .macro CHIP_INIT .endm