Pyramid Technologies .NET RS-232 API  1.4.4.0
RS-232 Bill Acceptor API for Pyramid Bill Validators
PyramidNETRS232.PyramidAcceptor Class Reference

The main class that does the actual "talking" the acceptor. In the context of documentation, this object what is referred to as the master and the acceptor is the slave device. More...

Inheritance diagram for PyramidNETRS232.PyramidAcceptor:

Public Member Functions

 PyramidAcceptor (RS232Config config)
 Creates a new PyramidAcceptor using the specified configuration More...
 
void Dispose ()
 Releases comm port and related managed resources. More...
 
void Close ()
 Stop talking to the slave and release the underlying comm port. More...
 
void PauseAcceptance ()
 Disables the bill acceptor within the time period defined by the poll rate. The poll rate (RS232Config.PollRate, default 50 ms) is the maximum time between poll packets from master to slave. This command does not disconnect the serial port. Use Close() for that effect. This effectively tells the acceptor to stop accepting bill but keep reporting status. The acceptor's lights will turn off after this call takes effect.

See also
ResumeAcceptance
More...
 
void ResmeAcceptance ()
 Returns the acceptor to bill accepting mode. This command has no effect if the acceptor is already running and accepting. The acceptor's lights will turn on after this command takes effect. The command will take up to Config.PollRate ms to take effect.

See also
PauseAcceptance
More...
 
void ResumeAcceptance ()
 Returns the acceptor to bill accepting mode. This command has no effect if the acceptor is already running and accepting. The acceptor's lights will turn on after this command takes effect. The command will take up to Config.PollRate ms to take effect.

See also
PauseAcceptance
More...
 
void Connect ()
 Connect to the device and begin speaking rs232 More...
 
void RequestReset ()
 Sets flag to reset the acceptor on the next message sent More...
 
void Stack ()
 Issue a stack command to the acceptor. Note that the acceptor must be configured to escrow mode and the bill must be in escrow. Otherwise, calling this command has no effect other than logging an error message. More...
 
void Reject ()
 Issue a reject command to the acceptor. Note that the acceptor must be configured to escrow mode and the bill must be in escrow. Otherwise, calling this command has no effect other than logging an error message. More...
 

Static Public Member Functions

static List< string > GetAvailablePorts ()
 Returns a list of all available ports More...
 

Properties

States PreviousState [get]
 Slave's last state More...
 
Events PreviousEvents [get]
 Slave's last events More...
 
bool IsRunning [get]
 Returns true if the communication thread is running normally More...
 
RS232Config Config [get, set]
 Gets or sets the RS232 Configuration More...
 
bool IsPaused [get]
 Gets the current pause state. If the acceptor is running and at least 1 bill is enabled, the acceptor is not paused. Otherwise, the acceptor is considered paused. More...
 

Events

EventHandler< EventChangedArgsOnEvent
 Raised when the acceptor reports any event. Events are transient in that they are only reported once to the master. More...
 
EventHandler< StateChangedArgsOnStateChanged
 Raised when the acceptor reports a state that is different from the previously recorded state. Note: In escrow mode the Escrowed event will be raised as More...
 
EventHandler< ErrorArgsOnError
 Raised by the master in the event that communication fails More...
 
EventHandler< CreditArgsOnCredit
 Raised once a note has been successfully stacked. More...
 
EventHandler< EscrowArgsOnEscrow
 subscribe to this event to be notified of when and what denomination is in escrow. If you are running in escrow mode, you may then decide whether to stack or reject the note based upon the denomination. More...
 
EventHandler OnCashboxAttached
 Raised when the cashbox is no longer detached. This only be reported if the cashbox is first attached, then missing. More...
 
EventHandler< DebugEntryArgsOnSerialData
 Subscribe to serial data received and transmission events. Useful for debugging. More...
 

Detailed Description

The main class that does the actual "talking" the acceptor. In the context of documentation, this object what is referred to as the master and the acceptor is the slave device.

Definition at line 15 of file ApexValidator.cs.

Constructor & Destructor Documentation

◆ PyramidAcceptor()

PyramidNETRS232.PyramidAcceptor.PyramidAcceptor ( RS232Config  config)

Creates a new PyramidAcceptor using the specified configuration

Parameters
configOperating RS-232 parameters

Definition at line 37 of file ApexValidator.cs.

Member Function Documentation

◆ Close()

void PyramidNETRS232.PyramidAcceptor.Close ( )

Stop talking to the slave and release the underlying comm port.

Do not use this to disable the bill acceptor: use PauseAcceptance()

Definition at line 116 of file ApexValidator.cs.

◆ Connect()

void PyramidNETRS232.PyramidAcceptor.Connect ( )

Connect to the device and begin speaking rs232

Definition at line 187 of file ApexValidator.cs.

◆ Dispose()

void PyramidNETRS232.PyramidAcceptor.Dispose ( )

Releases comm port and related managed resources.

Definition at line 96 of file ApexValidator.cs.

◆ GetAvailablePorts()

static List<string> PyramidNETRS232.PyramidAcceptor.GetAvailablePorts ( )
static

