Skip to content

Counter module Basics#150

Merged
NaveenChengappa-IFX merged 16 commits into
machine-counterfrom
Counter_module_implementation
Jul 14, 2026
Merged

Counter module Basics#150
NaveenChengappa-IFX merged 16 commits into
machine-counterfrom
Counter_module_implementation

Conversation

@NaveenChengappa-IFX

@NaveenChengappa-IFX NaveenChengappa-IFX commented Jul 6, 2026

Copy link
Copy Markdown

Summary

  • Implemented basic Counter module.
  • It has the constructor, Init(), Deinit() and the value() methods in this PR.
  • Basic boundary conditions and parameter validations implemented.

Testing

  • HIL testing carried out.
  • Local testing by coupling a PWM output to count the number of rising edges.

Trade-offs and Alternatives

Generative AI

I did not use generative AI tools when creating this PR.

Comment thread .github/workflows/ports_psoc-edge-ifx.yml Fixed
Comment thread .github/workflows/ports_psoc-edge-ifx.yml Fixed
Comment thread .github/workflows/ports_psoc-edge.yml Fixed
Comment thread .github/workflows/stale_issues.yml Fixed
Comment thread .github/workflows/synch_upstream.yml Fixed
Comment thread .github/workflows/synch_upstream.yml Fixed
@NaveenChengappa-IFX
NaveenChengappa-IFX force-pushed the Counter_module_implementation branch from a47d026 to 77f8533 Compare July 6, 2026 08:53
@NaveenChengappa-IFX
NaveenChengappa-IFX force-pushed the Counter_module_implementation branch from ac41df4 to b9ba57a Compare July 7, 2026 04:53
Comment thread ports/psoc-edge/machine_counter.c Outdated
Comment thread ports/psoc-edge/modmachine.c
Comment thread ports/psoc-edge/machine_counter.c

@AkshayChandra-IFX AkshayChandra-IFX left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Looks Great! 🔥

@NikhitaR-IFX NikhitaR-IFX 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.

Just what we discussed offline on timer, counter instance affect on each other can be verified through a test,. Rest looks good to me :)

Comment thread ports/psoc-edge/modmachine.h
Comment thread ports/psoc-edge/machine_counter.c
Comment thread ports/psoc-edge/machine_counter.c
Comment thread ports/psoc-edge/machine_counter.c Outdated
Comment thread ports/psoc-edge/machine_counter.c Outdated
Comment thread ports/psoc-edge/machine_counter.c

@jaenrig-ifx jaenrig-ifx 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.

Very good progress 👍

The docs are missing. I guess that will come in another PR.
Mostly there explaining only the differences with the general API.

And for the rest, whatever features and modes are missing once decided.

As a general topic, we should reuse the existing libs and approaches when possible, this will make the machine classes more harmonized, therefore easier to maintain in the long run.
In many cases, is not only a OCD whim, but a way to ensure that this class works together with the rest properly.
Otherwise, these classes functionality won't properly out of their unit isolation in which we develop them.

Comment thread ports/psoc-edge/boards/make-pins.py Outdated
Comment thread ports/psoc-edge/machine_counter.c
Comment thread ports/psoc-edge/machine_counter.c
@jaenrig-ifx
jaenrig-ifx force-pushed the psoc-edge-main branch 2 times, most recently from 61ce822 to f721963 Compare July 9, 2026 07:23
@NaveenChengappa-IFX
NaveenChengappa-IFX force-pushed the Counter_module_implementation branch from 7585e71 to f4cdb6a Compare July 9, 2026 11:02
@jaenrig-ifx
jaenrig-ifx force-pushed the Counter_module_implementation branch from f4cdb6a to 561999a Compare July 13, 2026 11:11
@jaenrig-ifx
jaenrig-ifx changed the base branch from psoc-edge-main to machine-encoder July 13, 2026 11:11
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: NaveenChengappa-IFX <Naveen.Chandura@infineon.com>
Signed-off-by: jaenrig-ifx <enriquezgarcia.external@infineon.com>
Signed-off-by: jaenrig-ifx <enriquezgarcia.external@infineon.com>
Signed-off-by: jaenrig-ifx <enriquezgarcia.external@infineon.com>
Signed-off-by: jaenrig-ifx <enriquezgarcia.external@infineon.com>
Signed-off-by: jaenrig-ifx <enriquezgarcia.external@infineon.com>

@jaenrig-ifx jaenrig-ifx 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.

🚀 !

@NaveenChengappa-IFX
NaveenChengappa-IFX merged commit b47730c into machine-counter Jul 14, 2026
22 checks passed
@NaveenChengappa-IFX
NaveenChengappa-IFX deleted the Counter_module_implementation branch July 14, 2026 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants