Skip to content
Tactiverge

Forge · Invention Blueprint

Debounce on a budget chip

A debounced press program (it checks the light gate twice before pressing) runs on a chip that is too slow to finish each 50 ms tick. Choose the clock, belt speed and light-gate window so every tick finishes in budget on a chip of at most 2,500 cycles per second, with no bad strokes, no crashes and all 30 parts stamped within 60 s.

Advanced · experimentalEmbedded computing

Starting design: “Press: the debounced program on a noisy light gate”, built from the Research Engineer system of the Computer-Controlled Machine. The Bench-8 runs the debounced program (it looks twice before pressing); the light gate glitches. Scenario: 1 setting changed from that system (shown in your technical document).

2,500cyc/s£busiest tick

Constraints

  • Zero overruns
  • Clock at most 2,500 cycles/s
  • No bad strokes
  • Zero crashes
  • All 30 parts stamped within 60 s

Components

Conveyor press · Bench-8 controller

Before you start

Extensions

  • Compare the busiest tick of the debounced program with the plain one in ‘Conveyor press on a budget chip’. What did debouncing cost in cycles?
  • Keep the clock you chose and raise the gate noise. When does looking twice stop being enough?

Learning pathway

  1. 1OverrunRun the starting design: at 1,000 cycles per second the program cannot finish a 50 ms tick, so the watchdog holds the outputs.
  2. 2BudgetThe cycle budget is clock × tick. Read the busiest tick's cycles and work out the smallest clock that fits.
  3. 3Debounce timingThe program waits one tick to confirm a part, so a part must stay under the gate for at least two ticks.
  4. 4Cheapest safeSettle on the slowest clock with zero overruns and the belt speed that keeps every stamp clean.

Your project

Switch freely between Learn (the pathway, step by step), Challenge (the settings and targets) and Create (the full sandbox). Everything stays private in this browser; your technical document is generated from it.

Loading Forge…

Curriculum

Labs

Technically checked by automated tests; not yet reviewed by an educator. Results come from simplified educational models, never from real hardware.