Returns a list of all available ports

Returns

Definition at line 106 of file ApexValidator.cs.

◆ PauseAcceptance()

void PyramidNETRS232.PyramidAcceptor.PauseAcceptance ( )

Disables the bill acceptor within the time period defined by the poll rate. The poll rate (RS232Config.PollRate, default 50 ms) is the maximum time between poll packets from master to slave. This command does not disconnect the serial port. Use Close() for that effect. This effectively tells the acceptor to stop accepting bill but keep reporting status. The acceptor's lights will turn off after this call takes effect.

See also
ResumeAcceptance

Definition at line 138 of file ApexValidator.cs.

◆ Reject()

void PyramidNETRS232.PyramidAcceptor.Reject ( )

Issue a reject command to the acceptor. Note that the acceptor must be configured to escrow mode and the bill must be in escrow. Otherwise, calling this command has no effect other than logging an error message.

Definition at line 28 of file Commands.cs.

◆ RequestReset()

void PyramidNETRS232.PyramidAcceptor.RequestReset ( )

Sets flag to reset the acceptor on the next message sent

Definition at line 233 of file ApexValidator.cs.

◆ ResmeAcceptance()

void PyramidNETRS232.PyramidAcceptor.ResmeAcceptance ( )

Returns the acceptor to bill accepting mode. This command has no effect if the acceptor is already running and accepting. The acceptor's lights will turn on after this command takes effect. The command will take up to Config.PollRate ms to take effect.

See also
PauseAcceptance

Definition at line 157 of file ApexValidator.cs.

◆ ResumeAcceptance()

void PyramidNETRS232.PyramidAcceptor.ResumeAcceptance ( )

Returns the acceptor to bill accepting mode. This command has no effect if the acceptor is already running and accepting. The acceptor's lights will turn on after this command takes effect. The command will take up to Config.PollRate ms to take effect.

See also
PauseAcceptance

Definition at line 174 of file ApexValidator.cs.

◆ Stack()

void PyramidNETRS232.PyramidAcceptor.Stack ( )

Issue a stack command to the acceptor. Note that the acceptor must be configured to escrow mode and the bill must be in escrow. Otherwise, calling this command has no effect other than logging an error message.

Definition at line 10 of file Commands.cs.

Property Documentation

◆ Config

RS232Config PyramidNETRS232.PyramidAcceptor.Config
getset

Gets or sets the RS232 Configuration

Definition at line 83 of file ApexValidator.cs.

◆ IsPaused

bool PyramidNETRS232.PyramidAcceptor.IsPaused
get

Gets the current pause state. If the acceptor is running and at least 1 bill is enabled, the acceptor is not paused. Otherwise, the acceptor is considered paused.

Definition at line 91 of file ApexValidator.cs.

◆ IsRunning

bool PyramidNETRS232.PyramidAcceptor.IsRunning
get

Returns true if the communication thread is running normally

Definition at line 78 of file ApexValidator.cs.

◆ PreviousEvents

Events PyramidNETRS232.PyramidAcceptor.PreviousEvents
get

Slave's last events

Definition at line 73 of file ApexValidator.cs.

◆ PreviousState

States PyramidNETRS232.PyramidAcceptor.PreviousState
get

Slave's last state

Definition at line 68 of file ApexValidator.cs.

Event Documentation

◆ OnCashboxAttached

EventHandler PyramidNETRS232.PyramidAcceptor.OnCashboxAttached

Raised when the cashbox is no longer detached. This only be reported if the cashbox is first attached, then missing.

Definition at line 94 of file Events.cs.

◆ OnCredit

EventHandler<CreditArgs> PyramidNETRS232.PyramidAcceptor.OnCredit

Raised once a note has been successfully stacked.

Definition at line 60 of file Events.cs.

◆ OnError

EventHandler<ErrorArgs> PyramidNETRS232.PyramidAcceptor.OnError

Raised by the master in the event that communication fails

Definition at line 45 of file Events.cs.

◆ OnEscrow

EventHandler<EscrowArgs> PyramidNETRS232.PyramidAcceptor.OnEscrow

subscribe to this event to be notified of when and what denomination is in escrow. If you are running in escrow mode, you may then decide whether to stack or reject the note based upon the denomination.

Definition at line 77 of file Events.cs.

◆ OnEvent

EventHandler<EventChangedArgs> PyramidNETRS232.PyramidAcceptor.OnEvent

Raised when the acceptor reports any event. Events are transient in that they are only reported once to the master.

Definition at line 12 of file Events.cs.

◆ OnSerialData

EventHandler<DebugEntryArgs> PyramidNETRS232.PyramidAcceptor.OnSerialData

Subscribe to serial data received and transmission events. Useful for debugging.

Definition at line 100 of file Events.cs.

◆ OnStateChanged

EventHandler<StateChangedArgs> PyramidNETRS232.PyramidAcceptor.OnStateChanged

Raised when the acceptor reports a state that is different from the previously recorded state. Note: In escrow mode the Escrowed event will be raised as

Definition at line 29 of file Events.cs.


The documentation for this class was generated from the following files: