Browse Source

Init DAC_DISABLE_PIN in dac_init

pull/1/head
Scott Lahteine 9 years ago
parent
commit
ddb386c139
  1. 5
      Marlin/stepper_dac.cpp

5
Marlin/stepper_dac.cpp

@ -51,6 +51,11 @@
const uint8_t dac_order[NUM_AXIS] = DAC_STEPPER_ORDER; const uint8_t dac_order[NUM_AXIS] = DAC_STEPPER_ORDER;
int dac_init() { int dac_init() {
#if PIN_EXISTS(DAC_DISABLE)
pinMode(DAC_DISABLE_PIN, OUTPUT);
digitalWrite(DAC_DISABLE_PIN, LOW); // set pin low to enable DAC
#endif
mcp4728_init(); mcp4728_init();
if (mcp4728_simpleCommand(RESET)) return -1; if (mcp4728_simpleCommand(RESET)) return -1;

Loading…
Cancel
Save