Browse Source

Support DAC_OR_ADDRESS in Printrboard too

Scott Lahteine 8 years ago
parent
commit
6c60869409
2 changed files with 4 additions and 1 deletions
  1. 3
    1
      Marlin/dac_mcp4728.h
  2. 1
    0
      Marlin/pins_PRINTRBOARD_REVF.h

+ 3
- 1
Marlin/dac_mcp4728.h View File

@@ -50,7 +50,9 @@
50 50
 #define GAINWRITE 0B11000000
51 51
 
52 52
 // This is taken from the original lib, makes it easy to edit if needed
53
-#define DAC_DEV_ADDRESS (BASE_ADDR | 0x00)
53
+// DAC_OR_ADDRESS defined in pins_BOARD.h  file
54
+#define DAC_DEV_ADDRESS (BASE_ADDR | DAC_OR_ADDRESS)
55
+
54 56
 
55 57
 void mcp4728_init();
56 58
 uint8_t mcp4728_analogWrite(uint8_t channel, uint16_t value);

+ 1
- 0
Marlin/pins_PRINTRBOARD_REVF.h View File

@@ -89,6 +89,7 @@
89 89
 #define DAC_STEPPER_MAX   3520
90 90
 #define DAC_STEPPER_VREF     1 //internal Vref, gain 1x = 2.048V
91 91
 #define DAC_STEPPER_GAIN     0
92
+#define DAC_OR_ADDRESS    0x00
92 93
 
93 94
 #if DISABLED(SDSUPPORT)
94 95
   // these pins are defined in the SD library if building with SD support

Loading…
Cancel
Save