isar 1.26.4__py3-none-any.whl → 1.27.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of isar might be problematic. Click here for more details.
- isar/apis/api.py +25 -0
- isar/apis/models/start_mission_definition.py +1 -7
- isar/apis/schedule/scheduling_controller.py +17 -1
- isar/config/settings.py +4 -1
- isar/models/communication/queues/events.py +1 -0
- isar/models/communication/queues/queue_utils.py +6 -0
- isar/modules.py +13 -6
- isar/robot/robot.py +10 -1
- isar/robot/robot_status.py +11 -5
- isar/services/utilities/scheduling_utilities.py +60 -7
- isar/state_machine/state_machine.py +51 -121
- isar/state_machine/states/await_next_mission.py +92 -0
- isar/state_machine/states/blocked_protective_stop.py +2 -5
- isar/state_machine/states/home.py +87 -0
- isar/state_machine/states/monitor.py +8 -3
- isar/state_machine/states/offline.py +3 -5
- isar/state_machine/states/returning_home.py +186 -0
- isar/state_machine/states/{idle.py → robot_standing_still.py} +20 -8
- isar/state_machine/states/{stop.py → stopping.py} +16 -4
- isar/state_machine/states/unknown_status.py +74 -0
- isar/state_machine/states_enum.py +6 -3
- isar/state_machine/transitions/functions/return_home.py +38 -0
- isar/state_machine/transitions/functions/robot_status.py +27 -0
- isar/state_machine/transitions/{start_mission.py → functions/start_mission.py} +1 -1
- isar/state_machine/transitions/mission.py +119 -0
- isar/state_machine/transitions/return_home.py +69 -0
- isar/state_machine/transitions/robot_status.py +73 -0
- {isar-1.26.4.dist-info → isar-1.27.0.dist-info}/METADATA +14 -7
- {isar-1.26.4.dist-info → isar-1.27.0.dist-info}/RECORD +43 -35
- {isar-1.26.4.dist-info → isar-1.27.0.dist-info}/WHEEL +1 -1
- robot_interface/models/exceptions/robot_exceptions.py +14 -0
- robot_interface/models/mission/mission.py +8 -1
- robot_interface/models/mission/status.py +2 -0
- robot_interface/models/mission/task.py +0 -1
- isar/state_machine/states/off.py +0 -18
- /isar/state_machine/transitions/{fail_mission.py → functions/fail_mission.py} +0 -0
- /isar/state_machine/transitions/{finish_mission.py → functions/finish_mission.py} +0 -0
- /isar/state_machine/transitions/{pause.py → functions/pause.py} +0 -0
- /isar/state_machine/transitions/{resume.py → functions/resume.py} +0 -0
- /isar/state_machine/transitions/{stop.py → functions/stop.py} +0 -0
- /isar/state_machine/transitions/{utils.py → functions/utils.py} +0 -0
- {isar-1.26.4.dist-info → isar-1.27.0.dist-info}/entry_points.txt +0 -0
- {isar-1.26.4.dist-info → isar-1.27.0.dist-info}/licenses/LICENSE +0 -0
- {isar-1.26.4.dist-info → isar-1.27.0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING, List
|
|
2
|
+
|
|
3
|
+
from isar.state_machine.transitions.functions.fail_mission import (
|
|
4
|
+
report_failed_mission_and_finalize,
|
|
5
|
+
)
|
|
6
|
+
from isar.state_machine.transitions.functions.finish_mission import finish_mission
|
|
7
|
+
from isar.state_machine.transitions.functions.pause import pause_mission
|
|
8
|
+
from isar.state_machine.transitions.functions.resume import resume_mission
|
|
9
|
+
from isar.state_machine.transitions.functions.start_mission import (
|
|
10
|
+
initialize_robot,
|
|
11
|
+
initiate_mission,
|
|
12
|
+
put_start_mission_on_queue,
|
|
13
|
+
set_mission_to_in_progress,
|
|
14
|
+
trigger_start_mission_event,
|
|
15
|
+
)
|
|
16
|
+
from isar.state_machine.transitions.functions.stop import (
|
|
17
|
+
stop_mission_cleanup,
|
|
18
|
+
trigger_stop_mission_event,
|
|
19
|
+
)
|
|
20
|
+
from isar.state_machine.transitions.functions.utils import def_transition
|
|
21
|
+
|
|
22
|
+
if TYPE_CHECKING:
|
|
23
|
+
from isar.state_machine.state_machine import StateMachine
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
def get_mission_transitions(state_machine: "StateMachine") -> List[dict]:
|
|
27
|
+
mission_transitions: List[dict] = [
|
|
28
|
+
{
|
|
29
|
+
"trigger": "pause",
|
|
30
|
+
"source": state_machine.monitor_state,
|
|
31
|
+
"dest": state_machine.paused_state,
|
|
32
|
+
"before": def_transition(state_machine, pause_mission),
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"trigger": "resume",
|
|
36
|
+
"source": state_machine.paused_state,
|
|
37
|
+
"dest": state_machine.monitor_state,
|
|
38
|
+
"before": def_transition(state_machine, resume_mission),
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"trigger": "stop",
|
|
42
|
+
"source": [
|
|
43
|
+
state_machine.await_next_mission_state,
|
|
44
|
+
state_machine.robot_standing_still_state,
|
|
45
|
+
state_machine.monitor_state,
|
|
46
|
+
state_machine.returning_home_state,
|
|
47
|
+
state_machine.paused_state,
|
|
48
|
+
],
|
|
49
|
+
"dest": state_machine.stopping_state,
|
|
50
|
+
"before": def_transition(state_machine, trigger_stop_mission_event),
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"trigger": "mission_stopped",
|
|
54
|
+
"source": state_machine.stopping_state,
|
|
55
|
+
"dest": state_machine.await_next_mission_state,
|
|
56
|
+
"before": def_transition(state_machine, stop_mission_cleanup),
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"trigger": "return_home_mission_stopped",
|
|
60
|
+
"source": state_machine.stopping_state,
|
|
61
|
+
"dest": state_machine.robot_standing_still_state,
|
|
62
|
+
"before": def_transition(state_machine, stop_mission_cleanup),
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"trigger": "request_mission_start",
|
|
66
|
+
"source": [
|
|
67
|
+
state_machine.await_next_mission_state,
|
|
68
|
+
state_machine.home_state,
|
|
69
|
+
state_machine.robot_standing_still_state,
|
|
70
|
+
],
|
|
71
|
+
"dest": state_machine.monitor_state,
|
|
72
|
+
"prepare": def_transition(state_machine, put_start_mission_on_queue),
|
|
73
|
+
"conditions": [
|
|
74
|
+
def_transition(state_machine, initiate_mission),
|
|
75
|
+
def_transition(state_machine, initialize_robot),
|
|
76
|
+
],
|
|
77
|
+
"before": [
|
|
78
|
+
def_transition(state_machine, set_mission_to_in_progress),
|
|
79
|
+
def_transition(state_machine, trigger_start_mission_event),
|
|
80
|
+
],
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"trigger": "request_mission_start",
|
|
84
|
+
"source": state_machine.await_next_mission_state,
|
|
85
|
+
"dest": state_machine.await_next_mission_state,
|
|
86
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
"trigger": "request_mission_start",
|
|
90
|
+
"source": state_machine.robot_standing_still_state,
|
|
91
|
+
"dest": state_machine.robot_standing_still_state,
|
|
92
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
"trigger": "request_mission_start",
|
|
96
|
+
"source": state_machine.home_state,
|
|
97
|
+
"dest": state_machine.home_state,
|
|
98
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"trigger": "request_mission_start",
|
|
102
|
+
"source": state_machine.returning_home_state,
|
|
103
|
+
"dest": state_machine.returning_home_state,
|
|
104
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"trigger": "mission_failed_to_start",
|
|
108
|
+
"source": state_machine.monitor_state,
|
|
109
|
+
"dest": state_machine.robot_standing_still_state,
|
|
110
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"trigger": "mission_finished",
|
|
114
|
+
"source": state_machine.monitor_state,
|
|
115
|
+
"dest": state_machine.await_next_mission_state,
|
|
116
|
+
"before": def_transition(state_machine, finish_mission),
|
|
117
|
+
},
|
|
118
|
+
]
|
|
119
|
+
return mission_transitions
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING, List
|
|
2
|
+
|
|
3
|
+
from isar.state_machine.transitions.functions.fail_mission import (
|
|
4
|
+
report_failed_mission_and_finalize,
|
|
5
|
+
)
|
|
6
|
+
from isar.state_machine.transitions.functions.return_home import (
|
|
7
|
+
return_home_finished,
|
|
8
|
+
set_return_home_status,
|
|
9
|
+
start_return_home_mission,
|
|
10
|
+
)
|
|
11
|
+
from isar.state_machine.transitions.functions.start_mission import (
|
|
12
|
+
initialize_robot,
|
|
13
|
+
trigger_start_mission_event,
|
|
14
|
+
)
|
|
15
|
+
from isar.state_machine.transitions.functions.utils import def_transition
|
|
16
|
+
|
|
17
|
+
if TYPE_CHECKING:
|
|
18
|
+
from isar.state_machine.state_machine import StateMachine
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def get_return_home_transitions(state_machine: "StateMachine") -> List[dict]:
|
|
22
|
+
return_home_transitions: List[dict] = [
|
|
23
|
+
{
|
|
24
|
+
"trigger": "request_return_home",
|
|
25
|
+
"source": [
|
|
26
|
+
state_machine.await_next_mission_state,
|
|
27
|
+
state_machine.home_state,
|
|
28
|
+
state_machine.robot_standing_still_state,
|
|
29
|
+
],
|
|
30
|
+
"dest": state_machine.returning_home_state,
|
|
31
|
+
"conditions": [
|
|
32
|
+
def_transition(state_machine, start_return_home_mission),
|
|
33
|
+
def_transition(state_machine, set_return_home_status),
|
|
34
|
+
def_transition(state_machine, initialize_robot),
|
|
35
|
+
],
|
|
36
|
+
"before": def_transition(state_machine, trigger_start_mission_event),
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"trigger": "request_return_home",
|
|
40
|
+
"source": state_machine.await_next_mission_state,
|
|
41
|
+
"dest": state_machine.await_next_mission_state,
|
|
42
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"trigger": "request_return_home",
|
|
46
|
+
"source": state_machine.home_state,
|
|
47
|
+
"dest": state_machine.home_state,
|
|
48
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"trigger": "request_return_home",
|
|
52
|
+
"source": state_machine.robot_standing_still_state,
|
|
53
|
+
"dest": state_machine.robot_standing_still_state,
|
|
54
|
+
"before": def_transition(state_machine, report_failed_mission_and_finalize),
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"trigger": "returned_home",
|
|
58
|
+
"source": state_machine.returning_home_state,
|
|
59
|
+
"dest": state_machine.home_state,
|
|
60
|
+
"before": def_transition(state_machine, return_home_finished),
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"trigger": "return_home_failed",
|
|
64
|
+
"source": state_machine.returning_home_state,
|
|
65
|
+
"dest": state_machine.robot_standing_still_state,
|
|
66
|
+
"before": def_transition(state_machine, return_home_finished),
|
|
67
|
+
},
|
|
68
|
+
]
|
|
69
|
+
return return_home_transitions
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING, List
|
|
2
|
+
|
|
3
|
+
from isar.state_machine.transitions.functions.robot_status import (
|
|
4
|
+
is_available,
|
|
5
|
+
is_blocked_protective_stop,
|
|
6
|
+
is_home,
|
|
7
|
+
is_offline,
|
|
8
|
+
)
|
|
9
|
+
from isar.state_machine.transitions.functions.utils import def_transition
|
|
10
|
+
|
|
11
|
+
if TYPE_CHECKING:
|
|
12
|
+
from isar.state_machine.state_machine import StateMachine
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
def get_robot_status_transitions(state_machine: "StateMachine") -> List[dict]:
|
|
16
|
+
robot_status_transitions: List[dict] = [
|
|
17
|
+
{
|
|
18
|
+
"trigger": "robot_status_changed",
|
|
19
|
+
"source": [
|
|
20
|
+
state_machine.home_state,
|
|
21
|
+
state_machine.blocked_protective_stopping_state,
|
|
22
|
+
state_machine.offline_state,
|
|
23
|
+
state_machine.unknown_status_state,
|
|
24
|
+
],
|
|
25
|
+
"dest": state_machine.robot_standing_still_state,
|
|
26
|
+
"conditions": def_transition(state_machine, is_available),
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"trigger": "robot_status_changed",
|
|
30
|
+
"source": [
|
|
31
|
+
state_machine.robot_standing_still_state,
|
|
32
|
+
state_machine.blocked_protective_stopping_state,
|
|
33
|
+
state_machine.offline_state,
|
|
34
|
+
state_machine.unknown_status_state,
|
|
35
|
+
],
|
|
36
|
+
"dest": state_machine.home_state,
|
|
37
|
+
"conditions": def_transition(state_machine, is_home),
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"trigger": "robot_status_changed",
|
|
41
|
+
"source": [
|
|
42
|
+
state_machine.robot_standing_still_state,
|
|
43
|
+
state_machine.home_state,
|
|
44
|
+
state_machine.offline_state,
|
|
45
|
+
state_machine.unknown_status_state,
|
|
46
|
+
],
|
|
47
|
+
"dest": state_machine.blocked_protective_stopping_state,
|
|
48
|
+
"conditions": def_transition(state_machine, is_blocked_protective_stop),
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"trigger": "robot_status_changed",
|
|
52
|
+
"source": [
|
|
53
|
+
state_machine.robot_standing_still_state,
|
|
54
|
+
state_machine.home_state,
|
|
55
|
+
state_machine.blocked_protective_stopping_state,
|
|
56
|
+
state_machine.unknown_status_state,
|
|
57
|
+
],
|
|
58
|
+
"dest": state_machine.offline_state,
|
|
59
|
+
"conditions": def_transition(state_machine, is_offline),
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"trigger": "robot_status_changed",
|
|
63
|
+
"source": [
|
|
64
|
+
state_machine.robot_standing_still_state,
|
|
65
|
+
state_machine.home_state,
|
|
66
|
+
state_machine.blocked_protective_stopping_state,
|
|
67
|
+
state_machine.offline_state,
|
|
68
|
+
state_machine.unknown_status_state,
|
|
69
|
+
],
|
|
70
|
+
"dest": state_machine.unknown_status_state,
|
|
71
|
+
},
|
|
72
|
+
]
|
|
73
|
+
return robot_status_transitions
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: isar
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.27.0
|
|
4
4
|
Summary: Integration and Supervisory control of Autonomous Robots
|
|
5
5
|
Author-email: Equinor ASA <fg_robots_dev@equinor.com>
|
|
6
6
|
License: Eclipse Public License version 2.0
|
|
@@ -331,22 +331,29 @@ The system consists of two main components.
|
|
|
331
331
|
The state machine handles interaction with the robots API and monitors the execution of missions. It also enables
|
|
332
332
|
interacting with the robot before, during and after missions.
|
|
333
333
|
|
|
334
|
-
The state machine is based on the [transitions](https://github.com/pytransitions/transitions) package for Python.
|
|
335
|
-
|
|
334
|
+
The state machine is based on the [transitions](https://github.com/pytransitions/transitions) package for Python. The following are some visualizations of the state machine:
|
|
335
|
+
|
|
336
|
+
Mission behavior without the robot status changed transition that enable the resting states to transition between each other if the robot status changes:
|
|
337
|
+

|
|
338
|
+
|
|
339
|
+
Robot status changed transition:
|
|
340
|
+

|
|
341
|
+
|
|
342
|
+
Full state machine:
|
|
343
|
+

|
|
336
344
|
|
|
337
345
|
In general the states
|
|
338
346
|
|
|
339
347
|
```
|
|
340
|
-
States.
|
|
341
|
-
States.Stop,
|
|
348
|
+
States.Stopping,
|
|
342
349
|
States.Monitor,
|
|
343
350
|
States.Paused,
|
|
344
351
|
```
|
|
345
352
|
|
|
346
|
-
indicates that the state machine is already running. For running a mission the state machine need to be in the
|
|
353
|
+
indicates that the state machine is already running. For running a mission the state machine need to be in the states
|
|
347
354
|
|
|
348
355
|
```
|
|
349
|
-
States.
|
|
356
|
+
States.Home, States.RobotStandingStill, States.AwaitNextMission or States.ReturningHome
|
|
350
357
|
```
|
|
351
358
|
|
|
352
359
|
### FastAPI
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
isar/__init__.py,sha256=cH8p8bVveu3FUL6kBhldcSlLaoHgD82Kd0-SwSNfGXw,87
|
|
2
|
-
isar/modules.py,sha256=
|
|
2
|
+
isar/modules.py,sha256=CO3Ikr3evmlNk7-EXfcdafATxaXVtSd-I1Dzr3uHpts,5095
|
|
3
3
|
isar/script.py,sha256=VOI4nSEObDj53cSAFfzVBFDMwbu20uOsUZLZYyDZfBE,6083
|
|
4
4
|
isar/apis/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
5
|
-
isar/apis/api.py,sha256=
|
|
5
|
+
isar/apis/api.py,sha256=1-RmRH7NReCpOo_NSwP5hS2lDQm6_Dx2ZWe2460GhJY,13770
|
|
6
6
|
isar/apis/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
7
7
|
isar/apis/models/models.py,sha256=HzLaWhjAv0uJRBWipIgYg_F75eaQ5jl9Pi4UnYbDJ-M,1749
|
|
8
|
-
isar/apis/models/start_mission_definition.py,sha256=
|
|
8
|
+
isar/apis/models/start_mission_definition.py,sha256=rGnMOSStAgGCEYG9jyQiVd0yxXZPwmf3Z4SOZJOyt-k,6011
|
|
9
9
|
isar/apis/robot_control/robot_controller.py,sha256=7EVukShJDhYez12wYeGWZXH-BrfQ4Wu2so0-fSWN2Zo,1277
|
|
10
10
|
isar/apis/schedule/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
|
-
isar/apis/schedule/scheduling_controller.py,sha256=
|
|
11
|
+
isar/apis/schedule/scheduling_controller.py,sha256=6QNn3dMu--UCvUfiPEqt9pD6rjjj9_8Mt5E6ECv6kcU,8351
|
|
12
12
|
isar/apis/security/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
13
13
|
isar/apis/security/authentication.py,sha256=Se2puhe2TUBmfio2RLma52-VSLRhqvWgu0Cd1bhdwMo,2000
|
|
14
14
|
isar/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -16,7 +16,7 @@ isar/config/configuration_error.py,sha256=rO6WOhafX6xvVib8WxV-eY483Z0PpN-9PxGsq5
|
|
|
16
16
|
isar/config/log.py,sha256=SzEWbzXU1DpN7YONIRT8k0zBOGm_qVkXlJuuZtb8STc,2300
|
|
17
17
|
isar/config/logging.conf,sha256=mYO1xf27gAopEMHhGzY7-mwyfN16rwRLkPNMvy3zn2g,1127
|
|
18
18
|
isar/config/settings.env,sha256=cLIlcXTM8x0N-6XjXmC0Qclx5dfDC6myqa25tvVwmRw,500
|
|
19
|
-
isar/config/settings.py,sha256=
|
|
19
|
+
isar/config/settings.py,sha256=Scr9clvqarBGzLceAcjPivBMAZ3GGPuaV5OB3J6B5_s,12966
|
|
20
20
|
isar/config/certs/ca-cert.pem,sha256=qoNljfad_qcMxhXJIUMLd7nT-Qwf_d4dYSdoOFEOE8I,2179
|
|
21
21
|
isar/config/keyvault/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
22
22
|
isar/config/keyvault/keyvault_error.py,sha256=zvPCsZLjboxsxthYkxpRERCTFxYV8R5WmACewAUQLwk,41
|
|
@@ -44,15 +44,15 @@ isar/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
|
44
44
|
isar/models/communication/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
45
45
|
isar/models/communication/message.py,sha256=ge2EdUXRnYkiEu5TIAYJFQET_5w-N8MRgc2Y31vetno,155
|
|
46
46
|
isar/models/communication/queues/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
47
|
-
isar/models/communication/queues/events.py,sha256=
|
|
47
|
+
isar/models/communication/queues/events.py,sha256=o_oMos8Md6aTv91ymRNY0fNDWwj5QxWcBm6rxHQz5TY,2413
|
|
48
48
|
isar/models/communication/queues/queue_io.py,sha256=AnHWUCkZ0tunkxKKeBarq-OUkRM97IaMfA-a1pmf1cQ,394
|
|
49
49
|
isar/models/communication/queues/queue_timeout_error.py,sha256=rF8TlNF7RHS_ueTZ5mp7aFkhLY1j0dcwMwH-Ba6lVpE,45
|
|
50
|
-
isar/models/communication/queues/queue_utils.py,sha256=
|
|
50
|
+
isar/models/communication/queues/queue_utils.py,sha256=wg6bIR3NS35Ek9hnGR5eN8z6i0jd5tOwM-8l30h3uiA,868
|
|
51
51
|
isar/models/communication/queues/status_queue.py,sha256=on8kvlNsG6MJjEVsyqtBswIpmOdOggQiKr7F5x0T3jw,514
|
|
52
52
|
isar/models/mission_metadata/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
53
|
-
isar/robot/robot.py,sha256=
|
|
53
|
+
isar/robot/robot.py,sha256=ubHX8AM54Iz5CdINfSRkhs7V8VGSIeuH1pZboUfeLMw,5244
|
|
54
54
|
isar/robot/robot_start_mission.py,sha256=0S5mzOENLtRvW75THr_PTlSDycI3NVMOptJuL9TV0v8,2766
|
|
55
|
-
isar/robot/robot_status.py,sha256=
|
|
55
|
+
isar/robot/robot_status.py,sha256=j5fGq5FzpEscmqUL6i8jRWCZEJ56b2g_DUpAgWpE1YI,1935
|
|
56
56
|
isar/robot/robot_stop_mission.py,sha256=jUyfemvbyigxrlIp9aKPn-PvarhagJEgajQPS_LgJ7g,2442
|
|
57
57
|
isar/robot/robot_task_status.py,sha256=Rfmw5DUMZWsdjuLyPOegTbfkyAkNN3TW9EcHSoZ7fpo,3305
|
|
58
58
|
isar/services/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -68,26 +68,34 @@ isar/services/service_connections/stid/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JC
|
|
|
68
68
|
isar/services/utilities/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
69
69
|
isar/services/utilities/queue_utilities.py,sha256=Pw3hehSwkXJNeDv-bDVDfs58VOwtt3i5hpiJ2ZpphuQ,1225
|
|
70
70
|
isar/services/utilities/robot_utilities.py,sha256=J3miRs0t74HNBoMIzVMceMCibp5DozP9Ai1_i7B3kWI,573
|
|
71
|
-
isar/services/utilities/scheduling_utilities.py,sha256=
|
|
71
|
+
isar/services/utilities/scheduling_utilities.py,sha256=SVmpAuU7101FVUx6x4tcMDrxYaWBPhgOkntFxX_d6Zc,10179
|
|
72
72
|
isar/services/utilities/threaded_request.py,sha256=py4G-_RjnIdHljmKFAcQ6ddqMmp-ZYV39Ece-dqRqjs,1874
|
|
73
73
|
isar/state_machine/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
74
|
-
isar/state_machine/state_machine.py,sha256=
|
|
75
|
-
isar/state_machine/states_enum.py,sha256=
|
|
74
|
+
isar/state_machine/state_machine.py,sha256=EvPTMTWkJuZlrr65cDsNXiyxvjk-B_81Q9U1O_ipS00,12864
|
|
75
|
+
isar/state_machine/states_enum.py,sha256=Z3dO6k6JmQAZ1lzcR58oVCxoCky_-ZS9MaL3RSaNbZ4,434
|
|
76
76
|
isar/state_machine/states/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
77
|
-
isar/state_machine/states/
|
|
78
|
-
isar/state_machine/states/
|
|
79
|
-
isar/state_machine/states/
|
|
80
|
-
isar/state_machine/states/
|
|
81
|
-
isar/state_machine/states/offline.py,sha256=
|
|
77
|
+
isar/state_machine/states/await_next_mission.py,sha256=Afmg2mtWQrlGLlsHJuHLeLWm0RT1lngN8MfRQrGUvXA,3227
|
|
78
|
+
isar/state_machine/states/blocked_protective_stop.py,sha256=Se7ZkZEb2TUYMWBwBDfetNnRH9vkmIwHlsHMqZhmDxg,1714
|
|
79
|
+
isar/state_machine/states/home.py,sha256=YKcOuoj_Z4Z61l_74mOnNQl0mKjRnfuJSl2nk1d6wXE,2956
|
|
80
|
+
isar/state_machine/states/monitor.py,sha256=FLXJEXyD5GJBwffeHF-ykaEe9lXL8XqMN-C61eIVtYQ,9631
|
|
81
|
+
isar/state_machine/states/offline.py,sha256=aqHv8EH68pfq4yTIxOxxDW7VMkPWcQZX3fNgz90_EbE,1503
|
|
82
82
|
isar/state_machine/states/paused.py,sha256=NgEl48GjLvnqGfPipYZZ6Yj8vdTb-fFLAK2tUu8i9j8,1461
|
|
83
|
-
isar/state_machine/states/
|
|
84
|
-
isar/state_machine/
|
|
85
|
-
isar/state_machine/
|
|
86
|
-
isar/state_machine/
|
|
87
|
-
isar/state_machine/transitions/
|
|
88
|
-
isar/state_machine/transitions/
|
|
89
|
-
isar/state_machine/transitions/
|
|
90
|
-
isar/state_machine/transitions/
|
|
83
|
+
isar/state_machine/states/returning_home.py,sha256=UErxB5xQMtjHtCmg-GLJutli2D6Lc29tbhdNcdxIC2M,6973
|
|
84
|
+
isar/state_machine/states/robot_standing_still.py,sha256=h2a0CTxXIjE8YKT9_8hkU80q0caq4TYCxHaOYB54cKc,3378
|
|
85
|
+
isar/state_machine/states/stopping.py,sha256=fxebBwB5rgRQQ1BPpmqrPBo0PxVvFdlXuQAidOGa4nY,3074
|
|
86
|
+
isar/state_machine/states/unknown_status.py,sha256=tOwfHW_4bKKkUTpKD7qc5gIwGT_fTXaCNxXcogGw-wo,2416
|
|
87
|
+
isar/state_machine/transitions/mission.py,sha256=B2d409Q8rJfG4kIY7ZWQWnyxB81xinCUsvm_VWfxMr4,4817
|
|
88
|
+
isar/state_machine/transitions/return_home.py,sha256=LeOMnckUUQYzBYRidD2ge6M0KdxGDTgo-ioXR7_9r8A,2714
|
|
89
|
+
isar/state_machine/transitions/robot_status.py,sha256=c1ceyWRGCtx-KTDtxHXRD7oPbt8TQ2ej24A0wyim8vc,2720
|
|
90
|
+
isar/state_machine/transitions/functions/fail_mission.py,sha256=_6HqBMALDinFZ4yh5GMpeqqgV5tw5i8OVMj5UDdqesg,495
|
|
91
|
+
isar/state_machine/transitions/functions/finish_mission.py,sha256=TRQrk7HdllmAkwsp25HRZAFAk46Y1hLx3jmkIAKrHDI,1442
|
|
92
|
+
isar/state_machine/transitions/functions/pause.py,sha256=aoDkq2nV6wBY0YQX3KbjvBR1ojP2o_SCRT_gfz0BulI,889
|
|
93
|
+
isar/state_machine/transitions/functions/resume.py,sha256=9KQjH_6YBGyxFhb7G5dgDe3WH0xHawhEIw6yTVEm9os,998
|
|
94
|
+
isar/state_machine/transitions/functions/return_home.py,sha256=UlniwYvpz74hxqgN0TyVv3LCmiMsqsosKEtEGLqkNj0,1139
|
|
95
|
+
isar/state_machine/transitions/functions/robot_status.py,sha256=xhKZ5u_X8uDvnhvGnAIABuKaPXeVqFjkgj4H2Om-j_A,1013
|
|
96
|
+
isar/state_machine/transitions/functions/start_mission.py,sha256=w8UDiq9pOHu-ei61ng6rWGjfrh6nk_qSokEVdzBHwzY,2516
|
|
97
|
+
isar/state_machine/transitions/functions/stop.py,sha256=NzPvr6C1tmDqji5XJf5vw9up_Ow7ApuhjAzDVlJLZPw,1368
|
|
98
|
+
isar/state_machine/transitions/functions/utils.py,sha256=Wa72Ocq4QT1E6qkpEJZQ3h5o33pGvx7Tlkt2JZ2Grbk,314
|
|
91
99
|
isar/storage/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
92
100
|
isar/storage/blob_storage.py,sha256=Qci6bO508nlTHKPuPtVU5QcvGA4T7mv8cFrKWRcfw4g,3226
|
|
93
101
|
isar/storage/local_storage.py,sha256=Bnmoi5gyN8r-oRh0aHrOdGqaH3JqRScFKMRXYojW5kY,1855
|
|
@@ -95,20 +103,20 @@ isar/storage/slimm_storage.py,sha256=DJVvTce4cb8m0_b_r6yog41UuxO_9VKb1hYCZUTEhR0
|
|
|
95
103
|
isar/storage/storage_interface.py,sha256=DYDry4I7aZpDHJhsBF6s8zrgokFAc7fdKJKfA8AvL7o,828
|
|
96
104
|
isar/storage/uploader.py,sha256=M7FEr0iLsrSil8SqP7vmB3hswIOA2HTrnakj6aOQbvg,6749
|
|
97
105
|
isar/storage/utilities.py,sha256=fitsdQ1ox5gr9fk9VuSk_iTBiEAIS8NZAnHabUZORh0,3173
|
|
98
|
-
isar-1.
|
|
106
|
+
isar-1.27.0.dist-info/licenses/LICENSE,sha256=3fc2-ebLwHWwzfQbulGNRdcNob3SBQeCfEVUDYxsuqw,14058
|
|
99
107
|
robot_interface/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
100
108
|
robot_interface/robot_interface.py,sha256=Bkk-joyIzRHxv8iZt7FLPFnlE8chlJad9vgjwc-fDkw,8786
|
|
101
109
|
robot_interface/test_robot_interface.py,sha256=FV1urn7SbsMyWBIcTKjsBwAG4IsXeZ6pLHE0mA9EGGs,692
|
|
102
110
|
robot_interface/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
103
111
|
robot_interface/models/exceptions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
104
|
-
robot_interface/models/exceptions/robot_exceptions.py,sha256=
|
|
112
|
+
robot_interface/models/exceptions/robot_exceptions.py,sha256=VrsWPf4g0qN5sJRKhc3ER_Wt5drK0MZRuECU-csIlDA,10026
|
|
105
113
|
robot_interface/models/initialize/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
106
114
|
robot_interface/models/inspection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
107
115
|
robot_interface/models/inspection/inspection.py,sha256=Q8vyiTMV2Ws1B4N10kQ3C1AZkck0Mh5pwOyWux7OQms,2318
|
|
108
116
|
robot_interface/models/mission/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
109
|
-
robot_interface/models/mission/mission.py,sha256=
|
|
110
|
-
robot_interface/models/mission/status.py,sha256=
|
|
111
|
-
robot_interface/models/mission/task.py,sha256=
|
|
117
|
+
robot_interface/models/mission/mission.py,sha256=MQ9p5cuclLXexaZu9bkDh5-aN99eunvYC0vP-Z_kUwI,960
|
|
118
|
+
robot_interface/models/mission/status.py,sha256=UOCARLfLxLFXJEjfIH7aXYXO7xajOKBJsxz-Wd6gZQ4,740
|
|
119
|
+
robot_interface/models/mission/task.py,sha256=Vbyp8JzyoLA2Q90TyEAGWUg6BrV0OBhEm0ut0iBwwXc,4859
|
|
112
120
|
robot_interface/models/robots/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
113
121
|
robot_interface/models/robots/battery_state.py,sha256=ktOtJ8ltdK0k_i7BoqYfhc5dbOzIG6Oo-uWC67fCWio,98
|
|
114
122
|
robot_interface/models/robots/media.py,sha256=8A-CuuubfngzPprs6zWB9hSaqe3jzgsE8rcCzRX2Uto,227
|
|
@@ -119,8 +127,8 @@ robot_interface/telemetry/payloads.py,sha256=m55aFrIczI-PDwQXvsFA6M7YNCTy83w7Ff-
|
|
|
119
127
|
robot_interface/utilities/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
120
128
|
robot_interface/utilities/json_service.py,sha256=qkzVkb60Gi_pto-b5n1vNzCrQze2yqgIJqSLNLYj1Fg,1034
|
|
121
129
|
robot_interface/utilities/uuid_string_factory.py,sha256=_NQIbBQ56w0qqO0MUDP6aPpHbxW7ATRhK8HnQiBSLkc,76
|
|
122
|
-
isar-1.
|
|
123
|
-
isar-1.
|
|
124
|
-
isar-1.
|
|
125
|
-
isar-1.
|
|
126
|
-
isar-1.
|
|
130
|
+
isar-1.27.0.dist-info/METADATA,sha256=OBbuMdSc9sbPALQ2Y4DYubr37T0Xn2jh-Bu9cL__KeU,30709
|
|
131
|
+
isar-1.27.0.dist-info/WHEEL,sha256=ck4Vq1_RXyvS4Jt6SI0Vz6fyVs4GWg7AINwpsaGEgPE,91
|
|
132
|
+
isar-1.27.0.dist-info/entry_points.txt,sha256=TFam7uNNw7J0iiDYzsH2gfG0u1eV1wh3JTw_HkhgKLk,49
|
|
133
|
+
isar-1.27.0.dist-info/top_level.txt,sha256=UwIML2RtuQKCyJJkatcSnyp6-ldDjboB9k9JgKipO-U,21
|
|
134
|
+
isar-1.27.0.dist-info/RECORD,,
|
|
@@ -15,6 +15,7 @@ class ErrorReason(str, Enum):
|
|
|
15
15
|
RobotInitializeException = "robot_initialize_exception"
|
|
16
16
|
RobotRetrieveDataException = "robot_retrieve_data_exception"
|
|
17
17
|
RobotRetrieveInspectionException = "robot_retrieve_inspection_exception"
|
|
18
|
+
RobotStillStartingMissionException = "robot_still_starting_mission_exception"
|
|
18
19
|
RobotTelemetryException = "robot_telemetry_exception"
|
|
19
20
|
RobotTelemetryNoUpdateException = "robot_telemetry_no_update_exception"
|
|
20
21
|
RobotTelemetryPoseException = "robot_telemetry_pose_exception"
|
|
@@ -174,6 +175,19 @@ class RobotRetrieveInspectionException(RobotException):
|
|
|
174
175
|
pass
|
|
175
176
|
|
|
176
177
|
|
|
178
|
+
# An exception which should be thrown by the robot package if it is still starting the
|
|
179
|
+
# mission when another action is requested. An example of this can be trying to stop
|
|
180
|
+
# the robot while it is still starting the mission.
|
|
181
|
+
class RobotStillStartingMissionException(RobotException):
|
|
182
|
+
def __init__(self, error_description: str) -> None:
|
|
183
|
+
super().__init__(
|
|
184
|
+
error_reason=ErrorReason.RobotStillStartingMissionException,
|
|
185
|
+
error_description=error_description,
|
|
186
|
+
)
|
|
187
|
+
|
|
188
|
+
pass
|
|
189
|
+
|
|
190
|
+
|
|
177
191
|
# An exception which should be thrown by the robot package if it is unable to retrieve
|
|
178
192
|
# telemetry data. It should be used exclusively by the telemetry publishers and their
|
|
179
193
|
# functions.
|
|
@@ -5,7 +5,7 @@ from pydantic import BaseModel, Field
|
|
|
5
5
|
|
|
6
6
|
from robot_interface.models.exceptions.robot_exceptions import ErrorMessage
|
|
7
7
|
from robot_interface.models.mission.status import MissionStatus
|
|
8
|
-
from robot_interface.models.mission.task import TASKS
|
|
8
|
+
from robot_interface.models.mission.task import TASKS, TaskTypes
|
|
9
9
|
from robot_interface.utilities.uuid_string_factory import uuid4_string
|
|
10
10
|
|
|
11
11
|
|
|
@@ -16,3 +16,10 @@ class Mission(BaseModel):
|
|
|
16
16
|
start_pose: Optional[Pose] = Field(default=None, frozen=True)
|
|
17
17
|
status: MissionStatus = MissionStatus.NotStarted
|
|
18
18
|
error_message: Optional[ErrorMessage] = Field(default=None)
|
|
19
|
+
|
|
20
|
+
def _is_return_to_home_mission(self) -> bool:
|
|
21
|
+
if len(self.tasks) != 1:
|
|
22
|
+
return False
|
|
23
|
+
if self.tasks[0].type != TaskTypes.ReturnToHome:
|
|
24
|
+
return False
|
|
25
|
+
return True
|
isar/state_machine/states/off.py
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import logging
|
|
2
|
-
from typing import TYPE_CHECKING
|
|
3
|
-
|
|
4
|
-
from transitions import State
|
|
5
|
-
|
|
6
|
-
if TYPE_CHECKING:
|
|
7
|
-
from isar.state_machine.state_machine import StateMachine
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
class Off(State):
|
|
11
|
-
def __init__(self, state_machine: "StateMachine"):
|
|
12
|
-
super().__init__(name="off", on_enter=self.start)
|
|
13
|
-
self.logger = logging.getLogger("state_machine")
|
|
14
|
-
self.state_machine: "StateMachine" = state_machine
|
|
15
|
-
|
|
16
|
-
def start(self):
|
|
17
|
-
self.state_machine.update_state()
|
|
18
|
-
self.logger.info("State: %s", self.state_machine.current_state)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|