Make blink(1) blink a specific color

4

I'm playing with my new blink(1), and trying to hook it's command line interface into some of my programs, but the docs are a little limited and I'm struggling to figure out how to run even some seemingly simple commands.

In particular, the CLI docs say:

Usage: 
  blink1-tool <cmd> [options]
where <cmd> is one of:
  ....
  --blink <numtimes>          Blink on/off
  ....

So I try to run blink1-tool --blink 5 and it outputs blink 5 times rgb:0,0,0: and doesn't light up.

How do I use the --blink command?

dimo414

Posted 2012-12-13T04:19:56.117

Reputation: 696

Answers

3

I suspect the fact that blink1-tool --blink 5 doesn't do anything is a bug. Originally --blink just blinked white, but a recent fix allows you to specify the color to blink (the usage script hasn't been updated yet).

The correct syntax for --blink is now:

blink1-tool [options] --rgb r,g,b --blink num

Note that [options] come before <cmd> despite the message in the usage script.

For example, to blink purple on for a second, off for a second, taking a fifth of a second to transition, you would run:

blink1-tool -t 1000 -m 200 --rgb 255,0,255 --blink 5

dimo414

Posted 2012-12-13T04:19:56.117

Reputation: 696

1

Be sure to set the --rgb switch before --blink

This is valid:

blink1-tool -t 1000 -m200 --rgb 255,0,255 --blink 5

This is not valid:

blink1-tool -t 1000 -m200 --blink 5 --rgb 255,0,255

neal

Posted 2012-12-13T04:19:56.117

Reputation: 11

Correct. Despite the -- notation suggesting order-independence, --rgb must come before --blink. – dimo414 – 2012-12-15T17:21:44.440