summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2019-06-11 23:15:38 +0200
committerThomas White <taw@physics.org>2019-06-11 23:21:03 +0200
commite1adc561967013d7b775e807cd56bfa19fcdca6b (patch)
tree5eb620978df5448c3fc8ffe0d9e09391811e56bd
parent184c8d4042517c817fe1d1932e2316b921fd197f (diff)
Add strobe/shutter attribute
-rw-r--r--src/command.c1
-rw-r--r--src/nanolight.c7
-rw-r--r--src/nanolight.h3
3 files changed, 9 insertions, 2 deletions
diff --git a/src/command.c b/src/command.c
index 62c047b..32c5ce9 100644
--- a/src/command.c
+++ b/src/command.c
@@ -162,6 +162,7 @@ static const char *str_attr(enum attr_class att)
case ATT_INTENSITY : return "intensity";
case ATT_PAN : return "pan";
case ATT_TILT : return "tilt";
+ case ATT_STROBE : return "strobe";
}
return "???";
}
diff --git a/src/nanolight.c b/src/nanolight.c
index a03c61e..6f6ebab 100644
--- a/src/nanolight.c
+++ b/src/nanolight.c
@@ -509,7 +509,7 @@ int main(int argc, char *argv[])
/* Set up data structures */
cls.name = "Dummy fixture";
- cls.n_attrs = 3;
+ cls.n_attrs = 4;
cls.attrs = attrs;
cls.attrs[0].cls = ATT_INTENSITY;
@@ -527,6 +527,11 @@ int main(int argc, char *argv[])
cls.attrs[2].addr_offset = 2;
cls.attrs[2].home = 32768;
+ cls.attrs[3].cls = ATT_STROBE;
+ cls.attrs[3].props = 0;
+ cls.attrs[3].addr_offset = 49;
+ cls.attrs[3].home = 255;
+
nl.fixture_width = 80.0;
nl.fixtures = NULL;
nl.n_fixtures = 0;
diff --git a/src/nanolight.h b/src/nanolight.h
index 67db396..d3ceb27 100644
--- a/src/nanolight.h
+++ b/src/nanolight.h
@@ -33,7 +33,8 @@ enum attr_class
{
ATT_INTENSITY,
ATT_PAN,
- ATT_TILT
+ ATT_TILT,
+ ATT_STROBE
};