From 1c3a1ab2c6c4251ea5989fea2a423b4b67cb57f5 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 8 Sep 2019 01:02:04 -0500 Subject: [PATCH] Use _MIN over MIN --- Marlin/src/feature/digipot/digipot_mcp4451.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Marlin/src/feature/digipot/digipot_mcp4451.cpp b/Marlin/src/feature/digipot/digipot_mcp4451.cpp index 61140d81b..1b9672251 100644 --- a/Marlin/src/feature/digipot/digipot_mcp4451.cpp +++ b/Marlin/src/feature/digipot/digipot_mcp4451.cpp @@ -72,7 +72,7 @@ void digipot_i2c_set_current(const uint8_t channel, const float current) { // Set actual wiper value byte addresses[4] = { 0x00, 0x10, 0x60, 0x70 }; - i2c_send(addr, addresses[channel & 0x3], current_to_wiper(MIN((float) _MAX(current, 0), DIGIPOT_I2C_MAX_CURRENT))); + i2c_send(addr, addresses[channel & 0x3], current_to_wiper(_MIN(float(_MAX(current, 0)), DIGIPOT_I2C_MAX_CURRENT))); } void digipot_i2c_init() {