2 using System.Collections.Generic;
15 #region IAutoConfigOutputController Member
23 const int UnitBias = 50;
24 List<int> Preconfigured =
new List<int>(Cabinet.
OutputControllers.Where(OC => OC is
Pinscape).Select(PS => ((Pinscape)PS).Number));
25 IEnumerable<int> Numbers = Pinscape.AllDevices().Select(d => d.UnitNo());
26 foreach (
int N
in Numbers)
28 if (!Preconfigured.Contains(N))
34 Log.
Write(
"Detected and added Pinscape Controller Nr. {0} with name {1}".Build(p.
Number, p.
Name));
40 LWE.
Name =
"{0} Equivalent".Build(p.
Name);
51 Log.
Write(
"Added LedwizEquivalent Nr. {0} with name {1} for Pinscape Controller Nr. {2}".Build(
The Cabinet object describes the parts of a pinball cabinet (toys, outputcontrollers, outputs and more).
Interface for classes used to automatically detect and configure output controllers ...
The namespace DirectOutput.Cab.Toys contains all toy related classes.
This class is used to detect and configure Pinscape output controllers automatically.
LedWizEquivalentOutputList Outputs
Gets or sets the outputs of the LedWizEquivalent toy.
bool Contains(string Name)
Checks if a INamedItem object with the specified name exists in the list.
void AutoConfig(Cabinet Cabinet)
This method detects and configures Pinscape output controllers automatically.
DirectOutput.Cab.Toys.ToyList Toys
List of IToy objects describing the toys in the cabinet.
static void Write(string Message)
Writes the specified message to the logfile.
A simple logger used to record important events and exceptions.
Out.OutputControllerList OutputControllers
List of IOutputController objects representing the output controllers in the cabinet.
The namespace DirectOutput.Cab contains all cabinet related classes like the Cabinet class itself...
The LEDWizEquivalent toy is only used by the framework when ini files are used for the configuration ...
int LedWizNumber
Gets or sets the number of the virtual LedWiz resp. ini file to be matched with the LedWizEquivalentT...
new string Name
Gets or sets the Name of the IToy.
LEDWizEquivalentOutput is the output object for the LedWizEquivalent IToy.
The Pinscape Controller is an open-source software/hardware project based on the inexpensive and powe...
int Number
Gets or sets the unit number of the controller. The unit number must be unique. Setting changes the...
string Name
Name of the named item. Triggers BeforeNameChange before a new Name is set. Triggers AfterNameChang...