aboutsummaryrefslogtreecommitdiffhomepage
path: root/source
diff options
context:
space:
mode:
authorBen V. Brown <[email protected]>2023-08-12 15:31:02 +1000
committerGitHub <[email protected]>2023-08-12 15:31:02 +1000
commitf69c37c4aa69c8d2d4fa8c79d882ac9c9ee05b63 (patch)
treea64954db24db803e792830b0df844c83b19b984f /source
parentcaedce0300602e103d1685f4fcfad0a1cff608d0 (diff)
downloadIronOS-f69c37c4aa69c8d2d4fa8c79d882ac9c9ee05b63.tar.gz
IronOS-f69c37c4aa69c8d2d4fa8c79d882ac9c9ee05b63.zip
Revert "Remove 0.5 ohm increase to resistance" (#1794)
Diffstat (limited to 'source')
-rw-r--r--source/Core/Drivers/USBPD.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/Core/Drivers/USBPD.cpp b/source/Core/Drivers/USBPD.cpp
index 6613bb9d..7bdd4113 100644
--- a/source/Core/Drivers/USBPD.cpp
+++ b/source/Core/Drivers/USBPD.cpp
@@ -123,7 +123,8 @@ bool parseCapabilitiesArray(const uint8_t numCaps, uint8_t *bestIndex, uint16_t
*bestIndex = 0xFF; // Mark unselected
*bestVoltage = 5000; // Default 5V
- uint8_t tipResistance = getTipResistanceX10();
+ // Fudge of 0.5 ohms to round up a little to account for us always having off periods in PWM
+ uint8_t tipResistance = getTipResistanceX10() + 5;
#ifdef MODEL_HAS_DCDC
// If this device has step down DC/DC inductor to smooth out current spikes
// We can instead ignore resistance and go for max voltage we can accept; and rely on the DC/DC regulation to keep under current limit