Open Model Railroad Network (OpenMRN)
Loading...
Searching...
No Matches
MultiConfiguredPC.hxx File Reference

Go to the source code of this file.

Classes

class  openlcb::MultiConfiguredPC
 

Namespaces

namespace  openlcb
 

Enumerations

enum class  ActionConfig : uint8_t { DOUTPUT = 0 , DINPUT = 1 }
 

Functions

 openlcb::CDI_GROUP (PCLineConfig)
 
 openlcb::CDI_GROUP_ENTRY (description, StringConfigEntry< 20 >, Name("Description"), Description("User name of this line."))
 Allows the user to assign a name for this output.
 
 openlcb::CDI_GROUP_ENTRY (event_on, EventConfigEntry, Name("Event On"), Description("This event ID will turn the output on / be produced when the " "input goes on."))
 Specifies the event ID to set the output to ON.
 
 openlcb::CDI_GROUP_ENTRY (event_off, EventConfigEntry, Name("Event Off"), Description("This event ID will turn the output off / be produced when the " "input goes off."))
 Specifies the event ID to set the output to OFF.
 
 openlcb::CDI_GROUP_END ()
 Signals termination of the group.
 
 openlcb::CDI_GROUP (PCConfig)
 CDI Configuration for a ConfiguredConsumer.
 
 openlcb::CDI_GROUP_ENTRY (action, Uint8ConfigEntry, Default(1), MapValues(PC_ACTION_MAP), Name("Configuration"))
 
 openlcb::CDI_GROUP_ENTRY (debounce, Uint8ConfigEntry, Name("Debounce parameter"), Default(3), Description("Used for inputs only. Amount of time to wait for the input to " "stabilize before " "producing the event. Unit is 30 msec of time. Usually a value " "of 2-3 works well in a non-noisy environment. In high noise " "(train wheels for example) a setting between 8 -- 15 makes " "for a slower response time but a more stable " "signal.\nFormally, the parameter tells how many times of " "tries, each 30 msec apart, the input must have the same value " "in order for that value to be accepted and the event " "transition produced."), Default(3))
 Configures the debounce parameter.
 
 openlcb::CDI_GROUP_ENTRY (unused, EmptyGroup< 1 >)
 
 openlcb::CDI_GROUP_ENTRY (pc, PCLineConfig)
 

Variables

static const char openlcb::PC_ACTION_MAP []
 

Detailed Description

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  • Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  • Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Producer-Consumer class that uses CDI configuration and many GPIO pins to export a multiple of configurable input or output pins.

Author
Balazs Racz
Date
28 Oct 2018

Definition in file MultiConfiguredPC.hxx.