diff --git a/prog/detect/detect.pl b/prog/detect/detect.pl index 39fbb3cc..1d03d2dd 100755 --- a/prog/detect/detect.pl +++ b/prog/detect/detect.pl @@ -799,6 +799,10 @@ sub add_isa_to_chips_detected print("Can't open ", "/dev/i2c-$new_misdetected_ref->[$j]->{devnr}?!?\n"), next; + i2c_set_slave_addr \*FILE,$new_misdetected_ref->[$j]->{address} or + print("Can't set I2C address for ", + "/dev/i2c-$new_misdetected_ref->[$j]->{devnr}?!?\n"), + next; if (&$alias_detect ($datahash->{isa_addr},\*FILE, $new_misdetected_ref->[$j]->{address})) { $new_misdetected_ref->[$j]->{isa_addr} = $datahash->{isa_addr}; @@ -816,6 +820,10 @@ sub add_isa_to_chips_detected print("Can't open ", "/dev/i2c-$new_detected_ref->[$j]->{devnr}?!?\n"), next; + i2c_set_slave_addr \*FILE,$new_detected_ref->[$j]->{address} or + print("Can't set I2C address for ", + "/dev/i2c-$new_detected_ref->[$j]->{devnr}?!?\n"), + next; if (&$alias_detect ($datahash->{isa_addr},\*FILE, $new_detected_ref->[$j]->{address})) { $new_detected_ref->[$j]->{isa_addr} = $datahash->{isa_addr}; diff --git a/prog/detect/sensors-detect b/prog/detect/sensors-detect index 39fbb3cc..1d03d2dd 100755 --- a/prog/detect/sensors-detect +++ b/prog/detect/sensors-detect @@ -799,6 +799,10 @@ sub add_isa_to_chips_detected print("Can't open ", "/dev/i2c-$new_misdetected_ref->[$j]->{devnr}?!?\n"), next; + i2c_set_slave_addr \*FILE,$new_misdetected_ref->[$j]->{address} or + print("Can't set I2C address for ", + "/dev/i2c-$new_misdetected_ref->[$j]->{devnr}?!?\n"), + next; if (&$alias_detect ($datahash->{isa_addr},\*FILE, $new_misdetected_ref->[$j]->{address})) { $new_misdetected_ref->[$j]->{isa_addr} = $datahash->{isa_addr}; @@ -816,6 +820,10 @@ sub add_isa_to_chips_detected print("Can't open ", "/dev/i2c-$new_detected_ref->[$j]->{devnr}?!?\n"), next; + i2c_set_slave_addr \*FILE,$new_detected_ref->[$j]->{address} or + print("Can't set I2C address for ", + "/dev/i2c-$new_detected_ref->[$j]->{devnr}?!?\n"), + next; if (&$alias_detect ($datahash->{isa_addr},\*FILE, $new_detected_ref->[$j]->{address})) { $new_detected_ref->[$j]->{isa_addr} = $datahash->{isa_addr};