From: ian Date: Tue, 31 May 2005 22:56:52 +0000 (+0000) Subject: parse-proto-spec makes a nice macro list X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ijackson/git?a=commitdiff_plain;h=5973dc4257d1791bef9c646d582105d08244577d;p=trains.git parse-proto-spec makes a nice macro list --- diff --git a/hostside/parse-proto-spec b/hostside/parse-proto-spec index a15db77..3b15077 100755 --- a/hostside/parse-proto-spec +++ b/hostside/parse-proto-spec @@ -46,7 +46,8 @@ while (<>) { $ybit= oct("0b$ybit"); } for $yval ($ybit ? (0,1) : '') { - printf("%s( %-16s, 0x%02x, %2d )\n", + printf("%s( %-12s 0x%02x, %2d )\n", + $dname, sprintf("%s%s,",$cname, $yval), oct("0b$opcode") | $ybit *$yval, $arglen)