外设_fubo_seq.svg 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <?xml version="1.0" encoding="UTF-8" standalone="no"?><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" contentStyleType="text/css" height="893px" preserveAspectRatio="none" style="width:596px;height:893px;background:#FFFFFF;" version="1.1" viewBox="0 0 596 893" width="596px" zoomAndPan="magnify"><defs/><g><rect fill="none" height="29.1201" id="_title" style="stroke:none;stroke-width:1.0;" width="115" x="242" y="10"/><text fill="#000000" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="105" x="247" y="31.0439">富伯工作时序图</text><rect fill="#FFFFFF" height="433.0986" style="stroke:#FFFFFF;stroke-width:1.0;" width="10" x="330" y="115.8745"/><line style="stroke:#181818;stroke-width:1.0;" x1="330" x2="330" y1="115.8745" y2="548.9731"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="340" y1="115.8745" y2="548.9731"/><line style="stroke:#181818;stroke-width:1.0;" x1="330" x2="340" y1="115.8745" y2="115.8745"/><rect fill="#FFFFFF" height="251.2808" style="stroke:#FFFFFF;stroke-width:1.0;" width="10" x="330" y="591.9961"/><line style="stroke:#181818;stroke-width:1.0;" x1="330" x2="330" y1="591.9961" y2="843.2769"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="340" y1="591.9961" y2="843.2769"/><rect fill="none" height="223.5723" style="stroke:#000000;stroke-width:1.5;" width="580" x="10" y="130.8745"/><rect fill="none" height="126.3091" style="stroke:#000000;stroke-width:1.5;" width="268" x="216" y="221.1377"/><rect fill="none" height="83.2632" style="stroke:#000000;stroke-width:1.5;" width="444" x="10" y="368.4468"/><rect fill="none" height="195.7949" style="stroke:#000000;stroke-width:1.5;" width="580" x="10" y="465.71"/><rect fill="none" height="159.772" style="stroke:#000000;stroke-width:1.5;" width="580" x="10" y="675.5049"/><line style="stroke:#181818;stroke-width:0.5;stroke-dasharray:5.0,5.0;" x1="118" x2="118" y1="82.1201" y2="548.9731"/><line style="stroke:#A80036;stroke-width:1.0;stroke-dasharray:1.0,4.0;" x1="118" x2="118" y1="548.9731" y2="591.9961"/><line style="stroke:#181818;stroke-width:0.5;stroke-dasharray:5.0,5.0;" x1="118" x2="118" y1="591.9961" y2="852.2769"/><line style="stroke:#181818;stroke-width:0.5;stroke-dasharray:5.0,5.0;" x1="335" x2="335" y1="82.1201" y2="548.9731"/><line style="stroke:#A80036;stroke-width:1.0;stroke-dasharray:1.0,4.0;" x1="335" x2="335" y1="548.9731" y2="591.9961"/><line style="stroke:#181818;stroke-width:0.5;stroke-dasharray:5.0,5.0;" x1="335" x2="335" y1="591.9961" y2="852.2769"/><line style="stroke:#181818;stroke-width:0.5;stroke-dasharray:5.0,5.0;" x1="559" x2="559" y1="82.1201" y2="548.9731"/><line style="stroke:#A80036;stroke-width:1.0;stroke-dasharray:1.0,4.0;" x1="559" x2="559" y1="548.9731" y2="591.9961"/><line style="stroke:#181818;stroke-width:0.5;stroke-dasharray:5.0,5.0;" x1="559" x2="559" y1="591.9961" y2="852.2769"/><rect fill="#E2E2F0" height="36" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:0.5;" width="196" x="20" y="45.1201"/><ellipse cx="38" cy="63.1201" fill="#ADD1B2" rx="11" ry="11" style="stroke:#181818;stroke-width:1.0;"/><path d="M36.5781,68.4795 Q34.7188,68.4795 33.625,67.0889 Q32.5313,65.6982 32.5313,62.7139 Q32.5313,60.1826 33.6953,58.5264 Q34.8594,56.8701 36.8438,56.8701 Q38.3125,56.8701 38.7813,56.9951 Q39.25,57.1982 39.25,57.1982 Q39.25,57.1982 39.25,57.1279 Q39.25,57.0576 39.8594,56.1357 L40.9063,59.792 L39.5781,60.1982 Q39.1094,58.6514 38.4453,57.9873 Q37.7813,57.3232 36.7188,57.3232 Q36.3281,57.3232 35.5625,58.8545 Q34.7969,60.3857 34.7969,62.6357 Q34.7969,65.1045 35.4609,66.4951 Q36.125,67.8857 36.6563,67.8857 Q37.7188,67.8857 38.4766,67.1201 Q39.2344,66.3545 39.5781,64.6982 L40.9063,65.292 Q40.5781,66.6982 39.6797,67.5889 Q38.7813,68.4795 36.5781,68.4795 Z " fill="#000000"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="154" x="55" y="68.1641">PeripheralHandManager</text><rect fill="#E2E2F0" height="36" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:0.5;" width="196" x="20" y="851.2769"/><ellipse cx="38" cy="869.2769" fill="#ADD1B2" rx="11" ry="11" style="stroke:#181818;stroke-width:1.0;"/><path d="M36.5781,874.6362 Q34.7188,874.6362 33.625,873.2456 Q32.5313,871.855 32.5313,868.8706 Q32.5313,866.3394 33.6953,864.6831 Q34.8594,863.0269 36.8438,863.0269 Q38.3125,863.0269 38.7813,863.1519 Q39.25,863.355 39.25,863.355 Q39.25,863.355 39.25,863.2847 Q39.25,863.2144 39.8594,862.2925 L40.9063,865.9487 L39.5781,866.355 Q39.1094,864.8081 38.4453,864.144 Q37.7813,863.48 36.7188,863.48 Q36.3281,863.48 35.5625,865.0112 Q34.7969,866.5425 34.7969,868.7925 Q34.7969,871.2612 35.4609,872.6519 Q36.125,874.0425 36.6563,874.0425 Q37.7188,874.0425 38.4766,873.2769 Q39.2344,872.5112 39.5781,870.855 L40.9063,871.4487 Q40.5781,872.855 39.6797,873.7456 Q38.7813,874.6362 36.5781,874.6362 Z " fill="#000000"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="154" x="55" y="874.3208">PeripheralHandManager</text><rect fill="#E2E2F0" height="36" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:0.5;" width="218" x="226" y="45.1201"/><ellipse cx="244" cy="63.1201" fill="#ADD1B2" rx="11" ry="11" style="stroke:#181818;stroke-width:1.0;"/><path d="M242.5781,68.4795 Q240.7188,68.4795 239.625,67.0889 Q238.5313,65.6982 238.5313,62.7139 Q238.5313,60.1826 239.6953,58.5264 Q240.8594,56.8701 242.8438,56.8701 Q244.3125,56.8701 244.7813,56.9951 Q245.25,57.1982 245.25,57.1982 Q245.25,57.1982 245.25,57.1279 Q245.25,57.0576 245.8594,56.1357 L246.9063,59.792 L245.5781,60.1982 Q245.1094,58.6514 244.4453,57.9873 Q243.7813,57.3232 242.7188,57.3232 Q242.3281,57.3232 241.5625,58.8545 Q240.7969,60.3857 240.7969,62.6357 Q240.7969,65.1045 241.4609,66.4951 Q242.125,67.8857 242.6563,67.8857 Q243.7188,67.8857 244.4766,67.1201 Q245.2344,66.3545 245.5781,64.6982 L246.9063,65.292 Q246.5781,66.6982 245.6797,67.5889 Q244.7813,68.4795 242.5781,68.4795 Z " fill="#000000"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="176" x="261" y="68.1641">FuboPneumaticFingerClient</text><rect fill="#E2E2F0" height="36" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:0.5;" width="218" x="226" y="851.2769"/><ellipse cx="244" cy="869.2769" fill="#ADD1B2" rx="11" ry="11" style="stroke:#181818;stroke-width:1.0;"/><path d="M242.5781,874.6362 Q240.7188,874.6362 239.625,873.2456 Q238.5313,871.855 238.5313,868.8706 Q238.5313,866.3394 239.6953,864.6831 Q240.8594,863.0269 242.8438,863.0269 Q244.3125,863.0269 244.7813,863.1519 Q245.25,863.355 245.25,863.355 Q245.25,863.355 245.25,863.2847 Q245.25,863.2144 245.8594,862.2925 L246.9063,865.9487 L245.5781,866.355 Q245.1094,864.8081 244.4453,864.144 Q243.7813,863.48 242.7188,863.48 Q242.3281,863.48 241.5625,865.0112 Q240.7969,866.5425 240.7969,868.7925 Q240.7969,871.2612 241.4609,872.6519 Q242.125,874.0425 242.6563,874.0425 Q243.7188,874.0425 244.4766,873.2769 Q245.2344,872.5112 245.5781,870.855 L246.9063,871.4487 Q246.5781,872.855 245.6797,873.7456 Q244.7813,874.6362 242.5781,874.6362 Z " fill="#000000"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="176" x="261" y="874.3208">FuboPneumaticFingerClient</text><rect fill="#E2E2F0" height="33.1201" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:0.5;" width="42" x="538" y="48"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="28" x="545" y="71.0439">设备</text><rect fill="#E2E2F0" height="33.1201" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:0.5;" width="42" x="538" y="851.2769"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="28" x="545" y="874.3208">设备</text><rect fill="#FFFFFF" height="433.0986" style="stroke:#FFFFFF;stroke-width:1.0;" width="10" x="330" y="115.8745"/><line style="stroke:#181818;stroke-width:1.0;" x1="330" x2="330" y1="115.8745" y2="548.9731"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="340" y1="115.8745" y2="548.9731"/><line style="stroke:#181818;stroke-width:1.0;" x1="330" x2="340" y1="115.8745" y2="115.8745"/><rect fill="#FFFFFF" height="251.2808" style="stroke:#FFFFFF;stroke-width:1.0;" width="10" x="330" y="591.9961"/><line style="stroke:#181818;stroke-width:1.0;" x1="330" x2="330" y1="591.9961" y2="843.2769"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="340" y1="591.9961" y2="843.2769"/><polygon fill="#181818" points="318,111.8745,328,115.8745,318,119.8745,322,115.8745" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="118" x2="324" y1="115.8745" y2="115.8745"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="70" x="125" y="111.0181">初始化client</text><path d="M10,130.8745 L125,130.8745 L125,140.6289 L115,150.6289 L10,150.6289 L10,130.8745 " fill="#EEEEEE" style="stroke:#000000;stroke-width:1.5;"/><rect fill="none" height="223.5723" style="stroke:#000000;stroke-width:1.5;" width="580" x="10" y="130.8745"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="70" x="25" y="146.7725">初始化连接</text><polygon fill="#181818" points="318,170.3833,328,174.3833,318,178.3833,322,174.3833" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="118" x2="324" y1="174.3833" y2="174.3833"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="25" x="125" y="169.5269">init()</text><polygon fill="#181818" points="547,202.1377,557,206.1377,547,210.1377,551,206.1377" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="553" y1="206.1377" y2="206.1377"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="195" x="347" y="201.2813">按串口和既定的其他参数连接串口</text><path d="M216,221.1377 L277,221.1377 L277,230.8921 L267,240.8921 L216,240.8921 L216,221.1377 " fill="#EEEEEE" style="stroke:#000000;stroke-width:1.5;"/><rect fill="none" height="126.3091" style="stroke:#000000;stroke-width:1.5;" width="268" x="216" y="221.1377"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="16" x="231" y="237.0356">alt</text><text fill="#000000" font-family="sans-serif" font-size="11" font-weight="bold" lengthAdjust="spacing" textLength="79" x="292" y="235.7437">[串口 is_open]</text><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="382" y1="264.6694" y2="264.6694"/><line style="stroke:#181818;stroke-width:1.0;" x1="382" x2="382" y1="264.6694" y2="277.6694"/><line style="stroke:#181818;stroke-width:1.0;" x1="341" x2="382" y1="277.6694" y2="277.6694"/><polygon fill="#181818" points="351,273.6694,341,277.6694,351,281.6694,347,277.6694" style="stroke:#181818;stroke-width:1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="118" x="347" y="259.813">is_connected = True</text><line style="stroke:#000000;stroke-width:1.0;stroke-dasharray:2.0,2.0;" x1="216" x2="484" y1="286.6694" y2="286.6694"/><text fill="#000000" font-family="sans-serif" font-size="11" font-weight="bold" lengthAdjust="spacing" textLength="56" x="221" y="299.2754">[发送失败]</text><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="382" y1="326.4468" y2="326.4468"/><line style="stroke:#181818;stroke-width:1.0;" x1="382" x2="382" y1="326.4468" y2="339.4468"/><line style="stroke:#181818;stroke-width:1.0;" x1="341" x2="382" y1="339.4468" y2="339.4468"/><polygon fill="#181818" points="351,335.4468,341,339.4468,351,343.4468,347,339.4468" style="stroke:#181818;stroke-width:1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="125" x="347" y="321.5903">is_connected = False</text><path d="M10,368.4468 L139,368.4468 L139,378.2012 L129,388.2012 L10,388.2012 L10,368.4468 " fill="#EEEEEE" style="stroke:#000000;stroke-width:1.5;"/><rect fill="none" height="83.2632" style="stroke:#000000;stroke-width:1.5;" width="444" x="10" y="368.4468"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="84" x="25" y="384.3447">获取连接状态</text><polygon fill="#181818" points="318,407.9556,328,411.9556,318,415.9556,322,411.9556" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="118" x2="324" y1="411.9556" y2="411.9556"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="44" x="125" y="407.0991">status()</text><polygon fill="#181818" points="129,439.71,119,443.71,129,447.71,125,443.71" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;stroke-dasharray:2.0,2.0;" x1="123" x2="329" y1="443.71" y2="443.71"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="77" x="135" y="438.8535">is_connected</text><path d="M10,465.71 L139,465.71 L139,475.4644 L129,485.4644 L10,485.4644 L10,465.71 " fill="#EEEEEE" style="stroke:#000000;stroke-width:1.5;"/><rect fill="none" height="195.7949" style="stroke:#000000;stroke-width:1.5;" width="580" x="10" y="465.71"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="84" x="25" y="481.6079">发送控制指令</text><polygon fill="#181818" points="318,505.2188,328,509.2188,318,513.2188,322,509.2188" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="118" x2="324" y1="509.2188" y2="509.2188"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="34" x="125" y="504.3623">start()</text><polygon fill="#181818" points="547,536.9731,557,540.9731,547,544.9731,551,540.9731" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="553" y1="540.9731" y2="540.9731"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="20" x="347" y="536.1167">flex</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacing" textLength="26" x="324" y="575.5791">7s 后</text><polygon fill="#181818" points="547,611.7505,557,615.7505,547,619.7505,551,615.7505" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="553" y1="615.7505" y2="615.7505"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="39" x="347" y="610.894">extend</text><polygon fill="#181818" points="129,646.5049,119,650.5049,129,654.5049,125,650.5049" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;stroke-dasharray:2.0,2.0;" x1="123" x2="329" y1="650.5049" y2="650.5049"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="7" x="135" y="645.6484">1</text><path d="M345,628.7505 L345,655.7505 L561,655.7505 L561,638.7505 L551,628.7505 L345,628.7505 " fill="#FFAAAA" style="stroke:#181818;stroke-width:0.5;"/><path d="M551,628.7505 L551,638.7505 L561,638.7505 L551,628.7505 " fill="#FFAAAA" style="stroke:#181818;stroke-width:0.5;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="195" x="351" y="648.6484">反馈不稳定,所以没使用设备反馈</text><path d="M10,675.5049 L111,675.5049 L111,685.2593 L101,695.2593 L10,695.2593 L10,675.5049 " fill="#EEEEEE" style="stroke:#000000;stroke-width:1.5;"/><rect fill="none" height="159.772" style="stroke:#000000;stroke-width:1.5;" width="580" x="10" y="675.5049"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="56" x="25" y="691.4028">关闭连接</text><polygon fill="#181818" points="318,715.0137,328,719.0137,318,723.0137,322,719.0137" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="118" x2="324" y1="719.0137" y2="719.0137"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="39" x="125" y="714.1572">close()</text><polygon fill="#181818" points="547,746.7681,557,750.7681,547,754.7681,551,750.7681" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="553" y1="750.7681" y2="750.7681"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="78" x="347" y="745.9116">断开串口连接</text><line style="stroke:#181818;stroke-width:1.0;" x1="340" x2="382" y1="782.5225" y2="782.5225"/><line style="stroke:#181818;stroke-width:1.0;" x1="382" x2="382" y1="782.5225" y2="795.5225"/><line style="stroke:#181818;stroke-width:1.0;" x1="341" x2="382" y1="795.5225" y2="795.5225"/><polygon fill="#181818" points="351,791.5225,341,795.5225,351,799.5225,347,795.5225" style="stroke:#181818;stroke-width:1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="125" x="347" y="777.666">is_connected = False</text><polygon fill="#181818" points="129,823.2769,119,827.2769,129,831.2769,125,827.2769" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;stroke-dasharray:2.0,2.0;" x1="123" x2="329" y1="827.2769" y2="827.2769"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="77" x="135" y="822.4204">is_connected</text><!--MD5=[567370278814f9c85717119626fad51d]
  2. @startuml
  3. title 富伯工作时序图
  4. hide unlinked
  5. participant PeripheralHandManager << (C,#ADD1B2) >>
  6. participant FuboPneumaticFingerClient << (C,#ADD1B2) >>
  7. participant 设备
  8. PeripheralHandManager -> FuboPneumaticFingerClient: 初始化client
  9. activate FuboPneumaticFingerClient
  10. group 初始化连接
  11. PeripheralHandManager -> FuboPneumaticFingerClient: init()
  12. FuboPneumaticFingerClient -> 设备: 按串口和既定的其他参数连接串口
  13. alt 串口 is_open
  14. FuboPneumaticFingerClient -> FuboPneumaticFingerClient: is_connected = True
  15. else 发送失败
  16. FuboPneumaticFingerClient -> FuboPneumaticFingerClient: is_connected = False
  17. end
  18. end
  19. group 获取连接状态
  20. PeripheralHandManager -> FuboPneumaticFingerClient: status()
  21. FuboPneumaticFingerClient - -> PeripheralHandManager : is_connected
  22. end
  23. group 发送控制指令
  24. PeripheralHandManager -> FuboPneumaticFingerClient: start()
  25. FuboPneumaticFingerClient -> 设备: flex
  26. ...7s 后 ...
  27. FuboPneumaticFingerClient -> 设备: extend
  28. FuboPneumaticFingerClient - -> PeripheralHandManager : 1
  29. note right #FFAAAA: 反馈不稳定,所以没使用设备反馈
  30. end
  31. group 关闭连接
  32. PeripheralHandManager -> FuboPneumaticFingerClient: close()
  33. FuboPneumaticFingerClient -> 设备: 断开串口连接
  34. FuboPneumaticFingerClient -> FuboPneumaticFingerClient: is_connected = False
  35. FuboPneumaticFingerClient - -> PeripheralHandManager : is_connected
  36. end
  37. @enduml
  38. PlantUML version 1.2022.7(Tue Aug 23 01:01:30 CST 2022)
  39. (GPL source distribution)
  40. Java Runtime: Java(TM) SE Runtime Environment
  41. JVM: Java HotSpot(TM) 64-Bit Server VM
  42. Default Encoding: GBK
  43. Language: zh
  44. Country: CN
  45. --></g></svg>