a working VI implementation