OSDN Git Service

シーケンス切り替え時に通信のログダンプを表示しなくした。
[gokigen/Gr2Control.git] / app / src / main / java / net / osdn / gokigen / gr2control / camera / fuji_x / wrapper / command / messages / changemode / ChangeToPlayback5th.java
1 package net.osdn.gokigen.gr2control.camera.fuji_x.wrapper.command.messages.changemode;
2
3 import androidx.annotation.NonNull;
4
5 import net.osdn.gokigen.gr2control.camera.fuji_x.wrapper.command.IFujiXCommandCallback;
6 import net.osdn.gokigen.gr2control.camera.fuji_x.wrapper.command.IFujiXMessages;
7 import net.osdn.gokigen.gr2control.camera.fuji_x.wrapper.command.messages.FujiXCommandBase;
8
9 public class ChangeToPlayback5th extends FujiXCommandBase
10 {
11     private final int holdId;
12     private final IFujiXCommandCallback callback;
13
14     public ChangeToPlayback5th(int holdId, @NonNull IFujiXCommandCallback callback)
15     {
16         this.holdId = holdId;
17         this.callback = callback;
18     }
19
20     @Override
21     public IFujiXCommandCallback responseCallback()
22     {
23         return (callback);
24     }
25
26     @Override
27     public int getId()
28     {
29         return (IFujiXMessages.SEQ_CHANGE_TO_PLAYBACK_5TH);
30     }
31
32     @Override
33     public byte[] commandBody()
34     {
35         return (new byte[] {
36                 // message_header.index : uint16 (0: terminate, 2: two_part_message, 1: other)
37                 (byte)0x01, (byte)0x00,
38
39                 // message_header.type : two_part (0x1016) : SetDevicePropValue
40                 (byte)0x16, (byte)0x10,
41
42                 // sequence number
43                 (byte)0x00, (byte)0x00, (byte)0x00, (byte)0x00,
44
45                 // data ...
46                 (byte)0x25, (byte)0xdf, (byte)0x00, (byte)0x00,
47         });
48     }
49
50     @Override
51     public byte[] commandBody2()
52     {
53         return (new byte[] {
54                 // message_header.index : uint16 (0: terminate, 2: two_part_message, 1: other)
55                 (byte)0x02, (byte)0x00,
56
57                 // message_header.type : two_part (0x1016) : SetDevicePropValue
58                 (byte)0x16, (byte)0x10,
59
60                 // sequence number
61                 (byte)0x00, (byte)0x00, (byte)0x00, (byte)0x00,
62
63                 // data ...
64                 //(byte)0x02, (byte)0x00,
65                 (byte)0x04, (byte)0x00,
66
67         });
68     }
69
70     @Override
71     public int getHoldId()
72     {
73         return (holdId);
74     }
75
76     @Override
77     public boolean isHold()
78     {
79         return (true);
80     }
81
82     @Override
83     public boolean isRelease()
84     {
85         return (false);
86     }
87
88     @Override
89     public boolean dumpLog()
90     {
91         return (false);
92     }
93 }