few fixes & added getAmountProgOut()