From cf16f06a985a8eaf77da45f486e579712de562db Mon Sep 17 00:00:00 2001 From: Kai Lauterbach Date: Fri, 30 Dec 2011 13:04:26 +0100 Subject: [PATCH] Sample implementation to parse commandline parameter. --- client/clcc.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/client/clcc.c b/client/clcc.c index cf4ec46..d30b977 100644 --- a/client/clcc.c +++ b/client/clcc.c @@ -32,8 +32,17 @@ int main(int argc, char **argv) lc_init(); - // TODO parse commandline parameters + lc_setMode(MODE_ANIMATION_STOP); + // TODO parse commandline parameters + unsigned int frame = 0; + if ( sscanf((char*)argv[1], "0x%08x", &frame) ) + { + printf("0x%08x\n", frame); + lc_setFrame(frame); + } + + //lc_setMode(MODE_ANIMATION_LOOP); lc_close(); return 0;