7 #include "HiC884Controller.h"
8 #include "HiM110Actuator.h"
19 HiC884Controller::HiC884Controller()
24 HiC884Controller::~HiC884Controller()
30 {
Std_TraceMsg(0,
"Caught Error in desctructor of HiC884Controller\r\n",
"", -1,
false,
true);}
33 void HiC884Controller::PortNumber(
int iPort)
36 m_iPortNumber = iPort;
39 int HiC884Controller::PortNumber() {
return m_iPortNumber;}
41 #pragma region DataAccesMethods
47 return RobotIOControl::GetDataPointer(strDataType);
54 if(RobotIOControl::SetData(strDataType, strValue,
false))
57 if(strType ==
"PORTNUMBER")
59 PortNumber((
int) atoi(strValue.c_str()));
65 THROW_PARAM_ERROR(Al_Err_lInvalidDataType, Al_Err_strInvalidDataType,
"Data Type", strDataType);
70 void HiC884Controller::QueryProperties(CStdPtrArray<TypeProperty> &aryProperties)
72 RobotIOControl::QueryProperties(aryProperties);
74 aryProperties.Add(
new TypeProperty(
"PortNumber", AnimatPropertyType::Integer, AnimatPropertyDirection::Set));
85 RobotIOControl::Initialize();
88 bool HiC884Controller::OpenIO()
94 void HiC884Controller::CloseIO()
101 RobotIOControl::Load(oXml);
104 PortNumber(oXml.
GetChildInt(
"PortNumber", m_iPortNumber));
virtual bool SetData(const std::string &strDataType, const std::string &strValue, bool bThrowError=true)
Set a variable based on a string data type name.
virtual bool IntoElem()
Goes into the next element where the cursor is located.
virtual int GetChildInt(std::string strElementName)
Gets an integer value from the element with the specified name.
bool Std_IsAboveMin(int iMinVal, int iVal, bool bThrowError, std::string strParamName, bool bInclusiveLimit)
Tests if a number is above a minimum value.
A standard xml manipulation class.
void Std_TraceMsg(const int iLevel, std::string strMessage, std::string strSourceFile, int iSourceLine, bool bLogToFile, bool bPrintHeader)
Traces a message to the debugger window.
virtual bool OutOfElem()
Goes out of the element where the cursor is located.
std::string Std_CheckString(std::string strVal)
Converts a string to upper case and trims it.
virtual void Load(StdUtils::CStdXml &oXml)
Loads the item using an XML data packet.
virtual void Initialize()
Initializes this object.
virtual float * GetDataPointer(const std::string &strDataType)
Returns a float pointer to a data item of interest in this object.