pull up polarity as a parameter