Comments (3)
https://github.com/tinygo-org/tinygo/blob/731532cd2/src/machine/usb.go#L261
I'm attempting to take a shot at this, using TinyGo's implementation as a reference. In part because it seems more minimal than alternatives like TinyUSB. I believe TinyGo have implemented just enough of CEC to be a serial device, not support for modems etc. I'm also trying to use TinyGo as a reference because I'm fluent in Go, but not Zig, or microcontrollers, or USB. 😄
from microzig.
Any luck with this? I read that picotool needs the firmware running on a microcontroller to implement USB-CDC in order for its load --force
argument to work (letting you reboot picos outside of BOOTSEL mode). When using C you can set pico_enable_stdio_usb(<project-name> 1)
in CMakeLists.txt
to accomplish this.
Apparently this is because picotool uses PICO_STDIO_USB_ENABLE_RESET_VIA_VENDOR_INTERFACE though I don't know enough of how this stuff works to provide any of my own insight.
from microzig.
Unfortunately I didn't get very far before my vacation ended.
I was finding it pretty hard to figure out how to cleanly extend the existing USB implementation. A lot of this is probably just because I don't know Zig, but I think it was exacerbated by the fact that the implementation isn't designed for extensibility.
My understanding based on ZigEmbeddedGroup/raspberrypi-rp2040#40 is that the USB implementation is a port of https://github.com/cbiffle/rp2040-usb-device-in-one-file/blob/4878f4/src/main.rs, which per its header comments is intended "for reference and study".
Here's what I ended up with. It's mostly just all the structs that I think are needed to make CDC work: 846e994e
from microzig.
Related Issues (20)
- No output files generated HOT 1
- documentation not clear and failre when using example HOT 1
- Improve customization of linker scripts
- Please help: with format a string with numbers or allocator instance in microzig. HOT 1
- What should we do if there's no SVD or ATDF file? HOT 2
- Tracking Issue: Problems with Zig
- Add support for DFU package creation
- ESP32 Firmware Image support
- Compile error on Raspberry Pi HOT 1
- On Zig 0.12.0 (or 0.11.1): Revert #153 for ziglang/zig issue 17882
- Getting Started
- AVR: Support C backend
- Generate status matrix
- Various issues HOT 2
- rp2040: dma: transfer_size_bytes is not respected HOT 1
- Suggestions re: STM32 from a Rust Embedded dev HOT 4
- Expand EmbeddedExecutable HOT 3
- [Tracking issue] Platform support/wishlist HOT 6
- STM32F4XX does not support SysTick register
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 microzig.