/**
- * Configure pull type for given pin.
+ * Configure voltage reference levels for digital inputs using variable
+ * reference threshold.
+ *
+ * @todo Implement.
+ *
+ * @param[in] refA [0-12000] voltage (in millivolts) to set the reference
+ * voltage A (pins 13-16).
+ * @param[in] refB [0-12000] voltage (in millivolts) to set the reference
+ * voltage B (pins 9-12).
+ *
+ *
+ * @return SUCCESS if successful.\n
+ * -1 if pin millivolts is out of range.
+ */
+int8_t rpp_din_ref(uint16_t refA, uint16_t refB);
+
+
+/**
+ * Configure given pin.
*
* @param[in] pin The pin number to setup [1-16].
* @param[in] pull_type TRUE to setup pin as pull-up (a switch-to-ground device
* option. Inputs [9-12] use variable threshold B and
* [13-16] use variable threshold B.
* FALSE to read from SPI cached value. All pins can use
- * this option.
+ * this option. See rpp_din_ref().
*
* @return HIGH or LOW if successful.\n
* -1 if pin number is out of range.\n
}
+int8_t rpp_din_ref(uint16_t ref_a, uint16_t ref_b)
+{
+ if((ref_a > 12000) || (ref_b > 12000)) {
+ return -1;
+ }
+
+ // FIXME Implement.
+ return SUCCESS;
+}
+
+
// Check for configuration changes to avoid SPI overhead
static boolean_t config_changed = FALSE;