Class CPLStation
Introduction This class implements a single station on a HomePlug AV powerline network. Class instances are instantiated and initialized only by instantiating the CPLNetwork class. Class properties are read-only and class methods are passive. The Firmware Technical Reference Manaual uses terminology that views a powerline network from the inside-looking-out. This class uses terminology that views a powerline network from the outside-looking-in. For example, here, a device is something connected to a powerline station, a network is a collection of stations and every adapter is a station. This class is declared in CPLStation.hpp and defined in CPLStation.cpp.
Inheritance None.
Dependence This class depends on the CPLNetwork class to instantiate it and inialize all properties. There is no need for an application programs to instantiate this class directly. This class uses class ointellon to encode and decode vendor specific management message frames. This class uses static class omemory to print outgoing and incoming frames. This class uses static class oerror to report errors.
Properties This class inherits no properties. Class properties are all read-only and cannot be modified once initialized.
CPLStation::HardwareType unsigned HardwareType void Return the hardware type as an unsigned integer. The hardware type incidates the chipset architecture. The value 0 means an unknown chipset architecture. A value greater than 0 indicates an INT6000, INT6300, INT6400 and so on. The hardware type is the same as the MDEVICEID field of the VS_SW_VER management message described in the Firmware Technical Reference Manual.
CPLStation::HardwareName char const * HardwareName void Return the hardware name as a NUL terminated character string. The hardware name is based on the HardwareType. The string "UNSUPPORTED" means the chipset is not recognized. Normally, the string will be one of "INT6000", "INT6300" or "INT6400".
CPLStation::FirmwareName char const * FirmwareName void Return the fimware revision as a NUL terminated character string. An example string might look like "INT6000-MAC-4-0-4011-01-3431-20090519-FINAL-B". The firmware revision is the same as the MVERSION field of the VS_SW_VER management message described in the Firmware Technical Reference Manual.
CPLStation::HostAddress byte const * HostAddress void Return the first bridged device hardware address. This is the hardware address of the first Ethernet device being supported by the powerline station. The bridged device address is ETHER_ADDR_LEN bytes. The host address is the same as the BDA returned by the VS_NW_INFO management message described in the Firwmare Technical Reference Manual. If the host address is the BroadcastAddress then no Ethernet devices are connected to the station. This is a common condition that does not affect the reliability of the other property values.
CPLStation::HostAddressString char const * HostAddressString void Return the HostAddress property as a NUL terminated hexadecimal character string. The string is ETHER_ADDR_LEN*3 characters long including the terminator.
CPLStation::IsBridge bool IsBridge void Return logical true if this station is a host bridge. This property is a boolean alternative to the LinkType property.
CPLStation::LinkName unsigned LinkName void Return the relationship between the station and this host as a NUL terminated character string. The string "LOC" means the station is local and serves as the ethernet-to-powerline bridge for this host. The string "REM" means the station is remote as serves as the powerline-to-ethernet bridge for another host. These string are useful when enumerating powerline network devices.
CPLStation::LinkType unsigned LinkType void Return the relationship between the station and this host as an unsigned integer. The value 0 means the station is local and serves as the ethernet-to-powerline bridge for this host. The value 1 means the station is remote and serves as the powerline-to-ethernet bridge for another host.
CPLStation::NodeAddress byte const * NodeAddress void Return the station hardware address. This is the address of the powerline station, itself. The station address is ETHER_ADDR_LEN bytes. The node address is the same as the DA field of the VS_NW_INFO management message described in the Firwmare Technical Reference Manual. If the node address is the BroadcastAddress then the associated station is no longer connected to the network. Consequently, the instance HostAddress, TxRate and RxRate properties are unreliable.
CPLStation::NodeAddressString char const * NodeAddressString void Return the NodeAddress property as a NUL terminated hexadecimal character string. The string will be ETHER_ADDR_LEN*3 characters long including the terminator.
CPLStation::PrefaceString char const * PrefaceString void Return the station preface as a string. The station preface is a single-line title for the output produced printed by the Print method. The only purpose it serves is to indicate the significance of each output field. Although shwn as a property, the string is implemented as a constant so parenthesis are omitted when referencing it. The string looks like this: P/L NET TEI ------ MAC ------ ------ BDA ------ TX RX CHIPSET FIRMWARE
CPLStation::RoleName unsigned RoleName void Return the AVLN station role as a NUL terminated character string. The string "STA" means the station is an ordinary station. The string "CCO" means the station is the Central Co-ordinator. See the HomePlug AV Specification for an explanation of station roles.
CPLStation::RoleType unsigned RoleType void Return the AVLN station role as an unsigned integer. The value 0 means the station is an oridnary station (STA). The value 1 means the station is the Central Co-ordinator (CCo). See the HomePlug AV Specification for an explanation of station roles.
CPLStation::RxRate unsigned RxRate void Return the station receive PHY rate in megabits per second as an unsigned integer. The receive rate applies only to traffic transmitted by this station to the reference station. It is the same as the AVGRX field in the VS_NW_INFO managment message described in the Firmware Technical Reference Manual.
CPLStation::StationID unsigned StationID void Return the AVLN station number. The station number is the same as the TEI field of the VS_NW_INFO management message described in the Firmware Technical Reference Manual. Every station on an AVLN has a unique station number.
CPLStation::TxRate unsigned TxRate void Return the station transmit PHY rate in megabits per second as an unsigned integer. The transmit rate applies only to traffic received by this this station from the reference station. It is the same as the AVGTX field in the VS_NW_INFO managment message described in the Firmware Technical Reference Manual.
Methods This class inherits no methods.
CPLStation::Preface CPLStation & Preface void Print the PrefaceString on stdout followed by a newline. This method is optional but may be called prior to printing station details. Sample output follows.
CPLStation::Print CPLStation & Print void Print class properties in a human readable format on stdout. Example output follows. The fields show local or remote connection, station or CCo status, station hardware address, bridged device hardware address, transmit PHY rate, receive PHY rate, hardware type and firmware revision. REM STA 002 00:B0:52:DE:AD:01 00:07:E9:F6:42:51 145 147 INT6000 INT6000-MAC-4-1-4101-00-3646-20090615-BETA1-B
Constructors CPLStation void Instantiates the class as an empty powerline station. Class CPLNetwork instantiates this class and initializes class properties.
Examples None.