Maxim Integrated / OneWire

Dependents:   MAXREFDES131_Qt_Demo MAX32630FTHR_iButton_uSD_Logger MAX32630FTHR_DS18B20_uSD_Logger MAXREFDES130_131_Demo ... more

Embed: (wiki syntax)

« Back to documentation index

DS2413 Class Reference

DS2413 1-Wire Dual Channel Addressable Switch. More...

#include <DS2413.h>

Inherits OneWire::OneWireSlave.

Public Types

enum  CmdResult
 

Result of operations.

More...

Public Member Functions

 DS2413 (RandomAccessRomIterator &selector)
 DS2413 constructor.
CmdResult pioAccessReadChA (uint8_t &val)
 pioAccessReadChA()
CmdResult pioAccessReadChB (uint8_t &val)
 pioAccessReadChB()
CmdResult pioAccessWriteChA (uint8_t val)
 pioAccessWriteChA()
CmdResult pioAccessWriteChB (uint8_t val)
 pioAccessWriteChB()
CmdResult pioAccessWriteChAB (uint8_t val)
 pioAccessWriteChAB()
RomId romId () const

Protected Member Functions

OneWireMaster::CmdResult selectDevice () const
 Select this slave device by ROM ID.
OneWireMastermaster () const
 The 1-Wire master for this slave device.

Detailed Description

DS2413 1-Wire Dual Channel Addressable Switch.

The DS2413 is a dual-channel programmable I/O 1-Wire® chip. The PIO outputs are configured as open-drain and provide up to 20mA continuous sink capability and off-state operating voltage up to 28V. Control and sensing of the PIO pins is performed with a dedicated device-level command protocol. To provide a high level of fault tolerance in the end application, the 1-Wire I/O and PIO pins are all capable of withstanding continuous application of voltages up to 28V max. Communication and operation of the DS2413 is performed with the single contact Maxim 1-Wire serial interface.

Definition at line 54 of file DS2413.h.


Member Enumeration Documentation

enum CmdResult

Result of operations.

Reimplemented from OneWireSlave.

Definition at line 59 of file DS2413.h.


Constructor & Destructor Documentation

DS2413 ( RandomAccessRomIterator selector )

DS2413 constructor.

On Entry:

Parameters:
[in]owm- reference to 1-wire master

On Exit:

Returns:

Definition at line 51 of file DS2413.cpp.


Member Function Documentation

OneWireMaster& master (  ) const [protected, inherited]

The 1-Wire master for this slave device.

Definition at line 77 of file OneWireSlave.h.

DS2413::CmdResult pioAccessReadChA ( uint8_t &  val )

pioAccessReadChA()

reads state of pio

On Exit:

Parameters:
[out]val- lsb represents the state of the pio
Returns:
CmdResult - result of operation

Definition at line 55 of file DS2413.cpp.

DS2413::CmdResult pioAccessReadChB ( uint8_t &  val )

pioAccessReadChB()

reads state of pio

On Exit:

Parameters:
[out]val- lsb represents the state of the pio
Returns:
CmdResult - result of operation

Definition at line 66 of file DS2413.cpp.

DS2413::CmdResult pioAccessWriteChA ( uint8_t  val )

pioAccessWriteChA()

writes to pio

On Entry:

Parameters:
[in]val- lsb sets state of pio
Returns:
CmdResult - result of operation

Definition at line 77 of file DS2413.cpp.

DS2413::CmdResult pioAccessWriteChAB ( uint8_t  val )

pioAccessWriteChAB()

writes to pio

On Entry:

Parameters:
[in]val- Bits 1:0 set PIOB and PIOB respectively
Returns:
CmdResult - result of operation

Definition at line 125 of file DS2413.cpp.

DS2413::CmdResult pioAccessWriteChB ( uint8_t  val )

pioAccessWriteChB()

writes to pio

On Entry:

Parameters:
[in]val- lsb sets state of pio
Returns:
CmdResult - result of operation

Definition at line 101 of file DS2413.cpp.

RomId romId (  ) const [inherited]

1-Wire ROM ID for this slave device.

Definition at line 59 of file OneWireSlave.h.

OneWireMaster::CmdResult selectDevice (  ) const [protected, inherited]

Select this slave device by ROM ID.

Definition at line 74 of file OneWireSlave.h.