Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Nucleo_Encoder_16_bits.h
- Revision:
- 0:ebd170807e11
- Child:
- 1:e82009479b5c
diff -r 000000000000 -r ebd170807e11 Nucleo_Encoder_16_bits.h
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/Nucleo_Encoder_16_bits.h Sun May 22 19:59:18 2016 +0000
@@ -0,0 +1,30 @@
+#ifndef ENCODER_H
+#define ENCODER_H
+#include "mbed.h"
+
+void EncoderInit(TIM_Encoder_InitTypeDef * encoder, TIM_HandleTypeDef * timer, TIM_TypeDef * TIMx, uint32_t maxcount, uint32_t encmode);
+
+
+namespace mbed{
+
+ class Nucleo_Encoder_16_bits {
+
+ public :
+ Nucleo_Encoder_16_bits(TIM_TypeDef * _TIM, uint32_t _maxcount, uint32_t _encmode);
+ Nucleo_Encoder_16_bits(TIM_Encoder_InitTypeDef * _encoder, TIM_HandleTypeDef * _timer, TIM_TypeDef * _TIM, uint32_t _maxcount, uint32_t _encmode);
+ int32_t GetCounter();
+ TIM_HandleTypeDef* GetTimer();
+
+ private :
+
+
+ protected :
+ TIM_Encoder_InitTypeDef encoder;
+ TIM_HandleTypeDef timer;
+ TIM_TypeDef * TIM;
+
+ };
+
+}// namespace mbed
+
+#endif
\ No newline at end of file