This is my repo for projects regarding the Digispark (ATTiny85). The instruction isn´t meant to be a perfect one. It should just help me to get back on track, when I forget something. :)
Short instructions (for Windows):
- Arduino IDE needed: Download
- Install Digistump driver (DPinst.exe=32bit|DPinst64.exe=64bit): Download | Repo
- Add "http://digistump.com/package_digistump_index.json" to "Additional Boards Manager URL"
Keyboard Layouts
-> German: DigiKeyboardDe.h | Repo
To add a keyboard layout, you need to import it in your code: #include "DigiKeyboardDe.h". Needs to be in the same path as the ".ino" files. An example is in the folder "hello_world.ino". Here you can see the exact structure, to be able to upload your code on your Digispark.
Code Example:
#include "DigiKeyboardDe.h"
void setup() {
DigiKeyboardDe.sendKeyStroke(0);
DigiKeyboardDe.sendKeyStroke(KEY_R, MOD_GUI_LEFT);
DigiKeyboardDe.println("cmd");
DigiKeyboard.delay(500);
DigiKeyboardDe.println("echo Hello World!");
}
void loop() {
}
How to upload:
- Open Arduino IDE and create your project.
- Be sure you selected the right board. (Tools -> Board -> "Digispark (Default - 16mhz)"
- To upload: Click the Upload Button in the Arduino IDE.
- Wait! Arduino will now compile your code.
- When the message: "Running Digispark Uploader... Plug in device now... (will timeout in 60 seconds)" appears, plug-in your Digispark!
- When the upload was succesfull, the message: ">> Micronucleus done. Thank you!" will appear!
Errors I experienced:
Digispark doesn´t get recognized by your OS (this happend to a few clones from a different drop):
A: I was able to fix this issue, when I used a USB-Hub. When you use a Digispark, with cable, try a different cable.