Comments (7)
Was going to uninstall hidapi from brew in case that was coming down as an Intel binary, but I noticed that open-ocd has this same dependency and it's working fine from my M1 Macbook, so the problem doesn't seem to be with hidapi being the wrong binary.
from edbg.
I have no way of debugging this. If you feel like it, you can put print statements along the way to see where it fails specifically. May be we can figure out something based on this information. But otherwise there is nothing I can do.
from edbg.
Thank you for the amazingly prompt response. Went in to start doing this and...was working fine.
Uh, "have you tried turning it off and turning it back on again?" All I can figure is a reboot whacked things in just the right way.
from edbg.
Hmm, started to reproduce again. Using print statements, I've sussed out that dbg_open
is failing the if (!handle)
check and then when perror_exit
calls into disconnect_debugger -> dap_led -> dbg_dap_cmd -> hid_write
that's what triggers seg_fault, I assume because handle was never set and so hid_write is going boink.
from edbg.
OK, root cause. If I'm simultaneously running openocd, then the device is busy and the dbg_open call fails, and as part of its failure path it tries writing to the invalid hid handle and segfaults.
edbg --list
works and edbg -t list
works while openocd has the device open, but edbg -t %device%
fails, so to a noob like me it's a little mysterious.
from edbg.
Should be fixed now. All those errors appeared after I tried to be nice and close the connection correctly.
Ideally individual OS drivers would track this and not execute commands if debugger is not open, but for not a global flag would do.
from edbg.
Confirmed that I now receive "unable to open device: No such file or directory" when I reproduce the 'device in use by openocd' error condition.
Thank you.
from edbg.
Related Issues (20)
- "Error: invalid response received" in ATSAMD11C14A HOT 16
- error_exit() function and target reset HOT 1
- Error: hid_error is not implemented yet HOT 20
- Ubuntu 20 edbg flash broken? HOT 3
- unable to unlock HOT 4
- Binary downloads HOT 7
- Programming ATsaml21e17b HOT 2
- CMSIS-DAP v2 support requirement HOT 5
- edbg compiled on Raspberry Pi 4B hangs while using free-DAP to program SAMD21 HOT 3
- RP2040 support? HOT 28
- board unusable after write fuse operation on SAML11-XPRO HOT 5
- Why is the RP2040 max flash 2MB? HOT 1
- libhidapi.0.dylib not loaded on Mac HOT 5
- Request to add entry for SAM V70N19 Rev B HOT 1
- "nanoDAP" adapter not supported in Linux HOT 2
- WAIT response after erasing flash HOT 7
- Can't list devices on Ubuntu 20.04 HOT 4
- Kinetis KL26 HOT 2
- Add support for PUYA PY32F0xx HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from edbg.