summaryrefslogtreecommitdiff
path: root/ports/nrf/fatfs_port.c
diff options
context:
space:
mode:
Diffstat (limited to 'ports/nrf/fatfs_port.c')
-rw-r--r--ports/nrf/fatfs_port.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/ports/nrf/fatfs_port.c b/ports/nrf/fatfs_port.c
index 2b741f993..5347af417 100644
--- a/ports/nrf/fatfs_port.c
+++ b/ports/nrf/fatfs_port.c
@@ -31,12 +31,12 @@
#include "shared-bindings/time/__init__.h"
DWORD get_fattime(void) {
-#if CIRCUITPY_RTC
+ #if CIRCUITPY_RTC
timeutils_struct_time_t tm;
common_hal_rtc_get_time(&tm);
return ((tm.tm_year - 1980) << 25) | (tm.tm_mon << 21) | (tm.tm_mday << 16) |
- (tm.tm_hour << 11) | (tm.tm_min << 5) | (tm.tm_sec >> 1);
-#else
+ (tm.tm_hour << 11) | (tm.tm_min << 5) | (tm.tm_sec >> 1);
+ #else
return ((2016 - 1980) << 25) | ((9) << 21) | ((1) << 16) | ((16) << 11) | ((43) << 5) | (35 / 2);
-#endif
+ #endif
}