This drive is working well with "LPD3806-600BM-G5-24G", and have Simple program, external pull-up resistance is required
注意:需要外置上拉电阻。
Diff: main.cpp
- Revision:
- 0:b2ffb830539c
- Child:
- 1:4d205546ec69
diff -r 000000000000 -r b2ffb830539c main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Sat Feb 02 21:19:30 2019 +0000 @@ -0,0 +1,15 @@ +#include "mbed.h" +#include "Rotary_Encoder.h" + +Rotary_Encoder Encoder(PA_0, PA_1); + + int main(void) + { + while(1) + { + printf("Direction: %s\r\n", Encoder.Calculate_Direction()); + printf("\r\n"); + + wait(0.2); + } +} \ No newline at end of file