From: Bruce Winter <winter@ch...> - 2004-10-28 02:45:46
> $self-> add ($id . $hc . 'L', 'dim');
> $self-> add ($id . $hc . 'M', 'brighten');
> If you remove these two lines
> a two member group dim command gets processed
> With the two lines included the data buffer gets
> "chunked" into 2 and 4 character snippets
> XA5AL becomes a valid serial_item. This leaves the dim
> level left as an umatched item.
> Without the above lines I get a
> 10/27/04 05:28:30 PM XA2A-25: bedroom_light -25
> 10/27/04 05:28:30 PM XA5A-25: livingroom_light -25
> 10/27/04 05:28:30 PM XA5: livingroom_light manual
> 10/27/04 05:28:29 PM XA2: bedroom_light manual
> Which is exactly as I would expect.
> Question :
> Why were those two lines added and what will I break
> if I remove them?
Without those lines, then "set $light DIM" or BRIGHTEN would not work.
But I think we can keep the dim/brighen states, but still fix the bug you
found, but changing those 2 lines to this:
$self-> add ($id . $hc . '+34', 'brighten');
$self-> add ($id . $hc . '-34', 'dim');