Modbus.PumpFM.DanfossVLT.Pump.Initialize( ) modification : modbus.ComponentNames[pumpCfg.ModbusAddress] = Name;
This commit is contained in:
@@ -118,7 +118,7 @@ namespace TBF.Rig.Modbus.PumpFM.DanfossVLT
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
readonly GenericDevices.IModbus modbus;
|
readonly Common.Modbus modbus;
|
||||||
readonly IControlBoard controlBoard;
|
readonly IControlBoard controlBoard;
|
||||||
int bitNr; /// 0 .. 63
|
int bitNr; /// 0 .. 63
|
||||||
public UInt128 Mask; /// derived from bitPosition in the constructor
|
public UInt128 Mask; /// derived from bitPosition in the constructor
|
||||||
@@ -137,7 +137,7 @@ namespace TBF.Rig.Modbus.PumpFM.DanfossVLT
|
|||||||
{
|
{
|
||||||
pumpCfg = cfg as PumpCfg;
|
pumpCfg = cfg as PumpCfg;
|
||||||
|
|
||||||
modbus = (GenericDevices.IModbus)TbfComponents.FindComponent(cfg.ParentName, components);
|
modbus = TbfComponents.FindComponent(cfg.ParentName, components) as Common.Modbus;
|
||||||
if (modbus == null) throw new Exception("Cannot find " + Name + " parent");
|
if (modbus == null) throw new Exception("Cannot find " + Name + " parent");
|
||||||
|
|
||||||
controlBoard = null;
|
controlBoard = null;
|
||||||
@@ -158,6 +158,7 @@ namespace TBF.Rig.Modbus.PumpFM.DanfossVLT
|
|||||||
{
|
{
|
||||||
bitNr = pumpCfg.BitNr;
|
bitNr = pumpCfg.BitNr;
|
||||||
Mask = (((UInt128)1) << bitNr);
|
Mask = (((UInt128)1) << bitNr);
|
||||||
|
modbus.ComponentNames[pumpCfg.ModbusAddress] = Name;
|
||||||
|
|
||||||
TBF.UiBridge.Bridge.SetpointChangeHandler += delegate(object sndr, TBF.UiBridge.SetpointChangeArgs args)
|
TBF.UiBridge.Bridge.SetpointChangeHandler += delegate(object sndr, TBF.UiBridge.SetpointChangeArgs args)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user