mirror of https://github.com/wb2osz/direwolf.git
scripts/telemetry-toolkit/telem-volts.py: Port to python3
This commit is contained in:
parent
8ac14f86f5
commit
a30f90956b
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/python
|
#!/usr/bin/python3
|
||||||
|
|
||||||
# Part of Dire Wolf APRS Telemetry Toolkit, WB2OSZ, 2015
|
# Part of Dire Wolf APRS Telemetry Toolkit, WB2OSZ, 2015
|
||||||
|
|
||||||
|
@ -33,4 +33,4 @@ volts = adc.readADCSingleEnded(0, gain, sps) * 0.001 * (r1+r2) / r2
|
||||||
# (multiply by expected value, divide by uncalibrated result.)
|
# (multiply by expected value, divide by uncalibrated result.)
|
||||||
#volts = volts * 4.98 / 4.889
|
#volts = volts * 4.98 / 4.889
|
||||||
|
|
||||||
print "%.3f" % (volts)
|
print("%.3f" % (volts))
|
||||||
|
|
Loading…
Reference in New Issue