Class: SDN::Message::ILT2::PostMotorSettings
- Inherits:
-
UnknownMessage
- Object
- SDN::Message
- UnknownMessage
- SDN::Message::ILT2::PostMotorSettings
- Defined in:
- lib/sdn/message/ilt2/post.rb
Constant Summary collapse
- MSG =
0x62- PARAMS_LENGTH =
3
Instance Attribute Summary collapse
-
#limit ⇒ Object
Returns the value of attribute limit.
Attributes inherited from UnknownMessage
Attributes inherited from SDN::Message
#ack_requested, #dest, #node_type, #src
Instance Method Summary collapse
-
#initialize(limit = nil, **kwargs) ⇒ PostMotorSettings
constructor
A new instance of PostMotorSettings.
- #params ⇒ Object
- #parse(params) ⇒ Object
Methods inherited from UnknownMessage
Methods inherited from SDN::Message
#==, #class_inspect, expected_response?, inherited, #inspect, parse, #serialize
Methods included from Helpers
#checksum, #from_number, #from_string, #group_address?, #node_type_from_number, #node_type_to_number, #node_type_to_string, #parse_address, #print_address, #to_number, #to_string, #transform_param
Constructor Details
#initialize(limit = nil, **kwargs) ⇒ PostMotorSettings
Returns a new instance of PostMotorSettings.
109 110 111 112 |
# File 'lib/sdn/message/ilt2/post.rb', line 109 def initialize(limit = nil, **kwargs) super(**kwargs) self.limit = limit end |
Instance Attribute Details
#limit ⇒ Object
Returns the value of attribute limit.
107 108 109 |
# File 'lib/sdn/message/ilt2/post.rb', line 107 def limit @limit end |
Instance Method Details
#params ⇒ Object
119 120 121 |
# File 'lib/sdn/message/ilt2/post.rb', line 119 def params transform_param(0) + from_number(limit, 2) end |
#parse(params) ⇒ Object
114 115 116 117 |
# File 'lib/sdn/message/ilt2/post.rb', line 114 def parse(params) super self.limit = to_number(params[1..2]) end |