Edge finding binary search
How about

if BlackOrWhite == 1:
  if oldtrial == high:
    newtrial = oldtrial+factorIncrease*(high-low)+1
    high = newtrial
    low = oldtrial
  elif high-oldtrial==1:
    finished = 1
    newtrial = oldtrial
  else:
    newtrial = oldtrial+(high-oldtrial)/2
    low = oldtrial


For simplifying your ifs?