Class CipBackplane
- java.lang.Object
-
- com.automation_pros.odva.cip.application.CipBackplane
-
public class CipBackplane extends java.lang.Object
CIP devices may have a backplane/chassis in their design. The specification requires that a device's port #1, if it exists, be the backplane port. If multiple backplanes exist in a device's design, one of them must be port 1. The others can use any port number.When a device creates LocalBusPort in a Port Manager, it passes the bus instance for the chassis and the slot number to occupy. That constructor will fail if the slot is not available.
-
-
Constructor Summary
Constructors Constructor Description CipBackplane(EKeySeg chassisId, int minSlot, int maxSlot)
Establish the bus with an identity and fixed range of slot numbers.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
checkPort(LocalBusPort p)
protected void
checkSlot(int n)
EKeySeg
getChassisId()
java.util.List<CipDevice>
getDevices()
int
getMaxSlot()
int
getMinSlot()
CipUINT
getPortRange()
LocalBusPort
getSlot(int n)
void
setupSlot(int n, LocalBusPort p)
Place a given LocalBusPort in the given slot of this bus.void
teardownSlot(int n, LocalBusPort p)
Utility to remove a LocalBusPort from a slot when that port is shutting down.
-
-
-
Field Detail
-
chassisId
protected final EKeySeg chassisId
-
minSlot
protected final int minSlot
-
maxSlot
protected final int maxSlot
-
portRange
protected final CipUINT portRange
-
bus
protected final LocalBusPort[] bus
-
-
Constructor Detail
-
CipBackplane
public CipBackplane(EKeySeg chassisId, int minSlot, int maxSlot)
Establish the bus with an identity and fixed range of slot numbers.A LocalBusPort instance will defer to its bus to supply these properties to attribute reads.
- Parameters:
chassisId
-minSlot
-maxSlot
-
-
-
Method Detail
-
getChassisId
public EKeySeg getChassisId()
-
getMinSlot
public int getMinSlot()
-
getMaxSlot
public int getMaxSlot()
-
getPortRange
public CipUINT getPortRange()
-
checkSlot
protected void checkSlot(int n)
-
getSlot
public LocalBusPort getSlot(int n)
-
getDevices
public java.util.List<CipDevice> getDevices()
-
checkPort
protected void checkPort(LocalBusPort p)
-
setupSlot
public void setupSlot(int n, LocalBusPort p)
Place a given LocalBusPort in the given slot of this bus. Called only from theLocalBusPort
constructor.- Parameters:
n
-p
-
-
teardownSlot
public void teardownSlot(int n, LocalBusPort p)
Utility to remove a LocalBusPort from a slot when that port is shutting down. Only called fromLocalBusPort.shutdown()
.- Parameters:
n
-p
-
-
-