Skip to content

[driver] gray-code decoder for STM32 Timer - #775

Merged
salkinium merged 4 commits into
modm-io:developfrom
TomSaw:feature/stm32-timer_encoder_input
Nov 15, 2021
Merged

[driver] gray-code decoder for STM32 Timer#775
salkinium merged 4 commits into
modm-io:developfrom
TomSaw:feature/stm32-timer_encoder_input

Conversation

@TomSaw

@TomSaw TomSaw commented Nov 6, 2021

Copy link
Copy Markdown
Contributor

Added driver:encoder_input using a STM32 Timer. It has the same interface like from my first contribution modm:driver:encoder_input.bitbang

I've also extended the Timer HAL and added a shorthand for setting the input filter.

TODO

  • Finish up encoder_input.md
  • Add example

@TomSaw
TomSaw force-pushed the feature/stm32-timer_encoder_input branch 8 times, most recently from 377bf08 to 39d91e6 Compare November 6, 2021 14:24

@salkinium salkinium left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, I love it!

Comment thread src/modm/driver/encoder/encoder_input.lb Outdated
@TomSaw
TomSaw force-pushed the feature/stm32-timer_encoder_input branch from 4bd7f1b to eb20a9a Compare November 12, 2021 10:07
@TomSaw

TomSaw commented Nov 12, 2021

Copy link
Copy Markdown
Contributor Author

Done!
Examples added and improved and also gave some touches to encoder_input.bitbang

@TomSaw
TomSaw force-pushed the feature/stm32-timer_encoder_input branch from eb20a9a to 4e2da59 Compare November 12, 2021 10:30
Comment thread src/modm/driver/encoder/encoder_input.hpp Outdated
@TomSaw
TomSaw force-pushed the feature/stm32-timer_encoder_input branch from 4e2da59 to bebe3f3 Compare November 12, 2021 10:45

@salkinium salkinium left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent!

@TomSaw

TomSaw commented Nov 12, 2021

Copy link
Copy Markdown
Contributor Author

Im also in the mood to proceed with fragment & PR #665 ... ->Have studied git rebase in the meanwhile 😇 - otherwise i'll get crazy with these 13k lines of changes, haha

@salkinium

Copy link
Copy Markdown
Member
scons: building terminated because of errors.main.cpp: In function 'int main()':
main.cpp:62:21: error: 'class modm::BitBangEncoderInput<modm::platform::GpioStatic<modm::platform::detail::DataB3>, modm::platform::GpioStatic<modm::platform::detail::DataB4>, 4>' has no member named 'getIncrement'
   62 |    value += encoder.getIncrement();
      |                     ^~~~~~~~~~~~
scons: *** [build/scons-release/main.o] Error 1

@salkinium

Copy link
Copy Markdown
Member

Im also in the mood to proceed

Yes please. I'm writing my master's thesis, so if I don't respond in timely fashion, just @ poke me again.

@TomSaw

TomSaw commented Nov 14, 2021

Copy link
Copy Markdown
Contributor Author

Please check this this CI error @salkinium . not my fault i think.

@salkinium

Copy link
Copy Markdown
Member

It's a bug in the AVR example: encoder.getIncrement(); vs encoder.getDelta();

@TomSaw
TomSaw force-pushed the feature/stm32-timer_encoder_input branch from bebe3f3 to 239b556 Compare November 15, 2021 08:23
@TomSaw
TomSaw force-pushed the feature/stm32-timer_encoder_input branch from 239b556 to d46c09d Compare November 15, 2021 08:54

@salkinium salkinium left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@salkinium
salkinium merged commit d46c09d into modm-io:develop Nov 15, 2021
@TomSaw
TomSaw deleted the feature/stm32-timer_encoder_input branch November 15, 2021 12:19
@salkinium salkinium added this to the 2021q4 milestone Dec 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants