use /dev/serial/by-path/
[air-quality] / mh-z19b.pl
index 94abb05..c2f8ffe 100755 (executable)
@@ -6,8 +6,7 @@ use Device::SerialPort;
 use Time::HiRes;
 use Data::Dump qw(dump);
 
-my $port = shift @ARGV || '/dev/ttyUSB0';
-$port = '/dev/ttyUSB5';
+my $port = shift @ARGV || '/dev/serial/by-path/pci-0000:00:1a.7-usb-0:5.3.4:1.2';
 my $influx_url = shift @ARGV || 'http://10.13.37.229:8186/write?db=telegraf';
 $influx_url = 'http://10.13.37.92:8086/write?db=rot13';