Replies: 8 comments 1 reply
-
I think it might make sense to call the program differently then. Basically, lex + yacc (which we already have) are able to parse any kind of grammar, as long as we can describe a grammar for the input language. |
Beta Was this translation helpful? Give feedback.
-
Another idea is to embed scripting language like jimtcl or lua or even Python. Reference: OpenOCD has embedded jimtcl |
Beta Was this translation helpful? Give feedback.
-
@MCUdude |
Beta Was this translation helpful? Give feedback.
-
The question is what's the goal: Is it automation? Then it might make more sense to just build up Python bindings on top of libavrdude, and write up some nice examples on how to use that practically. Is it ease of user interaction? Then I think we need a kind of "natural language" commandline parser. I thought the topic is about the latter. |
Beta Was this translation helpful? Give feedback.
-
Good point. But I have different understanding of "easier user interaction". I think GUI is the way to go and not "natural language" commandline parser. In that sense, we need to improve libavrdude. I can see AVRDUDESS is quite popular but it is built on top of avrdude CLI and there may be a better way to use libavrdude and other cross-platform GUI toolkit. |
Beta Was this translation helpful? Give feedback.
-
Agreed, and allowing for a better GUI integration than all those on-top-of-CLI ones, was the primary reason for segregating libavrdude as the backend from the frontend CLI code. |
Beta Was this translation helpful? Give feedback.
-
avrdude already has CLI and terminal syntax. I am not convinced their syntax is overly complex to solve
Some of the commands can be a bit complex, eg, terminal ChatGPT will probably be able to translate natural language into (halfway) correct syntax. 😮 In any case, it is probably best for avrdude to not invent a new syntax that competes with the existing one. Better to use libavrdude to generate a new interface/program using a different way of expressing above 4 points.
BTW, this example is likely to suffer from ambiguity: do you want to erase the entire chip or only |
Beta Was this translation helpful? Give feedback.
-
In this case, maybe we want to convert this issue to discussion. |
Beta Was this translation helpful? Give feedback.
-
In order to stay busy we need som crazy new ideas. So here's one I got when reading at the Avrfreaks forum.
If we implement Levenshtein distance checking for parts and memories too, would it be possible to support an "alternative syntax" without flags, for simpler things like flashing a file or setting a fuse?
Here are some made up examples:
If this unheard of, and practically impossible to implement, or is this something that would make Avrdude more accessible for the average AVR developer?
Could it be solved by a routine that parsed the input (
avrdude urclock ch340 250000 flash test_file.bin
) and then made it so that Avrdude can understand it (avrdude -c urclock -P ch340 -b 250000 -U flash:w:test_file.bin:a
)?Beta Was this translation helpful? Give feedback.
All reactions