PARAMETER_DESCRIPTION data type semantics
Hi,
I have two questions: 1) the data type description refers to arrays rather than single elements. Does this mean, that given a data type of say DWORD, the PDLen must be a fixed multiple of 4 indicating a fixed size DWORD array or should it be always 4, indicating a single DWORD (and arrays are not allowed at all) 2) I have a lamp here that returns a PARAMETER_DESCRIPTION response with a PDlen=2 and 0x0006 as the actual data. Did I miss something or is this just plain wrong ? Any help is appreciated :) Best, Tim |
Tim,
The PDL is always the number of bytes, regardless of the data type. PDL Size is used to tell the controller what to expect the PDL to be for a GET_COMMAND_RESPONSE or SET_COMMAND_RESPONSE message. There are a number of flaws you'll find documented on here with the Parameter Description message but it still has some basic uses. Strictly speaking by Table A-15, you can have arrays of values, but most commonly it will be an array size of 1. i.e. a single data value. In the case of a single DWORD value, the PDL would be 0x04 with leading 0's to pad out the field. A PDL of 0x02 and an actual value of 0x0006 would indicate a 16-bit value. If the PDL is 0x04 then the actual value would be: 0x00000006. |
Thanks for the clarification!
Just in case anyone cares: (2) was my bad because the response was actually a NAK response and thus did not contain a PARAMETER_DESCRIPTION at all. |
Note :
Quote:
Thus I found Scott's original response a bit misleading. As has been documented elsewhere, the format of this PID is severely limited, and probably the best approach is just to use it to send a text description of your Manufacturer specific PID. Peter Willis |
Peter, there are 2 PDL fields involved here. 1 is the PDL for the PARAMETER_DESCRIPTION response itself. The other is the PDL that is included in the parameter description message that defines what the PDL is for a response for the parameter ID that is being described. What we were talking about is the latter.
|
All times are GMT -6. The time now is 06:44 AM. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.