Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get away from master/slave terminology #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions devices/eurotherm_2404.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class eurotherm_2404( minimalmodbus.Instrument ):

Args:
* portname (str): port name
* slaveaddress (int): slave address in the range 1 to 247
* subordinateaddress (int): subordinate address in the range 1 to 247

Implemented with these function codes (in decimal):

Expand All @@ -57,7 +57,7 @@ class eurotherm_2404( minimalmodbus.Instrument ):

"""

def __init__(self, portname, slaveaddress=1):
def __init__(self, portname, subordinateaddress=1):
self.oven_name = str(portname)
self.oven_constant = 0.000078 # default value
if "/" not in portname: # means instead of a serial port name, a pseudoname has been used
Expand All @@ -69,7 +69,7 @@ def __init__(self, portname, slaveaddress=1):
self.oven_constant = 0
self.oven_name = ""
sys.exit("No furnace with the name: \""+str(portname)+"\" has been found. Is the controller really Eurotherm 2404? Don't you think it's a Eurotherm 2416 or 3216? Either use a correct pseudoname or address the serial port directly (See manual)")
minimalmodbus.Instrument.__init__(self, portname, slaveaddress=1)
minimalmodbus.Instrument.__init__(self, portname, subordinateaddress=1)
self.room_temperature = 23
print "###########################################################################"
print " "+self.oven_name+" (with id: "+str(self.get_id())+")"
Expand Down
6 changes: 3 additions & 3 deletions devices/eurotherm_2416.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class eurotherm_2416( minimalmodbus.Instrument ):

Args:
* portname (str): port name
* slaveaddress (int): slave address in the range 1 to 247
* subordinateaddress (int): subordinate address in the range 1 to 247

Implemented with these function codes (in decimal):

Expand All @@ -50,7 +50,7 @@ class eurotherm_2416( minimalmodbus.Instrument ):

"""

def __init__(self, portname, slaveaddress=1):
def __init__(self, portname, subordinateaddress=1):
self.oven_name = str(portname)
self.oven_constant = 0.000078 # default value
if "/" not in portname: # means instead of a serial port name, a pseudoname has been used
Expand All @@ -66,7 +66,7 @@ def __init__(self, portname, slaveaddress=1):
self.oven_constant = 0
self.oven_name = ""
sys.exit("No furnace with the name: \""+str(portname)+"\" has been found. Is the controller really Eurotherm 2416? Don't you think it's a Eurotherm 3216? Either use a correct pseudoname or address the serial port directly (See manual)")
minimalmodbus.Instrument.__init__(self, portname, slaveaddress=1)
minimalmodbus.Instrument.__init__(self, portname, subordinateaddress=1)
self.room_temperature = 23
print "###########################################################################"
print " "+self.oven_name+" (with id: "+str(self.get_id())+")"
Expand Down
6 changes: 3 additions & 3 deletions devices/eurotherm_3216.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class eurotherm_3216( minimalmodbus.Instrument ):

Args:
* portname (str): port name
* slaveaddress (int): slave address in the range 1 to 247
* subordinateaddress (int): subordinate address in the range 1 to 247

Implemented with these function codes (in decimal):

Expand All @@ -51,7 +51,7 @@ class eurotherm_3216( minimalmodbus.Instrument ):

"""

def __init__(self, portname, slaveaddress=1):
def __init__(self, portname, subordinateaddress=1):
self.oven_name = str(portname)
self.oven_constant = 0.000078 # default value
if "/" not in portname: # means instead of a serial port name, a pseudoname has been used
Expand Down Expand Up @@ -91,7 +91,7 @@ def __init__(self, portname, slaveaddress=1):
self.oven_constant = 0
self.oven_name = "unknown oven"
sys.exit("No furnace with the name: \""+str(portname)+"\" has been found. Is the controller really Eurotherm 3216? Don't you think it's a Eurotherm 2416? Either use a correct pseudoname or address the serial port directly (See manual)")
minimalmodbus.Instrument.__init__(self, portname, slaveaddress=1)
minimalmodbus.Instrument.__init__(self, portname, subordinateaddress=1)
self.room_temperature = 23
print "###########################################################################"
print " "+self.oven_name+" (with id: "+str(self.get_id())+")"
Expand Down
6 changes: 3 additions & 3 deletions devices/eurotherm_3500.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class eurotherm_3500( minimalmodbus.Instrument ):

Args:
* portname (str): port name
* slaveaddress (int): slave address in the range 1 to 247
* subordinateaddress (int): subordinate address in the range 1 to 247

Implemented with these function codes (in decimal):

Expand All @@ -57,8 +57,8 @@ class eurotherm_3500( minimalmodbus.Instrument ):

"""

def __init__(self, portname, slaveaddress=1):
minimalmodbus.Instrument.__init__(self, portname, slaveaddress=1)
def __init__(self, portname, subordinateaddress=1):
minimalmodbus.Instrument.__init__(self, portname, subordinateaddress=1)
self.room_temperature = 23
## Process value

Expand Down
6 changes: 3 additions & 3 deletions devices/eurotherm_nanodac.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class eurotherm_nanodac( minimalmodbus.Instrument ):

Args:
* portname (str): port name
* slaveaddress (int): slave address in the range 1 to 247
* subordinateaddress (int): subordinate address in the range 1 to 247

Implemented with these function codes (in decimal):

Expand All @@ -41,8 +41,8 @@ class eurotherm_nanodac( minimalmodbus.Instrument ):

"""

def __init__(self, portname, slaveaddress=1):
minimalmodbus.Instrument.__init__(self, portname, slaveaddress)
def __init__(self, portname, subordinateaddress=1):
minimalmodbus.Instrument.__init__(self, portname, subordinateaddress)
self.room_temperature = 23

## Process value
Expand Down
Loading