-
Notifications
You must be signed in to change notification settings - Fork 145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP: Write logs to microSD in HSM mode #196
base: master
Are you sure you want to change the base?
Conversation
you need to add your new module |
Thanks, very helpful! I'll try again and try to come up with something cleaner |
25c0941
to
9679366
Compare
Now it works on the real thing. Here's a summary of the changes made so far:
Please let me know if you think this is going in the right direction. |
Hi, I've been experimenting a lot recently with the CC, especially with the HSM mode, and it happened a couple times that the CC "freezes", it just stops responding at some point without any logs or indication of what happened on the screen. I'd let it run for days, so when it happened I would usually figure it out many hours after. At least once it crashed while signing as the screen was reading "Signing..."
I had a look at what it logged on the microSD and I didn't found it to be very helpful for my situation, so I tried to modify it to write more logs that could help me if it crashes again.
I tested my code with the simulator, and it worked, I could register a policy and then it would sign psbts and write logs on the SD card.
But then I tried to flash an actual CC Mk4 with my custom code, and it crashed on startup with the following error
I tried my code again with the simulator, and it works there. Here's an actual example of the content of a log file I just made like this:
I open this PR as a WIP because I think there might be demand for that, especially as more people will run the HSM mode, it's totally hacky right now but if you agree I'd gladly put on some more work because I need it. I'd just be happy to have a little help and not brick a couple more CC just to figure it out 😄