An arduino library to communicate using the Dallas one-wire protocol, where the Arduino takes the role of a slave.
Implementation of a DS2413 on Arduino UNO and ATTINY85
You can not select more than 25 topicsTopics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ADMUX|=(1<<ADLAR);//left align the ADC value- so we can read highest 8 bits from ADCH register only
ADCSRA|=(1<<ADPS2)|(1<<ADPS1)|(1<<ADPS0);//set ADC clock with 128 prescaler- 16mHz/128=125kHz ; 13 cycles for a conversion which means 9600 samples per second
ADCSRA|=(1<<ADATE);//enabble auto trigger
ADCSRA|=(1<<ADIE);//enable interrupts when measurement complete