fixes.

note. we need to read switches as integers. setting uselink = False, True, 0, 1 all result in 
if uselink: being evaluated as true!!!