mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-12 12:06:58 +00:00
Use joinData methods to set offset to get joins in the right spot
This commit is contained in:
parent
9526b9b6fe
commit
8a98924ad7
1 changed files with 12 additions and 9 deletions
|
|
@ -61,17 +61,20 @@ namespace PepperDash_Essentials_Core.Devices
|
|||
|
||||
for (uint i = 0; i < _port.IrFileCommands.Length; i++)
|
||||
{
|
||||
joinMap.Joins.Add(_port.IrFileCommands[i],
|
||||
new JoinDataComplete(new JoinData {JoinNumber = i + joinStart, JoinSpan = 1},
|
||||
var joinData = new JoinDataComplete(new JoinData {JoinNumber = i + joinStart, JoinSpan = 1},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = _port.IrFileCommands[i],
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
}));
|
||||
});
|
||||
|
||||
joinData.SetJoinOffset(joinStart);
|
||||
|
||||
joinMap.Joins.Add(_port.IrFileCommands[i],joinData);
|
||||
|
||||
var index = i;
|
||||
trilist.SetBoolSigAction(i + joinStart, (b) => Press(_port.IrFileCommands[index], b));
|
||||
trilist.SetBoolSigAction(joinData.JoinNumber, (b) => Press(_port.IrFileCommands[index], b));
|
||||
}
|
||||
|
||||
if (bridge != null)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue