Commit 50cbae3f0d9e20c7d6c047c6ecd3818ffef3d795
1 parent
12c6569f
Exists in
dev
big update du diagramme objet du Majordome
Showing
2 changed files
with
59 additions
and
35 deletions
Show diff stats
src/core/pyros_django/majordome/doc/AgentMajordome_object_diag.pu
1 | 1 | |
2 | 2 | @startuml |
3 | 3 | |
4 | +!include <tupadr3/common> | |
5 | +!include <tupadr3/font-awesome/server> | |
6 | + | |
7 | + | |
8 | + | |
4 | 9 | /' |
5 | 10 | UML class Diagram : can be displayed with PlantUML (plugin for Eclipse or for PyCharm) |
6 | 11 | |
... | ... | @@ -27,51 +32,69 @@ title |
27 | 32 | __**AgentMajordome object example diagram (context)**__ |
28 | 33 | end title |
29 | 34 | |
35 | +/' Allow to mix object/class diagram with other symbols like a "server" symbol '/ | |
36 | +allowmixing | |
37 | + | |
38 | +FA_SERVER(sbig_device,SBIG detector) #Red | |
39 | +FA_SERVER(gemini_device,Gemini telescope) #Red | |
30 | 40 | |
31 | 41 | |
32 | 42 | /' Abstract Devices Controllers '/ |
33 | 43 | |
34 | 44 | object AgentMajordome <<Singleton>> #yellow |
35 | 45 | |
36 | -object AgentDeviceTelescope | |
37 | -object AgentDeviceFilterSelector | |
38 | -object AgentDeviceShutter | |
39 | -object AgentDeviceSensor | |
46 | +object AgentDeviceTelescope1 | |
47 | +object AgentDeviceFilterSelector1 | |
48 | +object AgentDeviceShutter1 | |
49 | +object AgentDeviceSensor1 | |
50 | +object AgentDeviceShutter2 | |
51 | + | |
52 | + | |
53 | + | |
54 | +/' Use l,r,u,d for left, right, up, or down row alignement '/ | |
55 | +AgentMajordome o-d- AgentDeviceFilterSelector1 | |
56 | +AgentMajordome o-d- AgentDeviceShutter1 | |
57 | +AgentMajordome o-d- AgentDeviceSensor1 | |
58 | +AgentMajordome o-d- AgentDeviceTelescope1 | |
59 | +AgentMajordome o-d- AgentDeviceShutter2 | |
40 | 60 | |
61 | +object AgentDeviceSBIG_CXZ347 <<Singleton>> | |
41 | 62 | |
42 | -AgentMajordome o-> AgentDeviceFilterSelector | |
43 | -AgentMajordome o-> AgentDeviceShutter | |
44 | -AgentMajordome o-> AgentDeviceSensor | |
45 | -AgentMajordome o-> AgentDeviceTelescope | |
63 | +AgentDeviceFilterSelector1 --> AgentDeviceSBIG_CXZ347 :alias | |
64 | +AgentDeviceShutter1 --> AgentDeviceSBIG_CXZ347 :alias | |
65 | +AgentDeviceSensor1 --> AgentDeviceSBIG_CXZ347 :alias | |
66 | +object AgentDeviceTelescopeGemini_A1CZ3 | |
67 | +AgentDeviceTelescope1 --> AgentDeviceTelescopeGemini_A1CZ3 :alias | |
46 | 68 | |
47 | -object AgentDeviceSBIG <<Singleton>> | |
48 | 69 | |
49 | -AgentDeviceFilterSelector --> AgentDeviceSBIG :is a | |
50 | -AgentDeviceShutter --> AgentDeviceSBIG :is a | |
51 | -AgentDeviceSensor --> AgentDeviceSBIG :is a | |
52 | -object AgentDeviceTelescopeGemini <<Singleton>> | |
53 | -AgentDeviceTelescope --> AgentDeviceTelescopeGemini :is a | |
70 | +class DeviceControllerAbstract #lightblue | |
71 | +class DeviceControllerFilterSelector #lightblue | |
72 | +class DeviceControllerDetectorShutter #lightblue | |
73 | +class DeviceControllerDetectorSensor #lightblue | |
54 | 74 | |
75 | +object DeviceControllerSBIG <<Singleton>> #lightblue | |
76 | +AgentDeviceSBIG_CXZ347 --> DeviceControllerSBIG :use | |
55 | 77 | |
56 | -class FilterSelectorController #lightblue | |
57 | -class DetectorShutterController #lightblue | |
58 | -class DetectorSensorController #lightblue | |
78 | +object DeviceSimulatorSBIG #lightblue | |
79 | +DeviceControllerSBIG o- DeviceSimulatorSBIG | |
80 | +DeviceControllerSBIG <---> sbig_device :> channel/socket | |
59 | 81 | |
60 | -object SBIGController <<Singleton>> #lightblue | |
61 | -AgentDeviceSBIG --> SBIGController :use | |
62 | -SBIGController --|> FilterSelectorController | |
63 | -SBIGController --|> DetectorShutterController | |
64 | -SBIGController --|> DetectorSensorController | |
82 | +DeviceControllerSBIG --|> DeviceControllerDetectorSensor | |
83 | +DeviceControllerSBIG --|> DeviceControllerDetectorShutter | |
84 | +DeviceControllerSBIG --|> DeviceControllerFilterSelector | |
65 | 85 | |
66 | -object SBIGSimulator #lightblue | |
67 | -SBIGController o-- SBIGSimulator | |
86 | +DeviceControllerDetectorSensor --|> DeviceControllerAbstract | |
87 | +DeviceControllerDetectorShutter --|> DeviceControllerAbstract | |
88 | +DeviceControllerFilterSelector --|> DeviceControllerAbstract | |
68 | 89 | |
69 | -class TelescopeController #lightblue | |
70 | -object TelescopeGeminiController <<Singleton>> #lightblue | |
71 | -AgentDeviceTelescopeGemini --> TelescopeGeminiController :use | |
72 | -TelescopeGeminiController --|> TelescopeController | |
73 | -object TelescopeGeminiSimulator #lightblue | |
74 | -TelescopeGeminiController o-- TelescopeGeminiSimulator | |
75 | 90 | |
91 | +class DeviceControllerTelescope #lightblue | |
92 | +object DeviceControllerTelescopeGemini <<Singleton>> #lightblue | |
93 | +AgentDeviceTelescopeGemini_A1CZ3 --> DeviceControllerTelescopeGemini :use | |
94 | +object DeviceSimulatorTelescopeGemini #lightblue | |
95 | +DeviceControllerTelescopeGemini o-.left. DeviceSimulatorTelescopeGemini | |
96 | +DeviceControllerTelescopeGemini <---> gemini_device :> channel/socket | |
97 | +DeviceControllerTelescopeGemini --|> DeviceControllerTelescope | |
98 | +DeviceControllerTelescope --|> DeviceControllerAbstract | |
76 | 99 | |
77 | 100 | @enduml | ... | ... |
src/devices_controller/devices_controller_concrete/device_controller_SBIG/device_controller_SBIG.py
... | ... | @@ -28,10 +28,10 @@ sys.path.append('../../../..') |
28 | 28 | |
29 | 29 | #TODO: Heritage ou plutot COMPOSITION ? |
30 | 30 | # The SBIG controller has 3 capabilities : filter selector, detector sensor, and detector shutter |
31 | -from devices_controller.devices_controller_abstract_component.device_controller_abstract import * | |
32 | -from devices_controller.devices_controller_abstract_component.device_controller_filter_selector import * | |
33 | -from devices_controller.devices_controller_abstract_component.device_controller_detector_sensor import * | |
34 | -from devices_controller.devices_controller_abstract_component.device_controller_detector_shutter import * | |
31 | +#from devices_controller.devices_controller_abstract_component.device_controller_abstract import * | |
32 | +from devices_controller.devices_controller_abstract_component.device_controller_filter_selector import DeviceControllerFilterSelector | |
33 | +from devices_controller.devices_controller_abstract_component.device_controller_detector_sensor import DeviceControllerDetectorSensor | |
34 | +from devices_controller.devices_controller_abstract_component.device_controller_detector_shutter import DeviceControllerDetectorShutter | |
35 | 35 | |
36 | 36 | # Default timeouts |
37 | 37 | TIMEOUT_SEND = 10 |
... | ... | @@ -49,7 +49,8 @@ COMMAND6_SIMPLE = '6' |
49 | 49 | |
50 | 50 | ##class SocketClientTelescopeGEMINI(SocketClientTelescopeAbstract): |
51 | 51 | #class TelescopeControllerGEMINI(TelescopeControllerAbstract): |
52 | -class DeviceControllerSBIG(DeviceControllerAbstract): | |
52 | +#class DeviceControllerSBIG(DeviceControllerAbstract): | |
53 | +class DeviceControllerSBIG(DeviceControllerDetectorSensor, DeviceControllerDetectorShutter, DeviceControllerFilterSelector): | |
53 | 54 | |
54 | 55 | # STAMP : |
55 | 56 | # 00 00 00 00 00 00 00' (8 bytes from '00' to 'FF', 1st one is LOW BYTE) | ... | ... |