Search found 4 matches

by seanyoung
Mon Feb 13, 2023 5:16 am
Forum: JP1 - Software
Topic: Some protocols are not decodable without repeating magic
Replies: 5
Views: 20791

Thanks for the feedback. Let me compose a list of problematic protocols and maybe some better wording of the problem.

NFA and DFA are state machines used for decoding IR, not for parsing IRP language. The rust code has a peg grammar for parsing IRP: https://github.com/seanyoung/cir/blob/main/irp ...
by seanyoung
Tue Feb 07, 2023 3:59 pm
Forum: JP1 - Software
Topic: Some protocols are not decodable without repeating magic
Replies: 5
Views: 20791

The state machine starts at A(0).

Note that there are two edges with 'flash 9024' coming out of A(0), one for repeat and one for down. This means that after flash 9024 the state machine is in two states, M(12) and B(1).

This is exactly the difference between NFA and DFA. In DFA, these two edges ...
by seanyoung
Tue Feb 07, 2023 1:26 pm
Forum: JP1 - Software
Topic: Some protocols are not decodable without repeating magic
Replies: 5
Views: 20791

DFA => Deterministic Finiite Automation
NFA => Nondeterministic Finite Automation
This is used by regex engines. By using DFA we can get super-fast decoding, see https://shivankaul.com/blog/nfa-dfa-and-regexes

Here is the nec1 protocol converted to NFA (not DFA).

https://www.mess.org/nec-nfa.png
by seanyoung
Tue Feb 07, 2023 9:15 am
Forum: JP1 - Software
Topic: Some protocols are not decodable without repeating magic
Replies: 5
Views: 20791

Some protocols are not decodable without repeating magic

I'm writing an IRP encoder/decoder in rust, see https://docs.rs/irp/ and https://github.com/seanyoung/cir/tree/main/irp

The encoder is working fine, and produces the same output as IrpTransmogrifier for the protocols defined in IrpProtocols.xml

The decoder generates a fine state machine like ...