monome / monome/teletype

Proposal: Centralize definition of OPs into a single file

Open
#342 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
222
Forks
94
PR merge metrics
No merged PRs in 30d

Description

Users must read or touch many files to reason about or define a new OP. Currently that list includes the tele_ops table, the Ragel parser, the module, test, and simulator Makefiles, the help mode documentation, and the paper documentation.

We're already doing a little bit of codegen to create op_enums.h, but lots of this other material could be generated also.

The ideal would be a single file that describes all the information for an OP or small collection of related OPs, so adding or altering behavior could target a single location in the source tree. If a single file was untenable, then two separate files for definition and implementation in the same folder would also be an improvement.

In addition to making adding OPs easier, this change would also make it easier to refactor the way OPs are processed and documented, because all the implementations could be changed by changing the codegen.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by mapping the tele_ops table, Ragel parser, module, test, and simulator Makefiles, help documentation, paper documentation, and existing op_enums.h generation. Determine whether one definition file or separate definition and implementation files can cover these sources. Done means OP information has a clearly defined central source and the affected code, tests, simulator, and documentation are generated or updated from it.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
documentation, embedded-iot, tooling
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.