DevKitty-io / USB-Nugget

Run DuckyScript payloads on a USB Nugget!
https://usbnugget.com
MIT License
156 stars 18 forks source link

cdcusb.h: No such file or directory #8

Closed btasteel636 closed 2 years ago

btasteel636 commented 2 years ago

Best I could find to solve this was to include: Adafruit_TinyUSB.h library with no success.

Arduino: 1.8.19 (Mac OS X), Board: "ESP32S2 Dev Module, Enabled, Enabled, Enabled, Internal USB, Disabled, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi), QIO, 80MHz, 4MB (32Mb), 921600, None"

In file included from /Users/Choodyp/Downloads/RubberNugget-main/RubberNugget/RubberNugget.ino:4: RubberNugget.h:6:10: fatal error: cdcusb.h: No such file or directory

include "cdcusb.h"

      ^~~~~~~~~~

compilation terminated. exit status 1 cdcusb.h: No such file or directory

This report would have more information with "Show verbose output during compilation" option enabled in File -> Preferences.

AlexLynd commented 2 years ago

Hey! You can find the TinyUSB we're using here: https://github.com/chegewara/EspTinyUSB. This should include the CDC USB file referenced.

AlexLynd commented 2 years ago

The RubberNugget also depends on a few other libraries including our custom graphics library, which I'll statically upload to the repository when I get around to it.

btasteel636 commented 2 years ago

Yea now its getting stuck on Nugget_Interface.h Thank you! Look forward to trying this out when its ready!

AlexLynd commented 2 years ago

You can actually try out the v1.0 beta binary here! https://github.com/HakCat-Tech/RubberNugget/releases/tag/v1.0-beta

you just need to upload payloads under a subfolder for each os (os->category->payload.txt)

btasteel636 commented 2 years ago

Still having some issues. Tried to unpack the .zip v1.0 beta and open the .ino. but its then getting stuck on the same issue when uploading to the board. base64.hpp : no such file or directory. I think I need a walkthrough to get this going. Should I close this issue?

btasteel636 commented 2 years ago

I was able to flash the binary to the nugget using esptool but the nugget appears dead after the flash. Reset does nothing. Am I missing something?

/Users/ben/Library/Arduino15/packages/esp32/tools/esptool_py/3.3.0/esptool --chip esp32s2 --port /dev/cu.usbmodem01 --baud 921600 --before default_reset --after hard_reset write_flash -z --flash_mode dio --flash_freq 80m --flash_size 8MB 0xe000 /Users/ben/Downloads/v1.0-beta-RubberNugget.bin

skickar commented 2 years ago

Try flashing here in Chrome: https://nabucasa.github.io/esp-web-flasher/

btasteel636 commented 2 years ago

Excellent! That worked. Thank you. I think I may have a defective nugget though. It appears my nugget's buttons are not working except for the bottom button. This was happening as well with the Rubber Nugget Circuit Python version. I've tried shorting the pins for the other buttons and different cables. When I press the bottom button it works but on the next screen I have to press the up button to run my payload and I can't because the up button isnt working. Can I try and fix this on my own? I didnt assemble my own Nugget but am willing to self diagnose the problem with some instruction.

skickar commented 2 years ago

@btasteel636 Open a new bug about the buttons and we'll work with you to diagnose this. @AlexLynd can close this one when the libraries needed are added here.

First though, check if using a jumper wire to jump the buttons gives you a button press. If the button presses when you jump the connection, the button may have a bad solder joint. If it doesn't it might be an issue with the PCB or the microcontroller. But let's discuss in a new bug thread.