hardwario / bch-firmware-tool Goto Github PK
View Code? Open in Web Editor NEWHARDWARIO Firmware Tool (Python Application «bcf»)
License: MIT License
HARDWARIO Firmware Tool (Python Application «bcf»)
License: MIT License
While installing bcf, an error occurs and bcf can't be used. See description underneath.
OS: Manjaro Linux 21.2.6
Kernel: Linux 5.16.2-1-MANJARO
Python 3.10.4
pip 22.1.2 from /usr/lib/python3.10/site-packages/pip (python 3.10)
sudo pip3 install --upgrade --no-cache-dir bcf
echo 'eval "$(_BCF_COMPLETE=source bcf)"' >> ~/.bashrc
source ~/.bashrc
Traceback (most recent call last):
File "/usr/bin/bcf", line 33, in <module>
sys.exit(load_entry_point('bcf==1.8.1', 'console_scripts', 'bcf')())
File "/usr/bin/bcf", line 25, in importlib_load_entry_point
return next(matches).load()
File "/usr/lib/python3.10/importlib/metadata/__init__.py", line 171, in load
module = import_module(match.group('module'))
File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/usr/lib/python3.10/site-packages/bcf/cli.py", line 61, in <module>
def command_create(name, no_git, _from, depth):
File "/usr/lib/python3.10/site-packages/click/decorators.py", line 308, in decorator
_param_memo(f, OptionClass(param_decls, **option_attrs))
File "/usr/lib/python3.10/site-packages/click/core.py", line 2495, in __init__
super().__init__(param_decls, type=type, multiple=multiple, **attrs)
TypeError: Parameter.__init__() got an unexpected keyword argument 'autocompletion'
I just realized, in a hard way, that bcf log supressess log lines that do not start with the character '#':
bch-firmware-tool/bcf/log/log.py
Lines 47 to 85 in 52587f6
bcf log --raw -d /dev/ttyUSB0
I am still not seeing lines that do not match the pattern.
Case in point: When I perform a hard reboot in my firmware, the first character of the first log line that is produced after the reboot is garbage:
pi@rover:~/lora/firmware2 $ tail -f /dev/ttyUSB0
�# 0.00 <I> LoRa Module v1.1.1-37-gfa069eeb (modified) [LoRaMac v4.6.0-25-gae588f35] built on 2022-Jun-15 10:21:16 EDT
# 0.00 <D> part: Opened block 0x20000b50 (6144 B), 8 parts of 8
# 0.00 <D> Restoring system configuration from NVM
# 0.00 <D> LoRaMac: Initializing for region US915, regional parameters RP002-1.0.1
...
but bcf log --raw -d /dev/ttyUSB0
throws the entire line away:
pi@rover:~/lora/firmware2 $ bcf log --raw -d /dev/ttyUSB0
0.00 <D> part: Opened block 0x20000b50 (6144 B), 8 parts of 8
0.00 <D> Restoring system configuration from NVM
0.00 <D> LoRaMac: Initializing for region US915, regional parameters RP002-1.0.1
...
This is, in my opinion, very confusing behavior. Would it be possible to modify bcf log to always display all output so that there would be no need for --raw?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.