Posted to tcl by kbk at Mon Apr 16 16:13:18 GMT 2007view raw

  1. # Skeleton of a proc to make your 'tag' commands
  2. proc makeCommands {nChannels {limit 100}} {
  3. for {set i 0} {$i < $nChannels} {incr i $limit} {
  4. set cmd "tag"
  5. set sep " "
  6. for {set j $i} {$j < $nChannels && $j < $i+$limit} {incr j} {
  7. append cmd $sep $j
  8. set sep ","
  9. }
  10. # Here is where you send the command
  11. puts $cmd
  12. }
  13. }
  14. makeCommands 20 5