first draft of working code for bur