Skip to content
Snippets Groups Projects
Commit fcffd5ca authored by BAHJI's avatar BAHJI
Browse files

Merge remote-tracking branch 'origin/ICATHALES-415_DTT' into Sprint16_Delivery

parents a8faab92 b26dbcaf
Branches
Tags
1 merge request!3[PIController] Add PIAxis commands and attributes
......@@ -316,7 +316,7 @@ void AxisController::initialise_reference_position()
m_velocity.set_value(m_init_velocity);
msg = yat::Message::allocate(CTRL_SETVELOCITY_MSG, DEFAULT_MSG_PRIORITY, true);
post(msg);
if (m_model.get_value() == "C-884")
if (m_model.get_value() == "C-884" || m_model.get_value() == "SIMULATOR")
{
if (m_init_type == "FNL")
{
......@@ -334,6 +334,10 @@ void AxisController::initialise_reference_position()
yat::Message* msg = yat::Message::allocate(CTRL_AUTO_ZERO_MSG, DEFAULT_MSG_PRIORITY, true);
post(msg, 5000);
}
while (get_state() == Tango::MOVING)
{
continue;
}
m_pos.set_value(m_init_position);
msg = yat::Message::allocate(CTRL_POS_MSG, DEFAULT_MSG_PRIORITY, true);
post(msg);
......
......@@ -192,7 +192,7 @@ int Off::get_value()
//----------------------------------------------------
yat::String IsMoving::pull_request(int axis_id)
{
if (m_model == "SIMULATOR" || m_model == "E-754")
if (m_model == "SIMULATOR")
{
return "#5"; //Command for the MockServer
}
......
......@@ -23,14 +23,14 @@
#this i a special section to declare user variables, the syntaxe is xxx=yyy
model=(c)MOCK, SIMULATOR, 111111111, 1.0.0.0
servo=1
pos=10
pos=0
vel=0.500000
accel=2.000000
decel=2.000000
moving=0
ron=1
err=0
limit_switch=0x9004
limit_switch=0x9001
is_initialized=1
[END]
......
......@@ -52,7 +52,7 @@ Action: WAIT state param: ['0.1'] - Check: DIFF value: MOVING delta:
last raw result: ON
last check result: True
Action: WRITE Velocity param: ['2.0'] - No check
Action: WRITE velocity param: ['2.0'] - No check
raw result: OK
Action: WRITE acceleration param: ['2.0'] - No check
......@@ -187,9 +187,46 @@ Action: READ forwardLimitSwitch param: [''] - Check: EQUAL value: 1 delta:
raw result: True
check result: True
---------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------
PART V - Intialise the position of reference / ICATHALES-415
---------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------
Action: CMD INIT - No check
raw result: OK
------------------------
Check State is ON
------------------------
Action: READ state param: [''] - Check: EQUAL value: ON delta:
raw result: ON
check result: True
------------------------
Check InitialiseReferencePosition
------------------------
Action: CMD InitialiseReferencePosition - No check
raw result: OK
------------------------
------------------------
Wait (while state is Moving due to change position)
------------------------
Action: WAIT state param: ['0.1'] - Check: DIFF value: MOVING delta:
last raw result: ON
last check result: True
Action: READ position param: [''] - Check: EQUAL value: 0 delta:
raw result: 10.0
check result: False
Action: READ velocity param: [''] - Check: EQUAL value: 0.5 delta:
raw result: 0.5
check result: True
------------------------ END OF TEST --------------------------
---------------------------------------------------------------------
#### FINAL REPORT ####
Checks OK: 19 -- checks KO: 0
Checks OK: 22 -- checks KO: 1
---------------------------------------------------------------------
......@@ -38,7 +38,7 @@ WRITE;position;REAL;2.0;;;
@------------------------
WAIT;state;STATE;0.1;DIFF;MOVING;
#
WRITE;Velocity;REAL;2.0;;;
WRITE;velocity;REAL;2.0;;;
WRITE;acceleration;REAL;2.0;;;
WRITE;deceleration;REAL;2.0;;;
#
......@@ -117,3 +117,28 @@ WAIT;state;STATE;0.1;DIFF;MOVING;
READ;backwardLimitSwitch;BOOL;;EQUAL;0;
READ;forwardLimitSwitch;BOOL;;EQUAL;1;
#
@---------------------------------------------------------------------------------------
@---------------------------------------------------------------------------------------
@ PART V - Intialise the position of reference / ICATHALES-415
@---------------------------------------------------------------------------------------
@---------------------------------------------------------------------------------------
#
CMD;INIT;;;;;
@------------------------
@Check State is ON
@------------------------
READ;state;STATE;;EQUAL;ON;
#
@------------------------
@Check InitialiseReferencePosition
@------------------------
CMD;InitialiseReferencePosition;;;;;
@------------------------
@------------------------
@Wait (while state is Moving due to change position)
@------------------------
WAIT;state;STATE;0.1;DIFF;MOVING;
#
READ;position;REAL;;EQUAL;0;
READ;velocity;REAL;;EQUAL;0.5;
#
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment