package require Thread 2.6

proc LaunchThreads {} {
        for {set i 1} {$i<=5} {incr i} {
                puts "launching thead:$i"

                set thread($i) [thread::create {
                        # require tls
                        package require tls 1.5

                        proc Tester {keke} {

                                puts "we got info: $keke for [thread::id]"

                        }

                        thread::wait
                }]

                thread::send -async $thread($i) "Tester \"bah\""
        }
}


proc Menu {} {

        puts "Menu"

        set option [gets stdin]

        if { $option == "l" } {
                LaunchThreads
        }


        while { $option != "q" } {
                Menu
        }


}

Menu