#include <LOW_devDS2405.h>
Inheritance diagram for LOW_devDS2405:
Public Types | |
typedef std::vector< LOW_devDS2405 * > | devDS2405PtrVec_t |
Vector type of class device pointers. | |
typedef std::vector< LOW_device * > | devPtrVec_t |
Vector type of class device pointers. | |
typedef std::map< LOW_deviceID, LOW_device * > | deviceMap_t |
Map type of devices with LOW_deviceID as key. | |
Public Member Functions | |
class_DERIVE_FROM_EXCEPTION (devDS2405_error, LOW_exception) | |
Exception base class for all exceptions thrown by LOW_devDS2405. | |
LOW_devDS2405 (LOW_netSegment &inSegment, const LOW_deviceID &inDevID) | |
Real constructor corresponding to static pseudo constructor new_Instance(). | |
virtual | ~LOW_devDS2405 () |
Destructor. | |
virtual const LOW_deviceIDRaw::devFamCode_t | getFamilyCode () const |
Get the device's family code. | |
virtual const std::string | getFamilyName () const |
Get the device's family name. | |
virtual void | cmd_Match () const |
Toggle the state of the PIO pin. | |
virtual bool | cmd_MatchRead () const |
Toggle the state of the PIO pin and read its new state. | |
virtual bool | cmd_SearchRead () const |
Read the logic state of the PIO pin (input). | |
virtual bool | cmd_SearchActive () const |
Read if the output pulldown is turned on. | |
virtual LOW_deviceID | getID () const |
Get the device's ROM ID. | |
virtual LOW_netSegment & | getNetSegment () const |
Get the network segment the device is on. | |
virtual bool | verifyDevice (const bool inOnlyAlarm=false, const bool inDoReset=true) const |
Shortcut method to verify the presence of the device on it's network segment. | |
Static Public Attributes | |
const LOW_deviceIDRaw::devFamCode_t | familyCode = 0x05 |
Family code of this specific device. | |
const std::string | familyName = "DS2405" |
Family name of this specific device. | |
const LOW_deviceIDRaw::devFamCode_t | anyDev_famCode = 0x00 |
Pseudo family code for selecting any/all device types. | |
const LOW_deviceIDRaw::devFamCode_t | unknownDev_famCode = 0xff |
Pseudo family code for unknown device types. | |
const owCommand_t | MatchROM_COMMAND = 0x55 |
1-Wire command byte constant | |
const owCommand_t | ReadROM_COMMAND = 0x33 |
1-Wire command byte constant | |
const owCommand_t | SkipROM_COMMAND = 0xcc |
1-Wire command byte constant | |
const owCommand_t | SearchROM_COMMAND = 0xf0 |
1-Wire command byte constant | |
const owCommand_t | SearchAlarmROM_COMMAND = 0xec |
1-Wire command byte constant | |
Protected Member Functions | |
virtual LOW_link & | getLink () const |
Get the link the device is on. | |
virtual void | cmd_MatchROM () const |
Shortcut for issuing a matchROM command for a device. | |
Static Protected Member Functions | |
LOW_device * | new_Instance (LOW_netSegment &inNetSegment, const LOW_deviceID &inDevID) |
Static pseudo constructor for registering with LOW_deviceFactory. | |
Protected Attributes | |
const LOW_deviceID | ID |
1-Wire ROM ID of the device | |
LOW_netSegment & | netSegment |
Network segment where the device is located. | |
Static Private Member Functions | |
int | initialize () |
Static inizializer to register the class with LOW_deviceFactory. | |
Static Private Attributes | |
int | initHelper = initialize() |
Needed for dirty little C++ hack to force static initialization on application start. | |
Friends | |
class | linkLock |
Needed to grant access to the protected getLink() method. |
DS2405 features:
This class is thread-safe.
Parts of the documentation by Dallas Semiconductors / Maxim Integrated Products
Definition at line 54 of file LOW_devDS2405.h.
|
Vector type of class device pointers.
Definition at line 85 of file LOW_devDS2405.h. |
|
Map type of devices with LOW_deviceID as key.
Definition at line 101 of file LOW_device.h. |
|
Vector type of class device pointers.
Definition at line 100 of file LOW_device.h. Referenced by LOW_netSegment::searchDevices(). |
|
Real constructor corresponding to static pseudo constructor new_Instance().
Definition at line 60 of file LOW_devDS2405.cpp. Referenced by new_Instance(). |
|
Destructor.
Definition at line 66 of file LOW_devDS2405.cpp. |
|
Exception base class for all exceptions thrown by LOW_devDS2405.
|
|
Toggle the state of the PIO pin.
Definition at line 76 of file LOW_devDS2405.cpp. References LOW_device::cmd_MatchROM(), and LOW_device::linkLock. Referenced by cmd_MatchRead(), and LOW_compJalousieController::LOW_compJalousieController(). |
|
Toggle the state of the PIO pin and read its new state. Note: The return value is inverted compared to cmd_SearchActive().
Definition at line 84 of file LOW_devDS2405.cpp. References cmd_Match(), LOW_device::getLink(), LOW_device::linkLock, and LOW_link::readDataBit(). Referenced by LOW_compJalousieController::setDirectionDown(), LOW_compJalousieController::setDirectionUp(), LOW_compJalousieController::setPowerOff(), and LOW_compJalousieController::setPowerOn(). |
|
Shortcut for issuing a matchROM command for a device. Calls the corresponding method in LOW_netSegment. Definition at line 102 of file LOW_device.cpp. References LOW_netSegment::cmd_MatchROM(), and LOW_device::netSegment. Referenced by LOW_devDS2406::cmd_ChannelAccess::cmd_ChannelAccess(), LOW_devDS1820::cmd_ConvertT(), LOW_devDS1820::cmd_CopyScratchpad(), LOW_devDS2890::cmd_Decrement(), LOW_devDS2890::cmd_Increment(), cmd_Match(), LOW_devDS2890::cmd_ReadControlRegister(), LOW_devDS2890::cmd_ReadPosition(), LOW_devDS1820::cmd_ReadPowerSupply(), LOW_devDS1820::cmd_ReadScratchpad(), LOW_devDS1820::cmd_RecallE2(), LOW_devDS2890::cmd_WriteControlRegister(), LOW_devDS2890::cmd_WritePosition(), LOW_devDS1820::cmd_WriteScratchpad(), LOW_devDS2406::cmd_WriteStatus(), and LOW_devDS2406::readMemUniversal(). |
|
Read if the output pulldown is turned on. The device will not toggle the state of its PIO pin. Note: The return value is inverted compared to ().
Definition at line 102 of file LOW_devDS2405.cpp. References LOW_device::linkLock, and LOW_device::verifyDevice(). Referenced by LOW_compJalousieController::LOW_compJalousieController(). |
|
Read the logic state of the PIO pin (input). The device will not toggle the state of its PIO pin. The combination of Match ROM and Search ROM allows the user to change the state of the PIO pin and report the current state (Match ROM) or simply report the current state of the PIO pin without changing it (Search ROM).
Definition at line 93 of file LOW_devDS2405.cpp. References LOW_device::getLink(), LOW_device::linkLock, LOW_link::readDataBit(), and LOW_device::verifyDevice(). |
|
Get the device's family code. Note: Subclasses must implement this method to return their specific family code.
Reimplemented from LOW_device. Definition at line 113 of file LOW_devDS2405.h. References LOW_deviceIDRaw::devFamCode_t, and familyCode. |
|
Get the device's family name. Note: Subclasses must implement this method to return a clear text name of their family.
Reimplemented from LOW_device. Definition at line 120 of file LOW_devDS2405.h. References familyName. |
|
Get the device's ROM ID.
Definition at line 73 of file LOW_device.cpp. References LOW_device::ID. Referenced by LOW_netSegment::buryDevice(), LOW_netSegment::cmd_MatchROM(), LOW_compJalousieController::LOW_compJalousieController(), LOW_netSegment::removeDevice(), and LOW_netSegment::revitalizeDevice(). |
|
|
Get the network segment the device is on.
Definition at line 79 of file LOW_device.cpp. References LOW_device::netSegment. Referenced by LOW_compJalousieController::LOW_compJalousieController(), and LOW_compTwinSwitch::LOW_compTwinSwitch(). |
|
Static inizializer to register the class with LOW_deviceFactory.
Definition at line 35 of file LOW_devDS2405.cpp. References familyCode, new_Instance(), and LOW_deviceFactory::registerSpecificCtor(). |
|
Static pseudo constructor for registering with LOW_deviceFactory.
Reimplemented from LOW_device. Definition at line 48 of file LOW_devDS2405.cpp. References LOW_devDS2405(). Referenced by initialize(). |
|
Shortcut method to verify the presence of the device on it's network segment.
Definition at line 85 of file LOW_device.cpp. References LOW_device::ID, LOW_device::netSegment, and LOW_netSegment::verifyDevice(). Referenced by LOW_compTwinSwitch::alarmPollLoop(), LOW_compTempSensor::checkAlarm(), cmd_SearchActive(), and cmd_SearchRead(). |
|
|
Pseudo family code for selecting any/all device types.
Definition at line 73 of file LOW_device.h. Referenced by LOW_netSegment::cmd_SearchROMVerify(), LOW_netSegment::getDevice(), LOW_netSegment::getDevices(), LOW_deviceFactory::registerSpecificCtor(), LOW_linkDS2490::searchDevices(), and LOW_link::searchDevices(). |
|
Family code of this specific device.
Reimplemented from LOW_device. Definition at line 74 of file LOW_devDS2405.h. Referenced by getFamilyCode(), and initialize(). |
|
Family name of this specific device.
Reimplemented from LOW_device. Definition at line 32 of file LOW_devDS2405.cpp. Referenced by getFamilyName(). |
|
1-Wire ROM ID of the device
Definition at line 192 of file LOW_device.h. Referenced by LOW_device::getID(), LOW_device::LOW_device(), and LOW_device::verifyDevice(). |
|
Needed for dirty little C++ hack to force static initialization on application start.
Definition at line 34 of file LOW_devDS2405.cpp. |
|
1-Wire command byte constant
Definition at line 88 of file LOW_device.h. Referenced by LOW_netSegment::cmd_MatchROM(). |
|
Network segment where the device is located.
Definition at line 193 of file LOW_device.h. Referenced by LOW_device::cmd_MatchROM(), LOW_device::getLink(), LOW_device::getNetSegment(), LOW_device::LOW_device(), LOW_device::verifyDevice(), and LOW_device::~LOW_device(). |
|
1-Wire command byte constant
Definition at line 89 of file LOW_device.h. Referenced by LOW_netSegment::cmd_ReadROM(). |
|
1-Wire command byte constant
Definition at line 92 of file LOW_device.h. Referenced by LOW_linkDS2490::searchDevices(), and LOW_link::searchDevices(). |
|
1-Wire command byte constant
Definition at line 91 of file LOW_device.h. Referenced by LOW_linkDS2490::searchDevices(), and LOW_link::searchDevices(). |
|
1-Wire command byte constant
Definition at line 90 of file LOW_device.h. Referenced by LOW_netSegment::cmd_SkipROM(). |
|
Pseudo family code for unknown device types.
Definition at line 76 of file LOW_device.h. Referenced by LOW_netSegment::getDevice(), LOW_netSegment::getDevices(), and LOW_deviceFactory::registerSpecificCtor(). |