Stack events
Denis
Posts: 163
Hi
I would like to know, when we have 2 or more touch panel in the same projetc, each touch panel have some common devices, if it's better to do differents program for each panel or if we can stack buttons event
ex:
BUTTON_EVENT [dvTP_STORES_PISCINE,4]
BUTTON_EVENT [dvTPK_STORES_PISCINE,4]
or complete program for each button of each device
I would like to know, when we have 2 or more touch panel in the same projetc, each touch panel have some common devices, if it's better to do differents program for each panel or if we can stack buttons event
ex:
BUTTON_EVENT [dvTP_STORES_PISCINE,4]
BUTTON_EVENT [dvTPK_STORES_PISCINE,4]
or complete program for each button of each device
0
Comments
You can still address panels separately:
- Chip
Internally all forms resolve to the same code, so the better way is the one you like best and find the most easy to maintain.
Chip's method has the great advantage of scalability: just add the panel to the dev array and voila! (for the shared buttons at least).
However, I do find that "overusing" dev arrays and channel arrays and other arrays may sometimes lead to code not easily grasped unless you're firmly into it, the kind you look at 6 months later and wonder what this is trying to achieve. So I would not bother if few functions are shared.
Fred