avr: allow 32-bit meterconstants for pulse inputs
This commit is contained in:
parent
c8e1cd6975
commit
c0543f206d
|
@ -70,7 +70,7 @@ ISR(PCINT2_vect) {
|
||||||
}
|
}
|
||||||
**/
|
**/
|
||||||
|
|
||||||
void pulse_add(volatile struct sensor *measurement, volatile struct state *aux, uint8_t pulse_const, uint8_t pulse_half) {
|
void pulse_add(volatile struct sensor *measurement, volatile struct state *aux, uint32_t pulse_const, uint32_t pulse_half) {
|
||||||
measurement->value += pulse_const;
|
measurement->value += pulse_const;
|
||||||
|
|
||||||
if (aux->half == true) {
|
if (aux->half == true) {
|
||||||
|
|
|
@ -141,5 +141,5 @@ struct sensor {
|
||||||
// prototypes
|
// prototypes
|
||||||
void WDT_off(void);
|
void WDT_off(void);
|
||||||
void WDT_on(void);
|
void WDT_on(void);
|
||||||
void pulse_add(volatile struct sensor *measurement, volatile struct state *aux, uint8_t pulse_const, uint8_t pulse_half);
|
void pulse_add(volatile struct sensor *measurement, volatile struct state *aux, uint32_t pulse_const, uint32_t pulse_half);
|
||||||
void send(uint8_t msg_type, const struct sensor *measurement, const struct state *aux);
|
void send(uint8_t msg_type, const struct sensor *measurement, const struct state *aux);
|
||||||
|
|
Loading…
Reference in New Issue