tm3d
/
owSlave2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
- OWINIT save Register used in C
[owSlave2.git]
/
DS2423
/
DS2423.c
diff --git
a/DS2423/DS2423.c
b/DS2423/DS2423.c
index
73cb3b6
..
89b07db
100644
(file)
--- a/
DS2423/DS2423.c
+++ b/
DS2423/DS2423.c
@@
-32,8
+32,8
@@
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define _4_COUNTERS_
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define _4_COUNTERS_
-#define _EEPROM_SAVE_
-
//
#define _CPULLUP_
+
//
#define _EEPROM_SAVE_
+#define _CPULLUP_
#define F_CPU 8000000UL
#include <avr/io.h>
#define F_CPU 8000000UL
#include <avr/io.h>
@@
-155,10
+155,10
@@
int main(void){
OWINIT();
pack.zero=0;
OWINIT();
pack.zero=0;
- counters.c32[0]=
223433
;
- counters.c32[2]=
233
;
- counters.c32[1]=
3433
;
- counters.c32[3]=
22433
;
+ counters.c32[0]=
0
;
+ counters.c32[2]=
0
;
+ counters.c32[1]=
0
;
+ counters.c32[3]=
0
;
ACSR|=(1<<ACD); //Disable Comparator
ADCSRB|=(1<<ACME); //Disable Analog multiplexer
MCUCR &=~(1<<PUD); //All Pins Pullup...
ACSR|=(1<<ACD); //Disable Comparator
ADCSRB|=(1<<ACME); //Disable Analog multiplexer
MCUCR &=~(1<<PUD); //All Pins Pullup...
@@
-215,6
+215,8
@@
int main(void){
|(1<<PCINT6)|(1<<PCINT7)
#endif
;
|(1<<PCINT6)|(1<<PCINT7)
#endif
;
+
+
#ifdef _EEPROM_SAVE_
DDRA&=~(1<<PINA0);
PCMSK0|=(1<<PCINT0);
#ifdef _EEPROM_SAVE_
DDRA&=~(1<<PINA0);
PCMSK0|=(1<<PCINT0);