From cbc94b0f676207c1ab703dd85821452b51e6ed77 Mon Sep 17 00:00:00 2001 From: z-riley Date: Mon, 28 Oct 2024 16:02:41 +0000 Subject: [PATCH] Remove shadowed variable --- tic/tic.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tic/tic.go b/tic/tic.go index ff6c063..e627001 100644 --- a/tic/tic.go +++ b/tic/tic.go @@ -1107,8 +1107,7 @@ const ( // // The reading is less than about 2.4 V. // } func (d *Dev) GetAnalogReading(pin Pin) (uint16, error) { - offset := OffsetAnalogReadingSCL + 2*offset(pin) - return d.getVar16(offset) + return d.getVar16(OffsetAnalogReadingSCL + 2*offset(pin)) } // IsDigitalReading gets a digital reading from the specified pin.