summaryrefslogtreecommitdiff
path: root/include/arch
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2018-12-03 10:47:32 +0100
committerDaniel Friesel <derf@finalrewind.org>2018-12-03 10:47:32 +0100
commitd244dbee97d17031d4e22c06f7e31f3b17764440 (patch)
treee09d547d6359f2fc28bb1cfa3a82ac8f5edf3efc /include/arch
parent39c7c52cd245bab7760b032159e82317ec411eac (diff)
msp430 counter: Switch to new API
Diffstat (limited to 'include/arch')
-rw-r--r--include/arch/msp430fr5969lp/driver/counter.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/arch/msp430fr5969lp/driver/counter.h b/include/arch/msp430fr5969lp/driver/counter.h
index 851c32d..e7f0507 100644
--- a/include/arch/msp430fr5969lp/driver/counter.h
+++ b/include/arch/msp430fr5969lp/driver/counter.h
@@ -6,6 +6,7 @@ class Counter {
Counter(const Counter &copy);
public:
+ uint16_t value;
uint8_t overflowed;
Counter() : overflowed(0) {}
@@ -17,9 +18,9 @@ class Counter {
TA2CTL |= TACLR;
}
- inline uint16_t stop() {
+ inline void stop() {
TA2CTL = 0;
- return TA2R;
+ value = TA2R;
}
};