├── .github ├── issue_template.md └── workflows │ ├── TestCompile.yml │ └── TestRelease.yml ├── HID_UsageTables1.1.2v2 -Chapter10.pdf ├── Keyboard Scan Code Specification -Appendix C.doc ├── LinuxUSKeyboard.png ├── Qwerty.svg ├── README.md ├── digistump-avr-1.6.8.zip ├── digistump-avr-1.7.0.zip ├── digistump-avr-1.7.1.zip ├── digistump-avr-1.7.2.zip ├── digistump-avr-1.7.3.zip ├── digistump-avr-1.7.4.zip ├── digistump-avr-1.7.5.zip ├── digistump-avr ├── avrdude.conf ├── boards.txt ├── bootloaders │ ├── upgrade-t167_default.hex │ ├── upgrade-t167_entry_on_powerOn_activePullup_fastExit.hex │ ├── upgrade-t167_entry_on_reset_activePullup_fastExit.hex │ ├── upgrade-t85_agressive.hex │ ├── upgrade-t85_default.hex │ ├── upgrade-t85_entry_on_powerOn_activePullup_fastExit.hex │ └── upgrade-t85_entry_on_reset_activePullup_fastExit.hex ├── cores │ ├── license.txt │ ├── pro │ │ ├── Arduino.h │ │ ├── HardwareSerial.cpp │ │ ├── HardwareSerial.h │ │ ├── Print.cpp │ │ ├── Print.h │ │ ├── Printable.h │ │ ├── Stream.cpp │ │ ├── Stream.h │ │ ├── TinySoftwareSPI.cpp │ │ ├── TinySoftwareSPI.h │ │ ├── TinySoftwareSerial.cpp │ │ ├── TinySoftwareSerial.h │ │ ├── Tone.cpp │ │ ├── WCharacter.h │ │ ├── WInterrupts.c │ │ ├── WMath.cpp │ │ ├── WProgram.h │ │ ├── WString.cpp │ │ ├── WString.h │ │ ├── binary.h │ │ ├── hooks.c │ │ ├── main.cpp │ │ ├── new.cpp │ │ ├── new.h │ │ ├── wiring.c │ │ ├── wiring_analog.c │ │ ├── wiring_digital.c │ │ ├── wiring_private.h │ │ ├── wiring_pulse.c │ │ └── wiring_shift.c │ └── tiny │ │ ├── Arduino.h │ │ ├── HardwareSerial.cpp │ │ ├── HardwareSerial.h │ │ ├── Print.cpp │ │ ├── Print.h │ │ ├── Printable.h │ │ ├── PwmTimer.h │ │ ├── Stream.h │ │ ├── TinyDebugSerial.cpp │ │ ├── TinyDebugSerial.h │ │ ├── TinyDebugSerial115200.cpp │ │ ├── TinyDebugSerial38400.cpp │ │ ├── TinyDebugSerial9600.cpp │ │ ├── TinyDebugSerialErrors.cpp │ │ ├── Tone.cpp │ │ ├── ToneTimer.h │ │ ├── UserTimer.h │ │ ├── WCharacter.h │ │ ├── WConstants.h │ │ ├── WInterrupts.c │ │ ├── WMath.cpp │ │ ├── WProgram.h │ │ ├── WString.cpp │ │ ├── WString.h │ │ ├── binary.h │ │ ├── core_adc.h │ │ ├── core_build_options.h │ │ ├── core_macros.h │ │ ├── core_pins.h │ │ ├── core_timers.h │ │ ├── hooks.c │ │ ├── main.cpp │ │ ├── new.cpp │ │ ├── new.h │ │ ├── wiring.c │ │ ├── wiring.h │ │ ├── wiring_analog.c │ │ ├── wiring_digital.c │ │ ├── wiring_private.h │ │ ├── wiring_pulse.c │ │ └── wiring_shift.c ├── libraries │ ├── Adafruit_NeoPixel │ │ ├── Adafruit_NeoPixel.cpp │ │ ├── Adafruit_NeoPixel.h │ │ ├── COPYING │ │ ├── README.md │ │ ├── examples │ │ │ ├── buttoncycler │ │ │ │ └── buttoncycler.ino │ │ │ ├── digispark │ │ │ │ └── digispark.ino │ │ │ ├── simple │ │ │ │ └── simple.ino │ │ │ └── strandtest │ │ │ │ └── strandtest.ino │ │ └── keywords.txt │ ├── ArduinoWiiClassicController │ │ ├── ArduinoWiiClassicController.cpp │ │ ├── ArduinoWiiClassicController.h │ │ ├── LICENSE.txt │ │ ├── README.txt │ │ ├── examples │ │ │ └── WiiClassicJoystick │ │ │ │ └── WiiClassicJoystick.ino │ │ └── keywords.txt │ ├── DigisparkCDC │ │ ├── Changelog.txt │ │ ├── CommercialLicense.txt │ │ ├── DigiCDC.cpp │ │ ├── DigiCDC.h │ │ ├── License.txt │ │ ├── Readme.txt │ │ ├── asmcommon.inc │ │ ├── examples │ │ │ ├── CDC_DTR_LED │ │ │ │ └── CDC_DTR_LED.ino │ │ │ ├── CDC_LED │ │ │ │ └── CDC_LED.ino │ │ │ ├── Echo │ │ │ │ └── Echo.ino │ │ │ └── Print │ │ │ │ └── Print.ino │ │ ├── libs-device │ │ │ └── Readme.txt │ │ ├── oddebug.c │ │ ├── oddebug.h │ │ ├── osccal.c │ │ ├── osccal.h │ │ ├── osctune.h │ │ ├── ringBuffer.h │ │ ├── usbboardconfig.h │ │ ├── usbconfig-prototype.h │ │ ├── usbconfig.h │ │ ├── usbdrv.c │ │ ├── usbdrv.h │ │ ├── usbdrvasm.S │ │ ├── usbdrvasm.asm │ │ ├── usbdrvasm12.inc │ │ ├── usbdrvasm128.inc │ │ ├── usbdrvasm15.inc │ │ ├── usbdrvasm16.inc │ │ ├── usbdrvasm165.inc │ │ ├── usbdrvasm18-crc.inc │ │ ├── usbdrvasm20.inc │ │ └── usbportability.h │ ├── DigisparkJoystick │ │ ├── ArduinoNotes.txt │ │ ├── Changelog.txt │ │ ├── CommercialLicense.txt │ │ ├── DigiJoystick.h │ │ ├── JoystickReadme.txt │ │ ├── License.txt │ │ ├── Readme.txt │ │ ├── USB-ID-FAQ.txt │ │ ├── USB-IDs-for-free.txt │ │ ├── USBID-License.txt │ │ ├── asmcommon.inc │ │ ├── examples │ │ │ └── Joystick │ │ │ │ └── Joystick.ino │ │ ├── keywords.txt │ │ ├── oddebug.c │ │ ├── oddebug.h │ │ ├── osccal.c │ │ ├── osccal.h │ │ ├── osctune.h │ │ ├── usbboardconfig.h │ │ ├── usbconfig-prototype.h │ │ ├── usbconfig.h │ │ ├── usbdrv.c │ │ ├── usbdrv.h │ │ ├── usbdrvasm.S │ │ ├── usbdrvasm.asm │ │ ├── usbdrvasm12.inc │ │ ├── usbdrvasm128.inc │ │ ├── usbdrvasm15.inc │ │ ├── usbdrvasm16.inc │ │ ├── usbdrvasm165.inc │ │ ├── usbdrvasm18-crc.inc │ │ ├── usbdrvasm20.inc │ │ └── usbportability.h │ ├── DigisparkKeyboard │ │ ├── ArduinoNotes.txt │ │ ├── Changelog.txt │ │ ├── CommercialLicense.txt │ │ ├── DigiKeyboard.h │ │ ├── License.txt │ │ ├── Readme.txt │ │ ├── USB-ID-FAQ.txt │ │ ├── USB-IDs-for-free.txt │ │ ├── USBID-License.txt │ │ ├── asmcommon.inc │ │ ├── examples │ │ │ └── Keyboard │ │ │ │ └── Keyboard.ino │ │ ├── keylayouts.h │ │ ├── keywords.txt │ │ ├── oddebug.c │ │ ├── oddebug.h │ │ ├── osccal.c │ │ ├── osccal.h │ │ ├── osctune.h │ │ ├── scancode-ascii-table.h │ │ ├── usbboardconfig.h │ │ ├── usbconfig-prototype.h │ │ ├── usbconfig.h │ │ ├── usbdrv.c │ │ ├── usbdrv.h │ │ ├── usbdrvasm.S │ │ ├── usbdrvasm.asm │ │ ├── usbdrvasm12.inc │ │ ├── usbdrvasm128.inc │ │ ├── usbdrvasm15.inc │ │ ├── usbdrvasm16.inc │ │ ├── usbdrvasm165.inc │ │ ├── usbdrvasm18-crc.inc │ │ ├── usbdrvasm20.inc │ │ └── usbportability.h │ ├── DigisparkLCD │ │ ├── LiquidCrystal_I2C.cpp │ │ ├── LiquidCrystal_I2C.h │ │ ├── examples │ │ │ └── BasicUsage │ │ │ │ └── BasicUsage.ino │ │ ├── info │ │ │ ├── BC557.pdf │ │ │ ├── Image.jpg │ │ │ ├── PCF8574P.pdf │ │ │ ├── Schematic_diagram.jpg │ │ │ ├── notes_for_pollin_interface.txt │ │ │ └── readme.txt │ │ └── keywords.txt │ ├── DigisparkMouse │ │ ├── ArduinoNotes.txt │ │ ├── Changelog.txt │ │ ├── CommercialLicense.txt │ │ ├── DigiMouse.h │ │ ├── License.txt │ │ ├── MouseReadme.txt │ │ ├── Readme.txt │ │ ├── USB-ID-FAQ.txt │ │ ├── USB-IDs-for-free.txt │ │ ├── USBID-License.txt │ │ ├── asmcommon.inc │ │ ├── examples │ │ │ └── Mouse │ │ │ │ └── Mouse.ino │ │ ├── keywords.txt │ │ ├── oddebug.c │ │ ├── oddebug.h │ │ ├── osccal.c │ │ ├── osccal.h │ │ ├── osctune.h │ │ ├── usbboardconfig.h │ │ ├── usbconfig-prototype.h │ │ ├── usbconfig.h │ │ ├── usbdrv.c │ │ ├── usbdrv.h │ │ ├── usbdrvasm.S │ │ ├── usbdrvasm.asm │ │ ├── usbdrvasm12.inc │ │ ├── usbdrvasm128.inc │ │ ├── usbdrvasm15.inc │ │ ├── usbdrvasm16.inc │ │ ├── usbdrvasm165.inc │ │ ├── usbdrvasm18-crc.inc │ │ ├── usbdrvasm20.inc │ │ └── usbportability.h │ ├── DigisparkOLED │ │ ├── CHANGES.txt │ │ ├── DigisparkOLED.cpp │ │ ├── DigisparkOLED.h │ │ ├── README.txt │ │ ├── RESEARCH.txt │ │ ├── TODO.txt │ │ ├── examples │ │ │ └── DigisparkOLED │ │ │ │ ├── DigisparkOLED.ino │ │ │ │ ├── digistump_128x64c1.h │ │ │ │ └── img0_128x64c1.h │ │ ├── font6x8.h │ │ └── font8x16.h │ ├── DigisparkRGB │ │ ├── DigisparkRGB.cpp │ │ ├── DigisparkRGB.h │ │ ├── examples │ │ │ └── DigisparkRGB │ │ │ │ └── DigisparkRGB.ino │ │ └── keywords.txt │ ├── DigisparkRcSeq │ │ ├── Examples │ │ │ ├── DigiRcSeqZodiac │ │ │ │ └── DigiRcSeqZodiac.ino │ │ │ ├── MultiPosSwitch │ │ │ │ └── MultiPosSwitch.ino │ │ │ ├── OnePropTo5 │ │ │ │ └── OnePropTo5.ino │ │ │ ├── RcSeqAdvancedDoors │ │ │ │ └── RcSeqAdvancedDoors.ino │ │ │ ├── RcSeqDemo │ │ │ │ └── RcSeqDemo.ino │ │ │ ├── RcSeqZodiac │ │ │ │ └── RcSeqZodiac.ino │ │ │ └── UneVoieVers8 │ │ │ │ └── UneVoieVers8.ino │ │ ├── RcSeq.cpp │ │ ├── RcSeq.h │ │ ├── Readme.md │ │ └── keywords.txt │ ├── DigisparkSimpleServo │ │ ├── README.txt │ │ ├── SimpleServo.cpp │ │ ├── SimpleServo.h │ │ └── keywords.txt │ ├── DigisparkSoftRcPulseIn │ │ ├── Readme.md │ │ ├── SoftRcPulseIn.cpp │ │ ├── SoftRcPulseIn.h │ │ ├── examples │ │ │ ├── SoftRcPulseInDebug │ │ │ │ └── SoftRcPulseInDebug.ino │ │ │ ├── SoftRcPulseInDemo │ │ │ │ └── SoftRcPulseInDemo.ino │ │ │ └── SoftRcPulseInOutDemo │ │ │ │ └── SoftRcPulseInOutDemo.ino │ │ └── keywords.txt │ ├── DigisparkSoftRcPulseOut │ │ ├── Readme.md │ │ ├── SoftRcPulseOut.cpp │ │ ├── SoftRcPulseOut.h │ │ ├── examples │ │ │ ├── Knob │ │ │ │ └── Knob.ino │ │ │ ├── SerialServo │ │ │ │ └── SerialServo.ino │ │ │ ├── SoftRcPulseInOutDemo │ │ │ │ └── SoftRcPulseInOutDemo.ino │ │ │ ├── Sweep │ │ │ │ └── Sweep.ino │ │ │ ├── SweepNoDelay │ │ │ │ └── SweepNoDelay.ino │ │ │ ├── Usb2Servos │ │ │ │ └── Usb2Servos.ino │ │ │ └── knob_moyennee │ │ │ │ └── knob_moyennee.ino │ │ └── keywords.txt │ ├── DigisparkSoftSerial │ │ ├── Readme.md │ │ ├── SoftSerial.cpp │ │ ├── SoftSerial.h │ │ ├── examples │ │ │ ├── Digi_1io_SerialDbg │ │ │ │ └── Digi_1io_SerialDbg.ino │ │ │ ├── SoftSerialExample │ │ │ │ └── SoftSerialExample.ino │ │ │ └── TwoPortReceive │ │ │ │ └── TwoPortReceive.ino │ │ └── keywords.txt │ ├── DigisparkTinyPinChange │ │ ├── Readme.md │ │ ├── TinyPinChange.cpp │ │ ├── TinyPinChange.h │ │ ├── examples │ │ │ ├── Edge │ │ │ │ └── Edge.ino │ │ │ ├── FallingEdge │ │ │ │ └── FallingEdge.ino │ │ │ ├── RisingEdge │ │ │ │ └── RisingEdge.ino │ │ │ └── TinyRcScope │ │ │ │ └── TinyRcScope.ino │ │ └── keywords.txt │ ├── DigisparkTinySoftPwm │ │ ├── Readme.md │ │ ├── TinySoftPwm.cpp │ │ ├── TinySoftPwm.h │ │ ├── examples │ │ │ ├── SoftPwm13Pins │ │ │ │ └── SoftPwm13Pins.ino │ │ │ └── TinySoftPwmDemo │ │ │ │ └── TinySoftPwmDemo.ino │ │ └── keywords.txt │ ├── DigisparkUSB │ │ ├── ArduinoNotes.txt │ │ ├── Changelog.txt │ │ ├── CommercialLicense.txt │ │ ├── DigiUSB.cpp │ │ ├── DigiUSB.h │ │ ├── DigisparkReadme.txt │ │ ├── License.txt │ │ ├── Readme.txt │ │ ├── USB-ID-FAQ.txt │ │ ├── USB-IDs-for-free.txt │ │ ├── USBID-License.txt │ │ ├── asmcommon.inc │ │ ├── examples │ │ │ ├── DigiBlink │ │ │ │ └── DigiBlink.ino │ │ │ ├── DigiScope │ │ │ │ └── DigiScope.ino │ │ │ ├── DigiUSB2LCD │ │ │ │ └── DigiUSB2LCD.ino │ │ │ └── Echo │ │ │ │ └── Echo.ino │ │ ├── keywords.txt │ │ ├── libs-device │ │ │ ├── Readme.txt │ │ │ ├── osccal.c │ │ │ ├── osccal.c.lst │ │ │ ├── osccal.h │ │ │ ├── osccal.o │ │ │ └── osctune.h │ │ ├── oddebug.c │ │ ├── oddebug.h │ │ ├── osccal.c │ │ ├── osccal.h │ │ ├── osctune.h │ │ ├── rx_buffer.h │ │ ├── usbboardconfig.h │ │ ├── usbconfig-prototype.h │ │ ├── usbconfig.h │ │ ├── usbdrv.c │ │ ├── usbdrv.h │ │ ├── usbdrvasm.S │ │ ├── usbdrvasm.asm │ │ ├── usbdrvasm12.inc │ │ ├── usbdrvasm128.inc │ │ ├── usbdrvasm15.inc │ │ ├── usbdrvasm16.inc │ │ ├── usbdrvasm165.inc │ │ ├── usbdrvasm18-crc.inc │ │ ├── usbdrvasm20.inc │ │ └── usbportability.h │ ├── Digispark_Examples │ │ ├── BasicRobot │ │ │ └── BasicRobot.ino │ │ ├── Blink │ │ │ └── Blink.ino │ │ ├── CharliePlexMarquee │ │ │ └── charlieplex.ino │ │ ├── Charlieplex │ │ │ └── Charlieplex.ino │ │ ├── Digispark_Examples.h │ │ ├── EEPROM │ │ │ └── EEPROM.ino │ │ ├── Expander │ │ │ └── Expander.ino │ │ ├── GPS │ │ │ └── GPS.ino │ │ ├── MeshGeneralExample │ │ │ └── MeshGeneralExample.ino │ │ ├── MotorShield │ │ │ └── MotorShield.ino │ │ ├── Rfm12b │ │ │ └── Rfm12b.ino │ │ ├── SerialEcho │ │ │ └── SerialEcho.ino │ │ ├── SerialRobot │ │ │ └── SerialRobot.ino │ │ ├── WiFiClientGetExample │ │ │ └── WiFiClientGetExample.ino │ │ ├── WiFiClientPostExample │ │ │ └── WiFiClientPostExample.ino │ │ ├── WiFiServerExample │ │ │ └── WiFiServerExample.ino │ │ ├── WiFiServerRobot │ │ │ └── WiFiServerRobot.ino │ │ ├── _9DOF_Shield │ │ │ └── _9DOF_Shield.ino │ │ └── i2cScanner │ │ │ └── i2cScanner.ino │ ├── EEPROM │ │ ├── README.md │ │ ├── examples │ │ │ ├── eeprom_clear │ │ │ │ └── eeprom_clear.ino │ │ │ ├── eeprom_crc │ │ │ │ └── eeprom_crc.ino │ │ │ ├── eeprom_get │ │ │ │ └── eeprom_get.ino │ │ │ ├── eeprom_iteration │ │ │ │ └── eeprom_iteration.ino │ │ │ ├── eeprom_put │ │ │ │ └── eeprom_put.ino │ │ │ ├── eeprom_read │ │ │ │ └── eeprom_read.ino │ │ │ ├── eeprom_update │ │ │ │ └── eeprom_update.ino │ │ │ └── eeprom_write │ │ │ │ └── eeprom_write.ino │ │ ├── keywords.txt │ │ ├── library.properties │ │ └── src │ │ │ └── EEPROM.h │ ├── NewExamples │ │ ├── New_Examples.h │ │ └── OpenWindowAlarm │ │ │ ├── ATtinySerialOut.h │ │ │ ├── ATtinySerialOut.hpp │ │ │ └── OpenWindowAlarm.ino │ ├── Nunchuk │ │ ├── ArduinoNunchuk.cpp │ │ ├── ArduinoNunchuk.h │ │ ├── LICENSE.txt │ │ ├── README.txt │ │ ├── examples │ │ │ ├── ArduinoNunchukDemo │ │ │ │ └── ArduinoNunchukDemo.ino │ │ │ ├── DigisparkJoystickDemo │ │ │ │ └── DigisparkJoystickDemo.ino │ │ │ └── DigisparkUSBDemo │ │ │ │ └── DigisparkUSBDemo.ino │ │ └── keywords.txt │ ├── OneWire │ │ ├── OneWire.cpp │ │ ├── OneWire.h │ │ ├── examples │ │ │ ├── DS18x20_Temperature │ │ │ │ └── DS18x20_Temperature.ino │ │ │ ├── DS2408_Switch │ │ │ │ └── DS2408_Switch.ino │ │ │ ├── DS250x_PROM │ │ │ │ └── DS250x_PROM.ino │ │ │ └── Digispark_Example │ │ │ │ └── Digispark_Example.ino │ │ └── keywords.txt │ ├── TinyWireM │ │ ├── README.md │ │ ├── TinyWireM.cpp │ │ ├── TinyWireM.h │ │ ├── USI_TWI_Master.cpp │ │ ├── USI_TWI_Master.h │ │ ├── examples │ │ │ ├── Tiny85_Temp │ │ │ │ └── Tiny85_Temp.pde │ │ │ ├── Tiny85_Temp_LCD │ │ │ │ └── Tiny85_Temp_LCD.pde │ │ │ └── Tiny85_Temp_LCD_RTC │ │ │ │ └── Tiny85_Temp_LCD_RTC.pde │ │ ├── keywords.txt │ │ └── library.properties │ └── Wire │ │ ├── examples │ │ ├── SFRRanger_reader │ │ │ └── SFRRanger_reader.ino │ │ ├── digital_potentiometer │ │ │ └── digital_potentiometer.ino │ │ ├── master_reader │ │ │ └── master_reader.ino │ │ ├── master_writer │ │ │ └── master_writer.ino │ │ ├── slave_receiver │ │ │ └── slave_receiver.ino │ │ └── slave_sender │ │ │ └── slave_sender.ino │ │ ├── keywords.txt │ │ ├── library.properties │ │ └── src │ │ ├── SoftI2CMaster.h │ │ ├── SoftWire.h │ │ ├── USIWire.cpp │ │ ├── USIWire.h │ │ ├── USI_TWI_Master │ │ ├── USI_TWI_Master.c │ │ └── USI_TWI_Master.h │ │ ├── USI_TWI_Slave │ │ ├── USI_TWI_Slave.c │ │ └── USI_TWI_Slave.h │ │ ├── Wire.cpp │ │ ├── Wire.h │ │ ├── WireS.cpp │ │ ├── WireS.h │ │ ├── twi.c │ │ └── twi.h ├── platform.txt ├── programmers.txt └── variants │ ├── digispark │ ├── pins_arduino.c │ └── pins_arduino.h │ └── pro │ └── pins_arduino.h ├── framework-arduino-avr-digistump-1.6.8.zip ├── framework-arduino-avr-digistump-1.7.0.zip ├── framework-arduino-avr-digistump-1.7.1.zip ├── framework-arduino-avr-digistump-1.7.2.zip ├── framework-arduino-avr-digistump-1.7.3.zip ├── framework-arduino-avr-digistump-1.7.4.zip ├── framework-arduino-avr-digistump-1.7.5.zip ├── package_digistump_index.json ├── pictures ├── Bootloader2.5.jpg ├── Digistump1.6.8.jpg └── Micronucleus_Burn_Bootloader.jpg └── tools ├── Digistump_Drivers ├── DPinst.exe ├── DPinst64.exe ├── DigiSerial.inf ├── Digispark_Bootloader.cat ├── Digispark_Bootloader.inf ├── Digistump.Drivers.zip ├── amd64 │ ├── libusb0.dll │ ├── libusb0.sys │ ├── libusbK.dll │ └── lowcdc.sys ├── digiserial.cat ├── post_install.bat ├── readme.txt └── x86 │ ├── libusb0.sys │ ├── libusb0_x86.dll │ ├── libusbK_x86.dll │ └── lowcdc.sys ├── micronucleus-cli-2.5-aarch64-linux-gnu.tar.gz ├── micronucleus-cli-2.5-arm-linux-gnueabihf.tar.gz ├── micronucleus-cli-2.5-i686-linux-gnu.tar.gz ├── micronucleus-cli-2.5-i686-mingw32.zip ├── micronucleus-cli-2.5-pio-aarch64-linux-gnu.tar.gz ├── micronucleus-cli-2.5-pio-arm-linux-gnueabihf.tar.gz ├── micronucleus-cli-2.5-pio-i686-linux-gnu.tar.gz ├── micronucleus-cli-2.5-pio-i686-mingw32.zip ├── micronucleus-cli-2.5-pio-x86_64-apple-darwin.tar.gz ├── micronucleus-cli-2.5-pio-x86_64-linux-gnu.tar.gz ├── micronucleus-cli-2.5-pio-x86_64-mingw32.zip ├── micronucleus-cli-2.5-x86_64-apple-darwin.tar.gz ├── micronucleus-cli-2.5-x86_64-linux-gnu.tar.gz ├── micronucleus-cli-2.5-x86_64-mingw32.zip ├── micronucleus-cli-2.6-aarch64-linux-gnu.tar.gz ├── micronucleus-cli-2.6-arm-linux-gnueabihf.tar.gz ├── micronucleus-cli-2.6-i686-linux-gnu.tar.gz ├── micronucleus-cli-2.6-i686-mingw32.zip ├── micronucleus-cli-2.6-pio-aarch64-linux-gnu.tar.gz ├── micronucleus-cli-2.6-pio-arm-linux-gnueabihf.tar.gz ├── micronucleus-cli-2.6-pio-i686-linux-gnu.tar.gz ├── micronucleus-cli-2.6-pio-i686-mingw32.zip ├── micronucleus-cli-2.6-pio-x86_64-apple-darwin.tar.gz ├── micronucleus-cli-2.6-pio-x86_64-linux-gnu.tar.gz ├── micronucleus-cli-2.6-pio-x86_64-mingw32.zip ├── micronucleus-cli-2.6-x86_64-apple-darwin.tar.gz ├── micronucleus-cli-2.6-x86_64-linux-gnu.tar.gz └── micronucleus-cli-2.6-x86_64-mingw32.zip /.github/issue_template.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug Report 3 | about: If something isn't working as expected. 4 | assignees: ArminJo 5 | --- 6 | 7 | If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue. 8 | 9 | ## Bug Report 10 | 11 | ### Board 12 | * [ ] Digispark 13 | * [ ] Arduino Pro 14 | * [ ] MH-ET LIVE Tiny88 15 | 16 | ### IDE 17 | * [ ] Arduino IDE 18 | * [ ] Arduino Web Editor 19 | * [ ] Arduino Pro IDE 20 | * [ ] Sloeber IDE 21 | * [ ] PlatformIO IDE 22 | * [ ] Other - please specify 23 | 24 | 25 | ### Example from the core libraries to reproduce the issue 26 | 27 | 28 | ### Version 29 | * [ ] Yes I use the latest core version and verified this! 30 | * [ ] Other - please specify 31 | 32 | Please delete all unchecked lines above :-) 33 | 34 | ### Current behavior 35 | 36 | 37 | 38 | 39 | 40 | 41 | ### Expected behavior 42 | 43 | 44 | ### Additional context 45 | 46 | -------------------------------------------------------------------------------- /HID_UsageTables1.1.2v2 -Chapter10.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/HID_UsageTables1.1.2v2 -Chapter10.pdf -------------------------------------------------------------------------------- /Keyboard Scan Code Specification -Appendix C.doc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/Keyboard Scan Code Specification -Appendix C.doc -------------------------------------------------------------------------------- /LinuxUSKeyboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/LinuxUSKeyboard.png -------------------------------------------------------------------------------- /digistump-avr-1.6.8.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.6.8.zip -------------------------------------------------------------------------------- /digistump-avr-1.7.0.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.7.0.zip -------------------------------------------------------------------------------- /digistump-avr-1.7.1.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.7.1.zip -------------------------------------------------------------------------------- /digistump-avr-1.7.2.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.7.2.zip -------------------------------------------------------------------------------- /digistump-avr-1.7.3.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.7.3.zip -------------------------------------------------------------------------------- /digistump-avr-1.7.4.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.7.4.zip -------------------------------------------------------------------------------- /digistump-avr-1.7.5.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr-1.7.5.zip -------------------------------------------------------------------------------- /digistump-avr/cores/pro/Printable.h: -------------------------------------------------------------------------------- 1 | /* 2 | Printable.h - Interface class that allows printing of complex types 3 | Copyright (c) 2011 Adrian McEwen. All right reserved. 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | */ 19 | 20 | #ifndef Printable_h 21 | #define Printable_h 22 | 23 | #include 24 | 25 | class Print; 26 | 27 | /** The Printable class provides a way for new classes to allow themselves to be printed. 28 | By deriving from Printable and implementing the printTo method, it will then be possible 29 | for users to print out instances of this class by passing them into the usual 30 | Print::print and Print::println methods. 31 | */ 32 | 33 | class Printable 34 | { 35 | public: 36 | virtual size_t printTo(Print& p) const = 0; 37 | }; 38 | 39 | #endif 40 | 41 | -------------------------------------------------------------------------------- /digistump-avr/cores/pro/TinySoftwareSPI.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2012 by Thomas Carpenter 3 | * Software based SPI Master Library for Tiny core. 4 | * 5 | * This file is free software; you can redistribute it and/or modify 6 | * it under the terms of either the GNU General Public License version 2 7 | * or the GNU Lesser General Public License version 2.1, both as 8 | * published by the Free Software Foundation. 9 | */ 10 | 11 | #ifndef _SPI_H_INCLUDED 12 | //Uses the same guard as the SPI class as the two cannot be used together 13 | #define _SPI_H_INCLUDED 14 | 15 | #include 16 | #include 17 | 18 | #define SPI_MODE0 0 19 | #define SPI_MODE1 1 20 | #define SPI_MODE2 2 21 | #define SPI_MODE3 3 22 | 23 | #define SPI_CLOCK_DIV4 0x00 24 | #define SPI_CLOCK_DIV16 0x01 25 | #define SPI_CLOCK_DIV64 0x02 26 | #define SPI_CLOCK_DIV128 0x03 27 | #define SPI_CLOCK_DIV2 0x04 28 | #define SPI_CLOCK_DIV8 0x05 29 | #define SPI_CLOCK_DIV32 0x06 30 | 31 | class SoftSPIClass; 32 | typedef byte (SoftSPIClass::*TransferFunction)(byte _data); 33 | 34 | class SoftSPIClass { 35 | public: 36 | SoftSPIClass(); 37 | private: 38 | TransferFunction transferType; 39 | byte noTransfer(byte _data); 40 | byte transferMode0(byte _data); 41 | byte transferMode1(byte _data); 42 | byte transferMode2(byte _data); 43 | byte transferMode3(byte _data); 44 | public: 45 | byte transfer(byte _data); 46 | 47 | // SPI Configuration methods 48 | #if defined(SS) && defined(MOSI) && defined(MISO) && defined(SCK) 49 | void begin(); // Default to the preset SPI pins 50 | #endif 51 | void begin(byte SCK_, byte MOSI_, byte MISO_, byte SS_); //No SS specified, so require pin designation 52 | void end(); 53 | 54 | void setBitOrder(uint8_t); 55 | void setDataMode(uint8_t); 56 | void setClockDivider(uint8_t); 57 | 58 | void writeSS(boolean state); 59 | private: 60 | byte _rate; 61 | byte _bitOrder; 62 | byte _mode; 63 | boolean _running; 64 | byte _SS; 65 | byte _SCK; 66 | byte _MISO; 67 | byte _MOSI; 68 | volatile uint8_t* _MOSI_PORT; 69 | volatile uint8_t* _SS_PORT; 70 | volatile uint8_t* _SCK_PORT; 71 | volatile uint8_t* _MISO_PIN; 72 | byte _SS_HIGH; 73 | byte _MOSI_HIGH; 74 | byte _SCK_HIGH; 75 | byte _SS_LOW; 76 | byte _MOSI_LOW; 77 | byte _SCK_LOW; 78 | byte _MISO_MASK; 79 | }; 80 | 81 | extern SoftSPIClass SPI; 82 | 83 | #endif -------------------------------------------------------------------------------- /digistump-avr/cores/pro/TinySoftwareSerial.h: -------------------------------------------------------------------------------- 1 | 2 | #if USE_SOFTWARE_SERIAL 3 | #ifndef TinySoftwareSerial_h 4 | #define TinySoftwareSerial_h 5 | #include 6 | #include "Stream.h" 7 | 8 | #if !defined(ACSR) && defined(ACSRA) 9 | #define ACSR ACSRA 10 | #endif 11 | 12 | #if (RAMEND < 250) 13 | #define SERIAL_BUFFER_SIZE 8 14 | #elif (RAMEND < 500) 15 | #define SERIAL_BUFFER_SIZE 16 16 | #elif (RAMEND < 1000) 17 | #define SERIAL_BUFFER_SIZE 32 18 | #else 19 | #define SERIAL_BUFFER_SIZE 128 20 | #endif 21 | struct soft_ring_buffer 22 | { 23 | unsigned char buffer[SERIAL_BUFFER_SIZE]; 24 | int head; 25 | int tail; 26 | }; 27 | 28 | extern "C"{ 29 | void uartDelay() __attribute__ ((naked)); 30 | uint8_t getch(); 31 | void store_char(unsigned char c, soft_ring_buffer *buffer); 32 | } 33 | 34 | class TinySoftwareSerial : public Stream 35 | { 36 | public: //should be private but needed by extern "C" {} functions. 37 | uint8_t _rxmask; 38 | uint8_t _txmask; 39 | uint8_t _txunmask; 40 | soft_ring_buffer *_rx_buffer; 41 | uint8_t _delayCount; 42 | public: 43 | TinySoftwareSerial(soft_ring_buffer *rx_buffer, uint8_t txBit, uint8_t rxBit); 44 | void begin(long); 45 | void end(); 46 | virtual int available(void); 47 | virtual int peek(void); 48 | virtual int read(void); 49 | virtual void flush(void); 50 | virtual size_t write(uint8_t); 51 | using Print::write; // pull in write(str) and write(buf, size) from Print 52 | operator bool(); 53 | }; 54 | 55 | #if (!defined(UBRRH) && !defined(UBRR0H)) || USE_SOFTWARE_SERIAL 56 | extern TinySoftwareSerial Serial; 57 | #endif 58 | 59 | //extern void putch(uint8_t); 60 | #endif 61 | #endif 62 | -------------------------------------------------------------------------------- /digistump-avr/cores/pro/WMath.cpp: -------------------------------------------------------------------------------- 1 | /* -*- mode: jde; c-basic-offset: 2; indent-tabs-mode: nil -*- */ 2 | 3 | /* 4 | Part of the Wiring project - http://wiring.org.co 5 | Copyright (c) 2004-06 Hernando Barragan 6 | Modified 13 August 2006, David A. Mellis for Arduino - http://www.arduino.cc/ 7 | 8 | This library is free software; you can redistribute it and/or 9 | modify it under the terms of the GNU Lesser General Public 10 | License as published by the Free Software Foundation; either 11 | version 2.1 of the License, or (at your option) any later version. 12 | 13 | This library is distributed in the hope that it will be useful, 14 | but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 16 | Lesser General Public License for more details. 17 | 18 | You should have received a copy of the GNU Lesser General 19 | Public License along with this library; if not, write to the 20 | Free Software Foundation, Inc., 59 Temple Place, Suite 330, 21 | Boston, MA 02111-1307 USA 22 | 23 | $Id$ 24 | */ 25 | 26 | extern "C" { 27 | #include "stdlib.h" 28 | } 29 | 30 | void randomSeed(unsigned int seed) 31 | { 32 | if (seed != 0) { 33 | srandom(seed); 34 | } 35 | } 36 | 37 | long random(long howbig) 38 | { 39 | if (howbig == 0) { 40 | return 0; 41 | } 42 | return random() % howbig; 43 | } 44 | 45 | long random(long howsmall, long howbig) 46 | { 47 | if (howsmall >= howbig) { 48 | return howsmall; 49 | } 50 | long diff = howbig - howsmall; 51 | return random(diff) + howsmall; 52 | } 53 | 54 | long map(long x, long in_min, long in_max, long out_min, long out_max) 55 | { 56 | return (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min; 57 | } 58 | 59 | unsigned int makeWord(unsigned int w) { return w; } 60 | unsigned int makeWord(unsigned char h, unsigned char l) { return (h << 8) | l; } -------------------------------------------------------------------------------- /digistump-avr/cores/pro/WProgram.h: -------------------------------------------------------------------------------- 1 | //For compatibility with older programs 2 | #include "Arduino.h" -------------------------------------------------------------------------------- /digistump-avr/cores/pro/hooks.c: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2012 Arduino. All right reserved. 3 | 4 | This library is free software; you can redistribute it and/or 5 | modify it under the terms of the GNU Lesser General Public 6 | License as published by the Free Software Foundation; either 7 | version 2.1 of the License, or (at your option) any later version. 8 | 9 | This library is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 12 | See the GNU Lesser General Public License for more details. 13 | 14 | You should have received a copy of the GNU Lesser General Public 15 | License along with this library; if not, write to the Free Software 16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 17 | */ 18 | 19 | /** 20 | * Empty yield() hook. 21 | * 22 | * This function is intended to be used by library writers to build 23 | * libraries or sketches that supports cooperative threads. 24 | * 25 | * Its defined as a weak symbol and it can be redefined to implement a 26 | * real cooperative scheduler. 27 | */ 28 | static void __empty() { 29 | // Empty 30 | } 31 | void yield(void) __attribute__ ((weak, alias("__empty"))); 32 | -------------------------------------------------------------------------------- /digistump-avr/cores/pro/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | int main(void) 4 | { 5 | //OSCCAL = TUNED_OSCCAL_VALUE; //set the oscillator calibration value based on the pins_arduino.h file. If this is not set, it will be optimised away - it would boil down to 1 = 1; 6 | init(); 7 | 8 | setup(); 9 | 10 | for (;;) 11 | loop(); 12 | 13 | return 0; 14 | } 15 | 16 | -------------------------------------------------------------------------------- /digistump-avr/cores/pro/new.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | void * operator new(size_t size) 4 | { 5 | return malloc(size); 6 | } 7 | 8 | void *operator new[](size_t size) { 9 | return malloc(size); 10 | } 11 | 12 | void operator delete(void * ptr) 13 | { 14 | free(ptr); 15 | } 16 | 17 | void operator delete[](void * ptr) { 18 | free(ptr); 19 | } 20 | 21 | int __cxa_guard_acquire(__guard *g) {return !*(char *)(g);}; 22 | void __cxa_guard_release (__guard *g) {*(char *)g = 1;}; 23 | void __cxa_guard_abort (__guard *) {}; 24 | 25 | void __cxa_pure_virtual(void) {}; 26 | 27 | -------------------------------------------------------------------------------- /digistump-avr/cores/pro/new.h: -------------------------------------------------------------------------------- 1 | /* Header to define new/delete operators as they aren't provided by avr-gcc by default 2 | Taken from http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=59453 3 | */ 4 | 5 | #ifndef NEW_H 6 | #define NEW_H 7 | 8 | #include 9 | 10 | void * operator new(size_t size); 11 | void * operator new[](size_t size); 12 | void operator delete(void * ptr); 13 | void operator delete[](void * ptr); 14 | 15 | __extension__ typedef int __guard __attribute__((mode (__DI__))); 16 | 17 | extern "C" int __cxa_guard_acquire(__guard *); 18 | extern "C" void __cxa_guard_release (__guard *); 19 | extern "C" void __cxa_guard_abort (__guard *); 20 | 21 | extern "C" void __cxa_pure_virtual(void); 22 | 23 | #endif 24 | 25 | -------------------------------------------------------------------------------- /digistump-avr/cores/pro/wiring_shift.c: -------------------------------------------------------------------------------- 1 | /* 2 | wiring_shift.c - shiftOut() function 3 | Part of Arduino - http://www.arduino.cc/ 4 | 5 | Copyright (c) 2005-2006 David A. Mellis 6 | 7 | This library is free software; you can redistribute it and/or 8 | modify it under the terms of the GNU Lesser General Public 9 | License as published by the Free Software Foundation; either 10 | version 2.1 of the License, or (at your option) any later version. 11 | 12 | This library is distributed in the hope that it will be useful, 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 | Lesser General Public License for more details. 16 | 17 | You should have received a copy of the GNU Lesser General 18 | Public License along with this library; if not, write to the 19 | Free Software Foundation, Inc., 59 Temple Place, Suite 330, 20 | Boston, MA 02111-1307 USA 21 | 22 | $Id: wiring.c 248 2007-02-03 15:36:30Z mellis $ 23 | */ 24 | 25 | #include "wiring_private.h" 26 | 27 | uint8_t shiftIn(uint8_t dataPin, uint8_t clockPin, uint8_t bitOrder) { 28 | uint8_t value = 0; 29 | uint8_t i; 30 | 31 | for (i = 0; i < 8; ++i) { 32 | digitalWrite(clockPin, HIGH); 33 | if (bitOrder == LSBFIRST) 34 | value |= digitalRead(dataPin) << i; 35 | else 36 | value |= digitalRead(dataPin) << (7 - i); 37 | digitalWrite(clockPin, LOW); 38 | } 39 | return value; 40 | } 41 | 42 | void shiftOut(uint8_t dataPin, uint8_t clockPin, uint8_t bitOrder, uint8_t val) 43 | { 44 | uint8_t i; 45 | 46 | for (i = 0; i < 8; i++) { 47 | if (bitOrder == LSBFIRST) 48 | digitalWrite(dataPin, !!(val & (1 << i))); 49 | else 50 | digitalWrite(dataPin, !!(val & (1 << (7 - i)))); 51 | 52 | digitalWrite(clockPin, HIGH); 53 | digitalWrite(clockPin, LOW); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/Arduino.h: -------------------------------------------------------------------------------- 1 | #ifndef Arduino_h 2 | #define Arduino_h 3 | 4 | #include 5 | 6 | #define NOT_AN_INTERRUPT -1 7 | #endif 8 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/HardwareSerial.h: -------------------------------------------------------------------------------- 1 | /* 2 | HardwareSerial.h - Hardware serial library for Wiring 3 | Copyright (c) 2006 Nicholas Zambetti. All right reserved. 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Modified 28 September 2010 by Mark Sproul 20 | */ 21 | 22 | #ifndef HardwareSerial_h 23 | #define HardwareSerial_h 24 | 25 | #include 26 | 27 | #include "core_build_options.h" 28 | #include "Stream.h" 29 | 30 | struct ring_buffer; 31 | 32 | class HardwareSerial : public Stream 33 | { 34 | private: 35 | ring_buffer *_rx_buffer; 36 | volatile uint8_t *_ubrrh; 37 | volatile uint8_t *_ubrrl; 38 | volatile uint8_t *_ucsra; 39 | volatile uint8_t *_ucsrb; 40 | volatile uint8_t *_udr; 41 | uint8_t _rxen; 42 | uint8_t _txen; 43 | uint8_t _rxcie; 44 | uint8_t _udre; 45 | uint8_t _u2x; 46 | public: 47 | HardwareSerial(ring_buffer *rx_buffer, 48 | volatile uint8_t *ubrrh, volatile uint8_t *ubrrl, 49 | volatile uint8_t *ucsra, volatile uint8_t *ucsrb, 50 | volatile uint8_t *udr, 51 | uint8_t rxen, uint8_t txen, uint8_t rxcie, uint8_t udre, uint8_t u2x); 52 | void begin(long); 53 | void end(); 54 | operator bool() { return true; } // To support "while (!Serial); // wait for serial port to connect. Needed for Leonardo only 55 | virtual int available(void); 56 | virtual int peek(void); 57 | virtual int read(void); 58 | virtual void flush(void); 59 | virtual size_t write(uint8_t); 60 | using Print::write; // pull in write(str) and write(buf, size) from Print 61 | }; 62 | 63 | #if (defined(UBRRH) || defined(UBRR0H)) && ! DEFAULT_TO_TINY_DEBUG_SERIAL 64 | extern HardwareSerial Serial; 65 | #elif defined(USBCON) 66 | #include "usb_api.h" 67 | #endif 68 | #if defined(UBRR1H) 69 | extern HardwareSerial Serial1; 70 | #endif 71 | #if defined(UBRR2H) 72 | extern HardwareSerial Serial2; 73 | #endif 74 | #if defined(UBRR3H) 75 | extern HardwareSerial Serial3; 76 | #endif 77 | 78 | #endif 79 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/Printable.h: -------------------------------------------------------------------------------- 1 | /* 2 | Printable.h - Interface class that allows printing of complex types 3 | Copyright (c) 2011 Adrian McEwen. All right reserved. 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | */ 19 | 20 | #ifndef Printable_h 21 | #define Printable_h 22 | 23 | #include 24 | 25 | class Print; 26 | 27 | /** The Printable class provides a way for new classes to allow themselves to be printed. 28 | By deriving from Printable and implementing the printTo method, it will then be possible 29 | for users to print out instances of this class by passing them into the usual 30 | Print::print and Print::println methods. 31 | */ 32 | 33 | class Printable 34 | { 35 | public: 36 | virtual size_t printTo(Print& p) const = 0; 37 | }; 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/Stream.h: -------------------------------------------------------------------------------- 1 | /* 2 | Stream.h - base class for character-based streams. 3 | Copyright (c) 2010 David A. Mellis. All right reserved. 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | */ 19 | 20 | #ifndef Stream_h 21 | #define Stream_h 22 | 23 | #include 24 | #include "Print.h" 25 | 26 | class Stream : public Print 27 | { 28 | public: 29 | virtual int available() = 0; 30 | virtual int read() = 0; 31 | virtual int peek() = 0; 32 | virtual void flush() = 0; 33 | }; 34 | 35 | #endif 36 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/TinyDebugSerial.cpp: -------------------------------------------------------------------------------- 1 | /*============================================================================== 2 | 3 | TinyDebugSerial.cpp - Tiny write-only software serial. 4 | 5 | Copyright 2010 Rowdy Dog Software. 6 | 7 | This file is part of Arduino-Tiny. 8 | 9 | Arduino-Tiny is free software: you can redistribute it and/or modify it 10 | under the terms of the GNU Lesser General Public License as published by 11 | the Free Software Foundation, either version 3 of the License, or (at your 12 | option) any later version. 13 | 14 | Arduino-Tiny is distributed in the hope that it will be useful, but 15 | WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 17 | License for more details. 18 | 19 | You should have received a copy of the GNU Lesser General Public License 20 | along with Arduino-Tiny. If not, see . 21 | 22 | ==============================================================================*/ 23 | 24 | #include "core_build_options.h" 25 | #include "TinyDebugSerial.h" 26 | 27 | static TinyDebugSerialWriter stub; 28 | 29 | void TinyDebugSerial::useStub( void ) 30 | { 31 | _writer = &stub; 32 | _writer->init(); 33 | } 34 | 35 | TinyDebugSerial::TinyDebugSerial( void ) 36 | { 37 | useStub(); 38 | } 39 | 40 | #if defined( DEFAULT_TO_TINY_DEBUG_SERIAL ) && DEFAULT_TO_TINY_DEBUG_SERIAL 41 | TinyDebugSerial Serial; 42 | #endif 43 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/TinyDebugSerial115200.cpp: -------------------------------------------------------------------------------- 1 | /*============================================================================== 2 | 3 | TinyDebugSerial.cpp - Tiny write-only software serial. 4 | 5 | Copyright 2010 Rowdy Dog Software. 6 | 7 | This file is part of Arduino-Tiny. 8 | 9 | Arduino-Tiny is free software: you can redistribute it and/or modify it 10 | under the terms of the GNU Lesser General Public License as published by 11 | the Free Software Foundation, either version 3 of the License, or (at your 12 | option) any later version. 13 | 14 | Arduino-Tiny is distributed in the hope that it will be useful, but 15 | WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 17 | License for more details. 18 | 19 | You should have received a copy of the GNU Lesser General Public License 20 | along with Arduino-Tiny. If not, see . 21 | 22 | ==============================================================================*/ 23 | 24 | #include "TinyDebugSerial.h" 25 | 26 | TinyDebugSerialWriter_115200 tdsw115200; 27 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/TinyDebugSerial38400.cpp: -------------------------------------------------------------------------------- 1 | /*============================================================================== 2 | 3 | TinyDebugSerial.cpp - Tiny write-only software serial. 4 | 5 | Copyright 2010 Rowdy Dog Software. 6 | 7 | This file is part of Arduino-Tiny. 8 | 9 | Arduino-Tiny is free software: you can redistribute it and/or modify it 10 | under the terms of the GNU Lesser General Public License as published by 11 | the Free Software Foundation, either version 3 of the License, or (at your 12 | option) any later version. 13 | 14 | Arduino-Tiny is distributed in the hope that it will be useful, but 15 | WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 17 | License for more details. 18 | 19 | You should have received a copy of the GNU Lesser General Public License 20 | along with Arduino-Tiny. If not, see . 21 | 22 | ==============================================================================*/ 23 | 24 | #include "TinyDebugSerial.h" 25 | 26 | TinyDebugSerialWriter_38400 tdsw38400; 27 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/TinyDebugSerial9600.cpp: -------------------------------------------------------------------------------- 1 | /*============================================================================== 2 | 3 | TinyDebugSerial.cpp - Tiny write-only software serial. 4 | 5 | Copyright 2010 Rowdy Dog Software. 6 | 7 | This file is part of Arduino-Tiny. 8 | 9 | Arduino-Tiny is free software: you can redistribute it and/or modify it 10 | under the terms of the GNU Lesser General Public License as published by 11 | the Free Software Foundation, either version 3 of the License, or (at your 12 | option) any later version. 13 | 14 | Arduino-Tiny is distributed in the hope that it will be useful, but 15 | WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 17 | License for more details. 18 | 19 | You should have received a copy of the GNU Lesser General Public License 20 | along with Arduino-Tiny. If not, see . 21 | 22 | ==============================================================================*/ 23 | 24 | #include "TinyDebugSerial.h" 25 | 26 | TinyDebugSerialWriter_9600 tdsw9600; 27 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/TinyDebugSerialErrors.cpp: -------------------------------------------------------------------------------- 1 | /*============================================================================== 2 | 3 | TinyDebugSerial.cpp - Tiny write-only software serial. 4 | 5 | Copyright 2010 Rowdy Dog Software. 6 | 7 | This file is part of Arduino-Tiny. 8 | 9 | Arduino-Tiny is free software: you can redistribute it and/or modify it 10 | under the terms of the GNU Lesser General Public License as published by 11 | the Free Software Foundation, either version 3 of the License, or (at your 12 | option) any later version. 13 | 14 | Arduino-Tiny is distributed in the hope that it will be useful, but 15 | WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 17 | License for more details. 18 | 19 | You should have received a copy of the GNU Lesser General Public License 20 | along with Arduino-Tiny. If not, see . 21 | 22 | ==============================================================================*/ 23 | 24 | #include "TinyDebugSerial.h" 25 | 26 | void TinyDebugSerialWriterInternalBug( void ) { } 27 | void TinyDebugSerialBadBaud( void ) { } 28 | void TinyDebugSerialBaudMustBeConstant( void ) { } 29 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/WConstants.h: -------------------------------------------------------------------------------- 1 | #include "wiring.h" 2 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/WMath.cpp: -------------------------------------------------------------------------------- 1 | /* -*- mode: jde; c-basic-offset: 2; indent-tabs-mode: nil -*- */ 2 | 3 | /* 4 | Part of the Wiring project - http://wiring.org.co 5 | Copyright (c) 2004-06 Hernando Barragan 6 | Modified 13 August 2006, David A. Mellis for Arduino - http://www.arduino.cc/ 7 | 8 | This library is free software; you can redistribute it and/or 9 | modify it under the terms of the GNU Lesser General Public 10 | License as published by the Free Software Foundation; either 11 | version 2.1 of the License, or (at your option) any later version. 12 | 13 | This library is distributed in the hope that it will be useful, 14 | but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 16 | Lesser General Public License for more details. 17 | 18 | You should have received a copy of the GNU Lesser General 19 | Public License along with this library; if not, write to the 20 | Free Software Foundation, Inc., 59 Temple Place, Suite 330, 21 | Boston, MA 02111-1307 USA 22 | 23 | $Id$ 24 | */ 25 | 26 | extern "C" { 27 | #include "stdlib.h" 28 | } 29 | 30 | void randomSeed(unsigned int seed) 31 | { 32 | if (seed != 0) { 33 | srandom(seed); 34 | } 35 | } 36 | 37 | long random(long howbig) 38 | { 39 | if (howbig == 0) { 40 | return 0; 41 | } 42 | return random() % howbig; 43 | } 44 | 45 | long random(long howsmall, long howbig) 46 | { 47 | if (howsmall >= howbig) { 48 | return howsmall; 49 | } 50 | long diff = howbig - howsmall; 51 | return random(diff) + howsmall; 52 | } 53 | 54 | long map(long x, long in_min, long in_max, long out_min, long out_max) 55 | { 56 | return (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min; 57 | } 58 | 59 | unsigned int makeWord(unsigned int w) { return w; } 60 | unsigned int makeWord(unsigned char h, unsigned char l) { return (h << 8) | l; } -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/WProgram.h: -------------------------------------------------------------------------------- 1 | #ifndef WProgram_h 2 | #define WProgram_h 3 | 4 | #include 5 | #include 6 | #include 7 | 8 | #include 9 | 10 | #include "core_build_options.h" 11 | #include "core_pins.h" 12 | #include "wiring.h" 13 | #include "pins_arduino.h" 14 | 15 | #ifdef __cplusplus 16 | extern "C"{ 17 | void yield(void); 18 | } 19 | #endif 20 | 21 | #ifdef __cplusplus 22 | #include "WCharacter.h" 23 | #include "WString.h" 24 | #include "TinyDebugSerial.h" 25 | #include "HardwareSerial.h" 26 | 27 | uint16_t makeWord(uint16_t w); 28 | uint16_t makeWord(byte h, byte l); 29 | 30 | #define word(...) makeWord(__VA_ARGS__) 31 | 32 | unsigned long pulseIn(uint8_t pin, uint8_t state, unsigned long timeout = 1000000L); 33 | 34 | void tone(uint8_t _pin, unsigned int frequency, unsigned long duration = 0); 35 | void noTone(uint8_t _pin = 255); 36 | 37 | // WMath prototypes 38 | long random(long); 39 | long random(long, long); 40 | void randomSeed(unsigned int); 41 | long map(long, long, long, long, long); 42 | 43 | /* 44 | fix? On the Mega processors, the analogs are also "extended" digital pins. 45 | To (sort of) work the same way with this core, the following constants 46 | would have to be valid arguments to digitalRead, digitalWrite, and pinMode 47 | ("the digitals"). Which means the digitals would have to check for pins 48 | over A0 and then subtract A0. The current plan is to wait until someone 49 | wants this feature. 50 | */ 51 | #if CORE_ANALOG_COUNT >= 1 52 | const static uint8_t A0 = CORE_ANALOG_FIRST + 0; 53 | #endif 54 | 55 | #if CORE_ANALOG_COUNT >= 2 56 | const static uint8_t A1 = CORE_ANALOG_FIRST + 1; 57 | #endif 58 | 59 | #if CORE_ANALOG_COUNT >= 3 60 | const static uint8_t A2 = CORE_ANALOG_FIRST + 2; 61 | #endif 62 | 63 | #if CORE_ANALOG_COUNT >= 4 64 | const static uint8_t A3 = CORE_ANALOG_FIRST + 3; 65 | #endif 66 | 67 | #if CORE_ANALOG_COUNT >= 5 68 | const static uint8_t A4 = CORE_ANALOG_FIRST + 4; 69 | #endif 70 | 71 | #if CORE_ANALOG_COUNT >= 6 72 | const static uint8_t A5 = CORE_ANALOG_FIRST + 5; 73 | #endif 74 | 75 | #if CORE_ANALOG_COUNT >= 7 76 | const static uint8_t A6 = CORE_ANALOG_FIRST + 6; 77 | #endif 78 | 79 | #if CORE_ANALOG_COUNT >= 8 80 | const static uint8_t A7 = CORE_ANALOG_FIRST + 7; 81 | #endif 82 | 83 | #if CORE_ANALOG_COUNT >= 9 84 | #error Update the A* definitions for the selected processor. 85 | #endif 86 | 87 | #endif 88 | 89 | #endif 90 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/core_macros.h: -------------------------------------------------------------------------------- 1 | /*============================================================================== 2 | 3 | core_macros.h - Simple but handy macros. 4 | 5 | Copyright 2010 Rowdy Dog Software. 6 | 7 | This file is part of Arduino-Tiny. 8 | 9 | Arduino-Tiny is free software: you can redistribute it and/or modify it 10 | under the terms of the GNU Lesser General Public License as published by 11 | the Free Software Foundation, either version 3 of the License, or (at your 12 | option) any later version. 13 | 14 | Arduino-Tiny is distributed in the hope that it will be useful, but 15 | WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 16 | or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 17 | License for more details. 18 | 19 | You should have received a copy of the GNU Lesser General Public License 20 | along with Arduino-Tiny. If not, see . 21 | 22 | ==============================================================================*/ 23 | 24 | #ifndef core_macros_h 25 | #define core_macros_h 26 | 27 | 28 | /*============================================================================= 29 | Bitmask macros 30 | =============================================================================*/ 31 | 32 | #define MASK1(b1) ( (1< 2 | 3 | int main(void) 4 | { 5 | init(); 6 | 7 | setup(); 8 | 9 | for (;;) 10 | loop(); 11 | 12 | return 0; 13 | } 14 | 15 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/new.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | void * operator new(size_t size) 4 | { 5 | return malloc(size); 6 | } 7 | 8 | void *operator new[](size_t size) { 9 | return malloc(size); 10 | } 11 | 12 | void operator delete(void * ptr) 13 | { 14 | free(ptr); 15 | } 16 | 17 | void operator delete[](void * ptr) { 18 | free(ptr); 19 | } 20 | 21 | int __cxa_guard_acquire(__guard *g) {return !*(char *)(g);}; 22 | void __cxa_guard_release (__guard *g) {*(char *)g = 1;}; 23 | void __cxa_guard_abort (__guard *) {}; 24 | 25 | void __cxa_pure_virtual(void) {}; 26 | 27 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/new.h: -------------------------------------------------------------------------------- 1 | /* Header to define new/delete operators as they aren't provided by avr-gcc by default 2 | Taken from http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=59453 3 | */ 4 | 5 | #ifndef NEW_H 6 | #define NEW_H 7 | 8 | #include 9 | 10 | void * operator new(size_t size); 11 | void * operator new[](size_t size); 12 | void operator delete(void * ptr); 13 | void operator delete[](void * ptr); 14 | 15 | __extension__ typedef int __guard __attribute__((mode (__DI__))); 16 | 17 | extern "C" int __cxa_guard_acquire(__guard *); 18 | extern "C" void __cxa_guard_release (__guard *); 19 | extern "C" void __cxa_guard_abort (__guard *); 20 | 21 | extern "C" void __cxa_pure_virtual(void); 22 | 23 | #endif 24 | 25 | -------------------------------------------------------------------------------- /digistump-avr/cores/tiny/wiring_shift.c: -------------------------------------------------------------------------------- 1 | /* 2 | wiring_shift.c - shiftOut() function 3 | Part of Arduino - http://www.arduino.cc/ 4 | 5 | Copyright (c) 2005-2006 David A. Mellis 6 | 7 | This library is free software; you can redistribute it and/or 8 | modify it under the terms of the GNU Lesser General Public 9 | License as published by the Free Software Foundation; either 10 | version 2.1 of the License, or (at your option) any later version. 11 | 12 | This library is distributed in the hope that it will be useful, 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 | Lesser General Public License for more details. 16 | 17 | You should have received a copy of the GNU Lesser General 18 | Public License along with this library; if not, write to the 19 | Free Software Foundation, Inc., 59 Temple Place, Suite 330, 20 | Boston, MA 02111-1307 USA 21 | 22 | $Id: wiring.c 248 2007-02-03 15:36:30Z mellis $ 23 | */ 24 | 25 | #include "wiring_private.h" 26 | 27 | uint8_t shiftIn(uint8_t dataPin, uint8_t clockPin, uint8_t bitOrder) { 28 | uint8_t value = 0; 29 | uint8_t i; 30 | 31 | for (i = 0; i < 8; ++i) { 32 | digitalWrite(clockPin, HIGH); 33 | if (bitOrder == LSBFIRST) 34 | value |= digitalRead(dataPin) << i; 35 | else 36 | value |= digitalRead(dataPin) << (7 - i); 37 | digitalWrite(clockPin, LOW); 38 | } 39 | return value; 40 | } 41 | 42 | void shiftOut(uint8_t dataPin, uint8_t clockPin, uint8_t bitOrder, uint8_t val) 43 | { 44 | uint8_t i; 45 | 46 | for (i = 0; i < 8; i++) { 47 | if (bitOrder == LSBFIRST) 48 | digitalWrite(dataPin, !!(val & (1 << i))); 49 | else 50 | digitalWrite(dataPin, !!(val & (1 << (7 - i)))); 51 | 52 | digitalWrite(clockPin, HIGH); 53 | digitalWrite(clockPin, LOW); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Adafruit_NeoPixel/README.md: -------------------------------------------------------------------------------- 1 | Adafruit NeoPixel library 2 | ========================= 3 | 4 | Arduino library for controlling single-wire-based LED pixels and strip such as the [Adafruit 60 LED/meter Digital LED strip][strip], the [Adafruit FLORA RGB Smart Pixel][flora], the [Adafruit Breadboard-friendly RGB Smart Pixel][pixel], the [Adafruit NeoPixel Stick][stick], and the [Adafruit NeoPixel Shield][shield]. 5 | 6 | After downloading, rename folder to 'Adafruit_NeoPixel' and install in Arduino Libraries folder. Restart Arduino IDE, then open File->Sketchbook->Library->Adafruit_NeoPixel->strandtest sketch. 7 | 8 | [flora]: http://adafruit.com/products/1060 9 | [strip]: http://adafruit.com/products/1138 10 | [pixel]: http://adafruit.com/products/1312 11 | [stick]: http://adafruit.com/products/1426 12 | [shield]: http://adafruit.com/products/1430 13 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Adafruit_NeoPixel/examples/digispark/digispark.ino: -------------------------------------------------------------------------------- 1 | // NeoPixel Ring simple sketch (c) 2013 Shae Erisson 2 | // released under the GPLv3 license to match the rest of the AdaFruit NeoPixel library 3 | #include 4 | 5 | // Which pin on the Arduino is connected to the NeoPixels? 6 | #define PIN 1 7 | 8 | // How many NeoPixels are attached to the Arduino? 9 | #define NUMPIXELS 1 10 | 11 | // When we setup the NeoPixel library, we tell it how many pixels, and which pin to use to send signals. 12 | // Note that for older NeoPixel strips you might need to change the third parameter--see the strandtest 13 | // example for more information on possible values. 14 | Adafruit_NeoPixel pixels = Adafruit_NeoPixel(NUMPIXELS, PIN, NEO_RGB + NEO_KHZ800); 15 | 16 | int delayval = 500; // delay for half a second 17 | 18 | void setup() { 19 | pixels.begin(); // This initializes the NeoPixel library. 20 | } 21 | 22 | void loop() { 23 | // For a set of NeoPixels the first NeoPixel is 0, second is 1, all the way up to the count of pixels minus one. 24 | for(int i=0;i 4 | 5 | // Which pin on the Arduino is connected to the NeoPixels? 6 | #define PIN 6 7 | 8 | // How many NeoPixels are attached to the Arduino? 9 | #define NUMPIXELS 16 10 | 11 | // When we setup the NeoPixel library, we tell it how many pixels, and which pin to use to send signals. 12 | // Note that for older NeoPixel strips you might need to change the third parameter--see the strandtest 13 | // example for more information on possible values. 14 | Adafruit_NeoPixel pixels = Adafruit_NeoPixel(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800); 15 | 16 | int delayval = 500; // delay for half a second 17 | 18 | void setup() { 19 | pixels.begin(); // This initializes the NeoPixel library. 20 | } 21 | 22 | void loop() { 23 | // For a set of NeoPixels the first NeoPixel is 0, second is 1, all the way up to the count of pixels minus one. 24 | for(int i=0;i 16 | 17 | class ArduinoWiiClassicController 18 | { 19 | public: 20 | int leftAnalogX; 21 | int leftAnalogY; 22 | int rightAnalogX; 23 | int rightAnalogY; 24 | 25 | int leftTrigger; //Analog, when partially pressed 26 | int rightTrigger; //Analog, when partially pressed 27 | 28 | int dpadUp; 29 | int dpadDown; 30 | int dpadLeft; 31 | int dpadRight; 32 | 33 | int leftTriggerButton; //Digital, when fully pressed 34 | int rightTriggerButton; //Digital, when fully pressed 35 | int minusButton; 36 | int homeButton; 37 | int plusButton; 38 | int zLeftButton; 39 | int bButton; 40 | int yButton; 41 | int aButton; 42 | int xButton; 43 | int zRightButton; 44 | 45 | void init(); 46 | void update(); 47 | 48 | private: 49 | void _sendByte(byte data, byte location); 50 | }; 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /digistump-avr/libraries/ArduinoWiiClassicController/LICENSE.txt: -------------------------------------------------------------------------------- 1 | LICENSE 2 | 3 | This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 444 Castro Street, Suite 900, Mountain View, California, 94041, USA. -------------------------------------------------------------------------------- /digistump-avr/libraries/ArduinoWiiClassicController/README.txt: -------------------------------------------------------------------------------- 1 | WiiClassicController - Library for the WCC for the Digispark / Arduino 2 | 3 | Copyright 2017 Eduardo Flores - Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License 4 | http://eduardofv.com/2017/02/06/wii-classic-controller-usb-arduino/ 5 | https://github.com/eduardofv/ArduinoWiiClassicController 6 | 7 | Based on ArduinoNunchuck by Gabriel Bianconi 8 | https://github.com/eduardofv/DigistumpArduino/tree/master/digistump-avr/libraries/Nunchuk 9 | Project URL: http://www.gabrielbianconi.com/projects/arduinonunchuk/ 10 | 11 | 12 | Based on the following resources: 13 | - http://www.windmeadow.com/node/42 14 | - http://todbot.com/blog/2008/02/18/wiichuck-wii-nunchuck-adapter-available/ 15 | - http://wiibrew.org/wiki/Wiimote/Extension_Controllers 16 | - http://www.instructables.com/id/USB-Wii-Classic-Controller/step9/Reading-the-Wii-Classic-Controller/ 17 | - http://wiibrew.org/wiki/Wiimote/Extension_Controllers/Classic_Controller 18 | 19 | 20 | -------------------------------------------------------------------------------- /digistump-avr/libraries/ArduinoWiiClassicController/examples/WiiClassicJoystick/WiiClassicJoystick.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * Use your Wii Classic Controller as a USB Joystick 3 | */ 4 | 5 | #include 6 | #include 7 | 8 | ArduinoWiiClassicController classic = ArduinoWiiClassicController(); 9 | 10 | void setup() { 11 | classic.init(); 12 | } 13 | 14 | 15 | void loop() { 16 | classic.update(); 17 | 18 | //Left Stick 19 | DigiJoystick.setX(byte(map(classic.rightAnalogX,0,32,0,255))); 20 | DigiJoystick.setY(byte(map(classic.rightAnalogY,0,32,255,0))); //Invert Y axis. Check on Windows 21 | 22 | //Right Stick 23 | DigiJoystick.setXROT(byte(map(classic.leftAnalogX,0,64,0,255))); 24 | DigiJoystick.setYROT(byte(map(classic.leftAnalogY,0,64,255,0))); //Invert Y axis. Check on Windows 25 | 26 | //Analog buttons 27 | DigiJoystick.setZROT(byte(map(classic.rightTriggerButton,0,32,0,255))); 28 | DigiJoystick.setSLIDER(byte(map(classic.leftTriggerButton,0,32,0,255))); 29 | 30 | byte buttonLSB = 0; 31 | bitWrite(buttonLSB, 0, classic.rightTriggerButton); 32 | bitWrite(buttonLSB, 1, classic.leftTriggerButton); 33 | bitWrite(buttonLSB, 2, classic.minusButton); 34 | bitWrite(buttonLSB, 3, classic.homeButton); 35 | bitWrite(buttonLSB, 4, classic.plusButton); 36 | bitWrite(buttonLSB, 5, classic.aButton); 37 | bitWrite(buttonLSB, 6, classic.bButton); 38 | bitWrite(buttonLSB, 7, classic.yButton); 39 | 40 | byte buttonMSB = 0; 41 | bitWrite(buttonMSB, 0, classic.xButton); 42 | bitWrite(buttonMSB, 1, classic.dpadUp); 43 | bitWrite(buttonMSB, 2, classic.dpadDown); 44 | bitWrite(buttonMSB, 3, classic.dpadRight); 45 | bitWrite(buttonMSB, 4, classic.dpadLeft); 46 | bitWrite(buttonMSB, 5, classic.zLeftButton); 47 | bitWrite(buttonMSB, 6, classic.zRightButton); 48 | bitWrite(buttonMSB, 7, 0); 49 | 50 | DigiJoystick.setButtons(buttonLSB,buttonMSB); 51 | DigiJoystick.delay(10); 52 | } 53 | -------------------------------------------------------------------------------- /digistump-avr/libraries/ArduinoWiiClassicController/keywords.txt: -------------------------------------------------------------------------------- 1 | ArduinoNunchuk KEYWORD1 2 | init KEYWORD2 3 | update KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/DigiCDC.h: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | CDC Arduino Library by Ihsan Kehribar (kehribar.me) 4 | and Digistump LLC (digistump.com) 5 | - all changes made under the same license as V-USB 6 | 7 | 8 | */ 9 | #ifndef __DigiCDC_h__ 10 | #define __DigiCDC_h__ 11 | #include "usbdrv.h" 12 | 13 | 14 | 15 | #include "Stream.h" 16 | #include "ringBuffer.h" 17 | 18 | 19 | #define HW_CDC_TX_BUF_SIZE 32 20 | #define HW_CDC_RX_BUF_SIZE 32 21 | #define HW_CDC_BULK_OUT_SIZE 8 22 | #define HW_CDC_BULK_IN_SIZE 8 23 | 24 | 25 | 26 | /* library functions and variables start */ 27 | static uint8_t tmp[HW_CDC_BULK_IN_SIZE]; 28 | static uint8_t index = 0; 29 | 30 | static RingBuffer_t rxBuf; 31 | static uint8_t rxBuf_Data[HW_CDC_RX_BUF_SIZE]; 32 | 33 | static RingBuffer_t txBuf; 34 | static uint8_t txBuf_Data[HW_CDC_TX_BUF_SIZE]; 35 | 36 | 37 | class DigiCDCDevice : public Stream { 38 | public: 39 | DigiCDCDevice(); 40 | void begin(), begin(unsigned long x); 41 | void end(); 42 | void refresh(); 43 | void task(); 44 | void delay(long milli); 45 | void setDtrPin(uint8_t dtrPin); 46 | virtual int available(void); 47 | virtual int peek(void); 48 | virtual int read(void); 49 | virtual void flush(void); 50 | virtual size_t write(uint8_t); 51 | using Print::write; 52 | operator bool(); 53 | private: 54 | void usbBegin(); 55 | void usbPollWrapper(); 56 | }; 57 | 58 | 59 | extern DigiCDCDevice SerialUSB; 60 | 61 | 62 | #endif // __DigiCDC_h__ 63 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/examples/CDC_DTR_LED/CDC_DTR_LED.ino: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * Attention! 3 | * This example likely will not work with 4 | * windows versions > XP and current Linux kernels 5 | * see: http://digistump.com/board/index.php/topic,2720.msg13422.html#msg13422 6 | ******************************************************************************/ 7 | #include 8 | void setup() { 9 | SerialUSB.begin(); 10 | // initialize the digital pin 1 as an DTR output. 11 | SerialUSB.setDtrPin(1); 12 | } 13 | 14 | // the loop routine runs over and over again forever: 15 | void loop() { 16 | SerialUSB.delay(10); 17 | } 18 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/examples/CDC_LED/CDC_LED.ino: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * Attention! 3 | * This example likely will not work with 4 | * windows versions > XP and current Linux kernels 5 | * see: http://digistump.com/board/index.php/topic,2720.msg13422.html#msg13422 6 | ******************************************************************************/ 7 | #include 8 | void setup() { 9 | // initialize the digital pin as an output. 10 | SerialUSB.begin(); 11 | pinMode(1,OUTPUT); 12 | } 13 | 14 | // the loop routine runs over and over again forever: 15 | void loop() { 16 | 17 | //turns led on and off based on sending 0 or 1 from serial terminal 18 | if (SerialUSB.available()) { 19 | char input = SerialUSB.read(); 20 | if(input == '0') 21 | digitalWrite(1,LOW); 22 | else if(input == '1') 23 | digitalWrite(1,HIGH); 24 | 25 | } 26 | 27 | SerialUSB.delay(100); // keep usb alive // can alos use SerialUSB.refresh(); 28 | } 29 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/examples/Echo/Echo.ino: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * Attention! 3 | * This example likely will not work with 4 | * windows versions > XP and current Linux kernels 5 | * see: http://digistump.com/board/index.php/topic,2720.msg13422.html#msg13422 6 | ******************************************************************************/ 7 | #include 8 | void setup() { 9 | // initialize the digital pin as an output. 10 | SerialUSB.begin(); 11 | } 12 | 13 | // the loop routine runs over and over again forever: 14 | void loop() { 15 | 16 | if (SerialUSB.available()) { 17 | SerialUSB.write(SerialUSB.read()); 18 | } 19 | 20 | //SerialUSB.delay(10); 21 | /* 22 | if you don't call a SerialUSB function (write, print, read, available, etc) 23 | every 10ms or less then you must throw in some SerialUSB.refresh(); 24 | for the USB to keep alive - also replace your delays - ie. delay(100); 25 | with SerialUSB.delays ie. SerialUSB.delay(100); 26 | */ 27 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/examples/Print/Print.ino: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * Attention! 3 | * This example likely will not work with 4 | * windows versions > XP and current Linux kernels 5 | * see: http://digistump.com/board/index.php/topic,2720.msg13422.html#msg13422 6 | ******************************************************************************/ 7 | #include 8 | void setup() { 9 | // initialize the digital pin as an output. 10 | SerialUSB.begin(); 11 | /* 12 | remember the SerialUSB starts as soon as you call begin 13 | and doesn't restart the board when you open the serial monitor 14 | (like the uno does) - so if you print to it and you don't 15 | have a serial monitor open that text is lost. 16 | */ 17 | } 18 | 19 | // the loop routine runs over and over again forever: 20 | void loop() { 21 | 22 | SerialUSB.println(F("TEST!")); //wrap your strings in F() to save ram! 23 | 24 | //SerialUSB.delay(10); 25 | /* 26 | if you don't call a SerialUSB function (write, print, read, available, etc) 27 | every 10ms or less then you must throw in some SerialUSB.refresh(); 28 | for the USB to keep alive - also replace your delays - ie. delay(100); 29 | with SerialUSB.delays ie. SerialUSB.delay(100); 30 | */ 31 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/libs-device/Readme.txt: -------------------------------------------------------------------------------- 1 | This is the Readme file for the libs-device directory. This directory contains 2 | code snippets which may be useful for USB device firmware. 3 | 4 | 5 | WHAT IS INCLUDED IN THIS DIRECTORY? 6 | =================================== 7 | 8 | osccal.c and osccal.h 9 | This module contains a function which calibrates the AVR's built-in RC 10 | oscillator based on the USB frame clock. See osccal.h for a documentation 11 | of the API. 12 | 13 | osctune.h 14 | This header file contains a code snippet for usbconfig.h. With this code, 15 | you can keep the AVR's internal RC oscillator in sync with the USB frame 16 | clock. This is a continuous synchronization, not a single calibration at 17 | USB reset as with osccal.c above. Please note that this code works only 18 | if D- is wired to the interrupt, not D+. 19 | 20 | ---------------------------------------------------------------------------- 21 | (c) 2008 by OBJECTIVE DEVELOPMENT Software GmbH. 22 | http://www.obdev.at/ 23 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/oddebug.c: -------------------------------------------------------------------------------- 1 | /* Name: oddebug.c 2 | * Project: AVR library 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2005-01-16 5 | * Tabsize: 4 6 | * Copyright: (c) 2005 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id: oddebug.c 692 2008-11-07 15:07:40Z cs $ 9 | */ 10 | 11 | #include "oddebug.h" 12 | 13 | #if DEBUG_LEVEL > 0 14 | 15 | #warning "Never compile production devices with debugging enabled" 16 | 17 | static void uartPutc(char c) 18 | { 19 | while(!(ODDBG_USR & (1 << ODDBG_UDRE))); /* wait for data register empty */ 20 | ODDBG_UDR = c; 21 | } 22 | 23 | static uchar hexAscii(uchar h) 24 | { 25 | h &= 0xf; 26 | if(h >= 10) 27 | h += 'a' - (uchar)10 - '0'; 28 | h += '0'; 29 | return h; 30 | } 31 | 32 | static void printHex(uchar c) 33 | { 34 | uartPutc(hexAscii(c >> 4)); 35 | uartPutc(hexAscii(c)); 36 | } 37 | 38 | void odDebug(uchar prefix, uchar *data, uchar len) 39 | { 40 | printHex(prefix); 41 | uartPutc(':'); 42 | while(len--){ 43 | uartPutc(' '); 44 | printHex(*data++); 45 | } 46 | uartPutc('\r'); 47 | uartPutc('\n'); 48 | } 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkCDC/usbdrvasm.asm: -------------------------------------------------------------------------------- 1 | /* Name: usbdrvasm.asm 2 | * Project: V-USB, virtual USB port for Atmel's(r) AVR(r) microcontrollers 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2006-03-01 5 | * Tabsize: 4 6 | * Copyright: (c) 2006 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id$ 9 | */ 10 | 11 | /* 12 | General Description: 13 | The IAR compiler/assembler system prefers assembler files with file extension 14 | ".asm". We simply provide this file as an alias for usbdrvasm.S. 15 | 16 | Thanks to Oleg Semyonov for his help with the IAR tools port! 17 | */ 18 | 19 | #include "usbdrvasm.S" 20 | 21 | end 22 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/ArduinoNotes.txt: -------------------------------------------------------------------------------- 1 | Notes On Integrating AVRUSB with Arduino 2 | ======================================== 3 | 4 | * Note the license(s) under which AVRUSB is distributed. 5 | 6 | * See also: http://code.rancidbacon.com/ProjectLogArduinoUSB 7 | 8 | * Note: The pins we use on the PCB (not protoboard) hardware shield are: 9 | 10 | INT0 == PD2 == IC Pin 4 == Arduino Digital Pin 2 == D+ 11 | 12 | ---- == PD4 == -------- == Arduino Digital Pin 4 == D- 13 | 14 | ---- == PD5 == -------- == Arduino Digital Pin 5 == pull-up 15 | 16 | (DONE: Change to not use PD3 so INT1 is left free?) 17 | 18 | * In order to compile a valid 'usbconfig.h' file must exit. The content of this 19 | file will vary depending on whether the device is a generic USB device, 20 | generic HID device or specific class of HID device for example. 21 | 22 | The file 'usbconfig-prototype.h' can be used as a starting point, however 23 | it might be easier to use the 'usbconfig.h' from one of the example projects. 24 | 25 | TODO: Specify the settings that need to be changed to match the shield 26 | design we use. 27 | 28 | * (NOTE: Initial 'usbconfig.h' used will be based on the file from 29 | 'HIDKeys.2007-03-29'.) (Note: Have now upgraded to V-USB 2009-08-22.) 30 | 31 | * Versions of the Arduino IDE prior to 0018 won't compile our library 32 | so it needs to be pre-compiled with: 33 | 34 | avr-g++ -Wall -Os -I. -DF_CPU=16000000 -mmcu=atmega168 -c usbdrvasm.S -c usbdrv.c 35 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/DigiJoystick.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkJoystick/DigiJoystick.h -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/JoystickReadme.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkJoystick/JoystickReadme.txt -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/examples/Joystick/Joystick.ino: -------------------------------------------------------------------------------- 1 | //DigiJoystick test and usage documentation 2 | 3 | #include "DigiJoystick.h" 4 | 5 | void setup() { 6 | // Do nothing? It seems as if the USB hardware is ready to go on reset 7 | } 8 | 9 | 10 | void loop() { 11 | // If not using plentiful DigiJoystick.delay() calls, make sure to 12 | //DigiJoystick.update(); // call this at least every 50ms 13 | // calling more often than that is fine 14 | // this will actually only send the data every once in a while unless the data is different 15 | 16 | // you can set the values from a raw byte array with: 17 | // char myBuf[8] = { 18 | // x, y, xrot, yrot, zrot, slider, 19 | // buttonLowByte, buttonHighByte 20 | // }; 21 | // DigiJoystick.setValues(myBuf); 22 | 23 | // Or we can also set values like this: 24 | DigiJoystick.setX((byte) (millis() / 100)); // scroll X left to right repeatedly 25 | DigiJoystick.setY((byte) 0x30); 26 | DigiJoystick.setXROT((byte) 0x60); 27 | DigiJoystick.setYROT((byte) 0x90); 28 | DigiJoystick.setZROT((byte) 0xB0); 29 | DigiJoystick.setSLIDER((byte) 0xF0); 30 | 31 | // it's best to use DigiJoystick.delay() because it knows how to talk to 32 | // the connected computer - otherwise the USB link can crash with the 33 | // regular arduino delay() function 34 | DigiJoystick.delay(50); // wait 50 milliseconds 35 | 36 | // we can also set buttons like this (lowByte, highByte) 37 | //DigiJoystick.setButtons(0x00, 0x00); 38 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/keywords.txt: -------------------------------------------------------------------------------- 1 | DigiKeyboard KEYWORD1 2 | update KEYWORD2 3 | sendKeyStroke KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/oddebug.c: -------------------------------------------------------------------------------- 1 | /* Name: oddebug.c 2 | * Project: AVR library 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2005-01-16 5 | * Tabsize: 4 6 | * Copyright: (c) 2005 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id: oddebug.c 692 2008-11-07 15:07:40Z cs $ 9 | */ 10 | 11 | #include "oddebug.h" 12 | 13 | #if DEBUG_LEVEL > 0 14 | 15 | #warning "Never compile production devices with debugging enabled" 16 | 17 | static void uartPutc(char c) 18 | { 19 | while(!(ODDBG_USR & (1 << ODDBG_UDRE))); /* wait for data register empty */ 20 | ODDBG_UDR = c; 21 | } 22 | 23 | static uchar hexAscii(uchar h) 24 | { 25 | h &= 0xf; 26 | if(h >= 10) 27 | h += 'a' - (uchar)10 - '0'; 28 | h += '0'; 29 | return h; 30 | } 31 | 32 | static void printHex(uchar c) 33 | { 34 | uartPutc(hexAscii(c >> 4)); 35 | uartPutc(hexAscii(c)); 36 | } 37 | 38 | void odDebug(uchar prefix, uchar *data, uchar len) 39 | { 40 | printHex(prefix); 41 | uartPutc(':'); 42 | while(len--){ 43 | uartPutc(' '); 44 | printHex(*data++); 45 | } 46 | uartPutc('\r'); 47 | uartPutc('\n'); 48 | } 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkJoystick/usbdrvasm.asm: -------------------------------------------------------------------------------- 1 | /* Name: usbdrvasm.asm 2 | * Project: V-USB, virtual USB port for Atmel's(r) AVR(r) microcontrollers 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2006-03-01 5 | * Tabsize: 4 6 | * Copyright: (c) 2006 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id$ 9 | */ 10 | 11 | /* 12 | General Description: 13 | The IAR compiler/assembler system prefers assembler files with file extension 14 | ".asm". We simply provide this file as an alias for usbdrvasm.S. 15 | 16 | Thanks to Oleg Semyonov for his help with the IAR tools port! 17 | */ 18 | 19 | #include "usbdrvasm.S" 20 | 21 | end 22 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkKeyboard/ArduinoNotes.txt: -------------------------------------------------------------------------------- 1 | Notes On Integrating AVRUSB with Arduino 2 | ======================================== 3 | 4 | * Note the license(s) under which AVRUSB is distributed. 5 | 6 | * See also: http://code.rancidbacon.com/ProjectLogArduinoUSB 7 | 8 | * Note: The pins we use on the PCB (not protoboard) hardware shield are: 9 | 10 | INT0 == PD2 == IC Pin 4 == Arduino Digital Pin 2 == D+ 11 | 12 | ---- == PD4 == -------- == Arduino Digital Pin 4 == D- 13 | 14 | ---- == PD5 == -------- == Arduino Digital Pin 5 == pull-up 15 | 16 | (DONE: Change to not use PD3 so INT1 is left free?) 17 | 18 | * In order to compile a valid 'usbconfig.h' file must exit. The content of this 19 | file will vary depending on whether the device is a generic USB device, 20 | generic HID device or specific class of HID device for example. 21 | 22 | The file 'usbconfig-prototype.h' can be used as a starting point, however 23 | it might be easier to use the 'usbconfig.h' from one of the example projects. 24 | 25 | TODO: Specify the settings that need to be changed to match the shield 26 | design we use. 27 | 28 | * (NOTE: Initial 'usbconfig.h' used will be based on the file from 29 | 'HIDKeys.2007-03-29'.) (Note: Have now upgraded to V-USB 2009-08-22.) 30 | 31 | * Versions of the Arduino IDE prior to 0018 won't compile our library 32 | so it needs to be pre-compiled with: 33 | 34 | avr-g++ -Wall -Os -I. -DF_CPU=16000000 -mmcu=atmega168 -c usbdrvasm.S -c usbdrv.c 35 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkKeyboard/examples/Keyboard/Keyboard.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * Comment out the line for your layout 3 | */ 4 | 5 | //#define LAYOUT_US_ENGLISH // Is default 6 | //#define LAYOUT_CANADIAN_FRENCH 7 | //#define LAYOUT_CANADIAN_MULTILINGUAL 8 | //#define LAYOUT_DANISH 9 | //#define LAYOUT_FINNISH 10 | //#define LAYOUT_FRENCH 11 | //#define LAYOUT_FRENCH_BELGIAN 12 | //#define LAYOUT_FRENCH_SWISS 13 | //#define LAYOUT_GERMAN 14 | //#define LAYOUT_GERMAN_MAC 15 | //#define LAYOUT_GERMAN_SWISS 16 | //#define LAYOUT_ICELANDIC 17 | //#define LAYOUT_IRISH 18 | //#define LAYOUT_ITALIAN 19 | //#define LAYOUT_NORWEGIAN 20 | //#define LAYOUT_PORTUGUESE 21 | //#define LAYOUT_PORTUGUESE_BRAZILIAN 22 | //#define LAYOUT_SPANISH 23 | //#define LAYOUT_SPANISH_LATIN_AMERICA 24 | //#define LAYOUT_SWEDISH 25 | //#define LAYOUT_TURKISH 26 | //#define LAYOUT_UNITED_KINGDOM 27 | //#define LAYOUT_US_INTERNATIONAL 28 | #include "DigiKeyboard.h" 29 | 30 | void setup() { 31 | DigiKeyboard.enableLEDFeedback(); 32 | } 33 | 34 | // The loop function is called in an endless loop 35 | void loop() { 36 | 37 | // It's better to use DigiKeyboard.delay() over the regular Arduino delay() 38 | // if doing keyboard stuff because it keeps talking to the computer to make 39 | // sure the computer knows the keyboard is alive and connected 40 | DigiKeyboard.delay(5000); 41 | 42 | // this is generally not necessary but with some older systems it seems to 43 | // prevent missing the first character after a delay: 44 | // DigiKeyboard.sendKeyDEStroke(0); 45 | 46 | DigiKeyboard.print("Hello Digispark!"); 47 | DigiKeyboard.write('\n'); 48 | // DigiKeyboard.println(F("abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ 1234567890 !\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~")); 49 | DigiKeyboard.println(TEST_STRING); 50 | 51 | // Send all ASCII codes in a loop 52 | // for (uint8_t tSendChar = 0x20; tSendChar < 0x7F; ++tSendChar) { 53 | // DigiKeyboard.write(tSendChar); 54 | // DigiKeyboard.delay(50); 55 | // } 56 | // DigiKeyboard.write('\n'); 57 | } 58 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkKeyboard/keywords.txt: -------------------------------------------------------------------------------- 1 | DigiKeyboard KEYWORD1 2 | update KEYWORD2 3 | sendKeyStroke KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkKeyboard/oddebug.c: -------------------------------------------------------------------------------- 1 | /* Name: oddebug.c 2 | * Project: AVR library 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2005-01-16 5 | * Tabsize: 4 6 | * Copyright: (c) 2005 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id: oddebug.c 692 2008-11-07 15:07:40Z cs $ 9 | */ 10 | 11 | #include "oddebug.h" 12 | 13 | #if DEBUG_LEVEL > 0 14 | 15 | #warning "Never compile production devices with debugging enabled" 16 | 17 | static void uartPutc(char c) 18 | { 19 | while(!(ODDBG_USR & (1 << ODDBG_UDRE))); /* wait for data register empty */ 20 | ODDBG_UDR = c; 21 | } 22 | 23 | static uchar hexAscii(uchar h) 24 | { 25 | h &= 0xf; 26 | if(h >= 10) 27 | h += 'a' - (uchar)10 - '0'; 28 | h += '0'; 29 | return h; 30 | } 31 | 32 | static void printHex(uchar c) 33 | { 34 | uartPutc(hexAscii(c >> 4)); 35 | uartPutc(hexAscii(c)); 36 | } 37 | 38 | void odDebug(uchar prefix, uchar *data, uchar len) 39 | { 40 | printHex(prefix); 41 | uartPutc(':'); 42 | while(len--){ 43 | uartPutc(' '); 44 | printHex(*data++); 45 | } 46 | uartPutc('\r'); 47 | uartPutc('\n'); 48 | } 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkKeyboard/usbdrvasm.asm: -------------------------------------------------------------------------------- 1 | /* Name: usbdrvasm.asm 2 | * Project: V-USB, virtual USB port for Atmel's(r) AVR(r) microcontrollers 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2006-03-01 5 | * Tabsize: 4 6 | * Copyright: (c) 2006 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id$ 9 | */ 10 | 11 | /* 12 | General Description: 13 | The IAR compiler/assembler system prefers assembler files with file extension 14 | ".asm". We simply provide this file as an alias for usbdrvasm.S. 15 | 16 | Thanks to Oleg Semyonov for his help with the IAR tools port! 17 | */ 18 | 19 | #include "usbdrvasm.S" 20 | 21 | end 22 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/examples/BasicUsage/BasicUsage.ino: -------------------------------------------------------------------------------- 1 | /* ATtiny85 as an I2C Master Ex2 BroHogan 1/21/11 2 | * Modified for Digistump - Digispark LCD Shield by Erik Kettenburg 11/2012 3 | * SETUP: 4 | * ATtiny Pin 1 = (RESET) N/U ATtiny Pin 2 = (D3) N/U 5 | * ATtiny Pin 3 = (D4) to LED1 ATtiny Pin 4 = GND 6 | * ATtiny Pin 5 = SDA on DS1621 & GPIO ATtiny Pin 6 = (D1) to LED2 7 | * ATtiny Pin 7 = SCK on DS1621 & GPIO ATtiny Pin 8 = VCC (2.7-5.5V) 8 | * NOTE! - It's very important to use pullups on the SDA & SCL lines! 9 | * PCA8574A GPIO was used wired per instructions in "info" folder in the LiquidCrystal_I2C lib. 10 | * This ex assumes A0-A2 are set HIGH for an addeess of 0x3F 11 | * LiquidCrystal_I2C lib was modified for ATtiny - on Playground with Wire lib. 12 | * Wire USAGE & CREDITS: - see Wire.h 13 | */ 14 | 15 | //#define DEBUG 16 | #include // I2C Master lib for ATTinys which use USI - comment this out to use with standard arduinos 17 | #include // for LCD w/ GPIO MODIFIED for the ATtiny85 18 | 19 | #define GPIO_ADDR 0x27 // (PCA8574A A0-A2 @5V) typ. A0-A3 Gnd 0x20 / 0x38 for A - 0x27 is the address of the Digispark LCD modules. 20 | 21 | 22 | LiquidCrystal_I2C lcd(GPIO_ADDR,16,2); // set address & 16 chars / 2 lines 23 | 24 | 25 | void setup(){ 26 | Wire.begin(); // initialize I2C lib - comment this out to use with standard arduinos 27 | lcd.init(); // initialize the lcd 28 | lcd.backlight(); // Print a message to the LCD. 29 | lcd.print("Digispark!"); 30 | } 31 | 32 | 33 | void loop(){ 34 | 35 | } 36 | 37 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/info/BC557.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkLCD/info/BC557.pdf -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/info/Image.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkLCD/info/Image.jpg -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/info/PCF8574P.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkLCD/info/PCF8574P.pdf -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/info/Schematic_diagram.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkLCD/info/Schematic_diagram.jpg -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/info/notes_for_pollin_interface.txt: -------------------------------------------------------------------------------- 1 | Notes for users with a Pollin.de interface board 2 | http://www.pollin.de/shop/dt/NDU4OTgxOTk-/Bausaetze_Module/Bausaetze/LCD_I2C_Modul.html 3 | 4 | The pollin interface board will not work with de default library. 5 | To get it working two control lines to the LCD need to be changed. 6 | 7 | Open file "LiquidCrystal_I2C.h" with a text editor like Notepad (not WordPad !) 8 | 9 | In that file look for: 10 | #define En B00010000 // Enable bit 11 | #define Rw B00100000 // Read/Write bit 12 | #define Rs B01000000 // Register select bit 13 | 14 | Replace these lines by: 15 | #define En B01000000 // Enable bit 16 | #define Rw B00100000 // Read/Write bit 17 | #define Rs B00010000 // Register select bit 18 | 19 | 20 | 21 | People at Pollin also have misunderstood the PCF8574 Datasheet and list the wrong addresses on their PCB 22 | For PCF8574A the addressing is: 23 | 24 | Jp3 Jp2 Jp1 25 | A2 A1 A0 Dec Hex 26 | L L L 56 0x38 27 | L L H 57 0x39 28 | L H L 64 0x40 29 | L H H 74 0x4A 30 | H L L 75 0x4B 31 | H L H 76 0x4C 32 | H H L 77 0x4D 33 | H H H 78 0x4E 34 | 35 | They also seem to ship boards with a PCF8574 36 | For PCF8574 the addressing is: 37 | 38 | Jp3 Jp2 Jp1 39 | A2 A1 A0 Dec Hex 40 | L L L 32 0x20 41 | L L H 33 0x21 42 | L H L 34 0x22 43 | L H H 35 0x23 44 | H L L 36 0x24 45 | H L H 37 0x25 46 | H H L 38 0x26 47 | H H H 39 0x27 48 | 49 | 50 | They have also chosen two rather high pull-up resistors (10K) for the I2C lines. Usually two 4K7 resistors should do the job. 51 | Please note that on a I2C bus only one device should have the pull-up resistors installed! 52 | 53 | I hope this helps in getting your LCD working. 54 | 55 | Mario -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/info/readme.txt: -------------------------------------------------------------------------------- 1 | LiquidCrystal_I2C V2.0 2 | 3 | The LiquidCrystal_I2C library is a modified version of the standard LiquidCrystal library as found on 4 | the Arduino website. 5 | This library is intended to be used when a parallel HD44780 compatible LCD is controlled over I2C using 6 | a PCF8574 extender (see datasheet for details). 7 | 4 of the 8 outputs are used for LDC data lines 4 to 7. 8 | 3 outputs are used for the Enable, register-select and Read/Write lines. 9 | The one output left can be used to control the backlight of the LCD (if available). 10 | For backlight control some extra resistors and a pnp-type transistor are required (for details see 11 | schematic diagram). 12 | 13 | The PCF8574 extender is available in two versions, the PCF8574 and the PCF8574A. 14 | The only difference between the two is the I2C base address. 15 | The base address for the PCF8574 is 0x20 and the base address for the PCF8574A is 0x38. 16 | The examples included in this zip file assume the use of an PCF8574 set for address 0x20 17 | (A0, A1 and A3 grounded). 18 | 19 | For compatibility reasons this library contains some aliases for functions that are known under different 20 | names in other libraries. This should make it fairly easy to implement the library in existing sketches 21 | without changing to much code. 22 | Functions not supported by this library will return nothing at all and in case a return value is expected 23 | the function will return 0. 24 | 25 | Update 8-12-2011: 26 | Due to the relaese of Arduino IDE 1.0 some changes were made to the library to get it working under the new IDE. 27 | Because of these changes this version of the LiquidCrystal_I2C library can not be used for older IDE versions. 28 | The old version of the LiquidCrystal_I2Clibrary can be downloaded form http://www.xs4all.nl/~hmario/arduino/LiquidCrystal_I2C/V1.0/LiquidCrystal_I2C_V1.0.zip 29 | 30 | Download the latest version from: 31 | http://www.xs4all.nl/~hmario/arduino/LiquidCrystal_I2C/LiquidCrystal_I2C.zip 32 | (Thanks to Ailton F. for beta testing.) 33 | 34 | 35 | Mario H. 36 | atmega@xs4all.nl -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkLCD/keywords.txt: -------------------------------------------------------------------------------- 1 | ########################################### 2 | # Syntax Coloring Map For LiquidCrystal_I2C 3 | # Version 2.0 4 | ########################################### 5 | 6 | ########################################### 7 | # Datatypes (KEYWORD1) 8 | ########################################### 9 | 10 | LiquidCrystal_I2C KEYWORD1 11 | 12 | ########################################### 13 | # Methods and Functions (KEYWORD2) 14 | ########################################### 15 | init KEYWORD2 16 | begin KEYWORD2 17 | clear KEYWORD2 18 | home KEYWORD2 19 | noDisplay KEYWORD2 20 | display KEYWORD2 21 | noBlink KEYWORD2 22 | blink KEYWORD2 23 | noCursor KEYWORD2 24 | cursor KEYWORD2 25 | scrollDisplayLeft KEYWORD2 26 | scrollDisplayRight KEYWORD2 27 | leftToRight KEYWORD2 28 | rightToLeft KEYWORD2 29 | shiftIncrement KEYWORD2 30 | shiftDecrement KEYWORD2 31 | noBacklight KEYWORD2 32 | backlight KEYWORD2 33 | autoscroll KEYWORD2 34 | noAutoscroll KEYWORD2 35 | createChar KEYWORD2 36 | setCursor KEYWORD2 37 | print KEYWORD2 38 | blink_on KEYWORD2 39 | blink_off KEYWORD2 40 | cursor_on KEYWORD2 41 | cursor_off KEYWORD2 42 | setBacklight KEYWORD2 43 | load_custom_character KEYWORD2 44 | printstr KEYWORD2 45 | ########################################### 46 | # Constants (LITERAL1) 47 | ########################################### 48 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/ArduinoNotes.txt: -------------------------------------------------------------------------------- 1 | Notes On Integrating AVRUSB with Arduino 2 | ======================================== 3 | 4 | * Note the license(s) under which AVRUSB is distributed. 5 | 6 | * See also: http://code.rancidbacon.com/ProjectLogArduinoUSB 7 | 8 | * Note: The pins we use on the PCB (not protoboard) hardware shield are: 9 | 10 | INT0 == PD2 == IC Pin 4 == Arduino Digital Pin 2 == D+ 11 | 12 | ---- == PD4 == -------- == Arduino Digital Pin 4 == D- 13 | 14 | ---- == PD5 == -------- == Arduino Digital Pin 5 == pull-up 15 | 16 | (DONE: Change to not use PD3 so INT1 is left free?) 17 | 18 | * In order to compile a valid 'usbconfig.h' file must exit. The content of this 19 | file will vary depending on whether the device is a generic USB device, 20 | generic HID device or specific class of HID device for example. 21 | 22 | The file 'usbconfig-prototype.h' can be used as a starting point, however 23 | it might be easier to use the 'usbconfig.h' from one of the example projects. 24 | 25 | TODO: Specify the settings that need to be changed to match the shield 26 | design we use. 27 | 28 | * (NOTE: Initial 'usbconfig.h' used will be based on the file from 29 | 'HIDKeys.2007-03-29'.) (Note: Have now upgraded to V-USB 2009-08-22.) 30 | 31 | * Versions of the Arduino IDE prior to 0018 won't compile our library 32 | so it needs to be pre-compiled with: 33 | 34 | avr-g++ -Wall -Os -I. -DF_CPU=16000000 -mmcu=atmega168 -c usbdrvasm.S -c usbdrv.c 35 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/DigiMouse.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkMouse/DigiMouse.h -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/MouseReadme.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkMouse/MouseReadme.txt -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/examples/Mouse/Mouse.ino: -------------------------------------------------------------------------------- 1 | // DigiMouse test and usage documentation 2 | // CAUTION!!!! This does click things!!!!!!!! 3 | // Originally created by Sean Murphy (duckythescientist) 4 | 5 | #include 6 | 7 | void setup() { 8 | DigiMouse.begin(); //start or reenumerate USB - BREAKING CHANGE from old versions that didn't require this 9 | } 10 | 11 | void loop() { 12 | // If not using plentiful DigiMouse.delay(), make sure to call 13 | // DigiMouse.update() at least every 50ms 14 | 15 | // move across the screen 16 | // these are signed chars 17 | DigiMouse.moveY(10); //down 10 18 | DigiMouse.delay(500); 19 | DigiMouse.moveX(20); //right 20 20 | DigiMouse.delay(500); 21 | DigiMouse.scroll(5); 22 | DigiMouse.delay(500); 23 | 24 | // or DigiMouse.move(X, Y, scroll) works 25 | 26 | // three buttons are the three LSBs of an unsigned char 27 | DigiMouse.setButtons(1<<0); //left click 28 | DigiMouse.delay(500); 29 | DigiMouse.setButtons(0); //unclick all 30 | DigiMouse.delay(500); 31 | 32 | //or you can use these functions to click 33 | DigiMouse.rightClick(); 34 | DigiMouse.delay(500); 35 | DigiMouse.leftClick(); 36 | DigiMouse.delay(500); 37 | DigiMouse.middleClick(); 38 | DigiMouse.delay(500); 39 | 40 | //for compatability with other libraries you can also use DigiMouse.move(X, Y, scroll, buttons) 41 | } 42 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/keywords.txt: -------------------------------------------------------------------------------- 1 | DigiMouse KEYWORD1 2 | update KEYWORD2 3 | moveX KEYWORD2 4 | moveY KEYWORD2 5 | scroll KEYWORD2 6 | move KEYWORD2 7 | setButtons KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/oddebug.c: -------------------------------------------------------------------------------- 1 | /* Name: oddebug.c 2 | * Project: AVR library 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2005-01-16 5 | * Tabsize: 4 6 | * Copyright: (c) 2005 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id: oddebug.c 692 2008-11-07 15:07:40Z cs $ 9 | */ 10 | 11 | #include "oddebug.h" 12 | 13 | #if DEBUG_LEVEL > 0 14 | 15 | #warning "Never compile production devices with debugging enabled" 16 | 17 | static void uartPutc(char c) 18 | { 19 | while(!(ODDBG_USR & (1 << ODDBG_UDRE))); /* wait for data register empty */ 20 | ODDBG_UDR = c; 21 | } 22 | 23 | static uchar hexAscii(uchar h) 24 | { 25 | h &= 0xf; 26 | if(h >= 10) 27 | h += 'a' - (uchar)10 - '0'; 28 | h += '0'; 29 | return h; 30 | } 31 | 32 | static void printHex(uchar c) 33 | { 34 | uartPutc(hexAscii(c >> 4)); 35 | uartPutc(hexAscii(c)); 36 | } 37 | 38 | void odDebug(uchar prefix, uchar *data, uchar len) 39 | { 40 | printHex(prefix); 41 | uartPutc(':'); 42 | while(len--){ 43 | uartPutc(' '); 44 | printHex(*data++); 45 | } 46 | uartPutc('\r'); 47 | uartPutc('\n'); 48 | } 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkMouse/usbdrvasm.asm: -------------------------------------------------------------------------------- 1 | /* Name: usbdrvasm.asm 2 | * Project: V-USB, virtual USB port for Atmel's(r) AVR(r) microcontrollers 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2006-03-01 5 | * Tabsize: 4 6 | * Copyright: (c) 2006 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id$ 9 | */ 10 | 11 | /* 12 | General Description: 13 | The IAR compiler/assembler system prefers assembler files with file extension 14 | ".asm". We simply provide this file as an alias for usbdrvasm.S. 15 | 16 | Thanks to Oleg Semyonov for his help with the IAR tools port! 17 | */ 18 | 19 | #include "usbdrvasm.S" 20 | 21 | end 22 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkOLED/CHANGES.txt: -------------------------------------------------------------------------------- 1 | CHANGES 2 | 3 | 4 | 2015-01-10 (nb) 5 | 6 | Fixed and improved initialization. New and improved printing of text. Updated texts. 7 | 8 | - Fixed initialization commands. 9 | - Implemented ssd1306_init more efficiently. 10 | - New functions ssd1306_send_command_start, ssd1306_send_command_stop. 11 | - Improved ssd1306_setpos, more efficient. 12 | - Reimplemented function ssd1306_char_f6x8 as improved ssd1306_char_font6x8 printing single characters only, added new ssd1306_string_font6x8 for printing strings. 13 | - The font8x16 functions and data moved to another file until properly implemented. 14 | - Added to the Make file ssd1306xled8x16 file. 15 | - Updated testing text displayed on the screen. 16 | 17 | 18 | 2015-01-10 (nb) 19 | 20 | Changed default pins for display, now PB0=SCL and PB1=SDA. Source code reformatting, improvements, edited comments. 21 | 22 | - Changed default pins for connecting to the display for consistency with the built-in TWI interface, they are now PB0=SCL and PB1=SDA. 23 | - Source code, removed redundant initializations of variables. 24 | - Source code reformatting, edited comments. 25 | 26 | 27 | 2015-01-10 (nb) 28 | 29 | Fixed some warnings, variables renamed. The font16x16/Chinese stuff moved to other folders. 30 | 31 | - Font variable ssd1306xled_font8X16 renamed to ssd1306xled_font8x16 for consistency. TODO: rename "ssd1306xled_font8x16" file as well. 32 | - Fixed ssd1306_draw_bmp prototype: added "const" to bitmap so it wont't generate warning. 33 | - Files related to font 16x16 (Chinese) moved to different folders: font16x16cn.h. 34 | - Functions and other code related to font 16x16 (Chinese) moved to different folders. 35 | - Source code reformatting, edited comments. 36 | 37 | 38 | 2014-10-26 (gs) 39 | 40 | Make project compile on gcc-avr - turn static images to consts, and rename include of font16x16cn.h 41 | 42 | 43 | 2014-08-13 (nb) 44 | 45 | More files added to the repository. 46 | 47 | 48 | 2014-08-11 (nb) 49 | 50 | Files added to the repository. 51 | 52 | 53 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkOLED/DigisparkOLED.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SSD1306xLED - Drivers for SSD1306 controlled dot matrix OLED/PLED 128x64 displays 3 | * 4 | * @created: 2014-08-12 5 | * @author: Neven Boyanov 6 | * 7 | * Source code available at: https://bitbucket.org/tinusaur/ssd1306xled 8 | * 9 | */ 10 | #include 11 | #include 12 | #include 13 | // #include 14 | // #include 15 | #include 16 | 17 | #ifndef DIGISPARKOLED_H 18 | #define DIGISPARKOLED_H 19 | 20 | // #define _nofont_8x16 //tBUG 21 | #ifndef _nofont_8x16 //tBUG 22 | #define FONT8X16 1 23 | #endif 24 | #define FONT6X8 0 25 | 26 | // ---------------------------------------------------------------------------- 27 | 28 | #ifndef SSD1306 29 | #define SSD1306 0x3C // Slave address 30 | #endif 31 | 32 | // ---------------------------------------------------------------------------- 33 | 34 | class SSD1306Device: public Print { 35 | 36 | public: 37 | SSD1306Device(void); 38 | void begin(void); 39 | void setFont(uint8_t font); 40 | void ssd1306_send_command(uint8_t command); 41 | void ssd1306_send_data_byte(uint8_t byte); 42 | void ssd1306_send_data_start(void); 43 | void ssd1306_send_data_stop(void); 44 | void setCursor(uint8_t x, uint8_t y); 45 | void fill(uint8_t fill); 46 | void clear(void); 47 | void bitmap(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1, const uint8_t bitmap[]); 48 | void ssd1306_send_command_start(void); 49 | void ssd1306_send_command_stop(void); 50 | void ssd1306_char_f8x16(uint8_t x, uint8_t y, const char ch[]); 51 | virtual size_t write(byte c); 52 | using Print::write; 53 | 54 | 55 | }; 56 | 57 | 58 | extern SSD1306Device oled; 59 | 60 | // ---------------------------------------------------------------------------- 61 | 62 | #endif 63 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkOLED/README.txt: -------------------------------------------------------------------------------- 1 | Overhauled to support Wire library, print library, and generally be more "Arduino friendly" - renamed DigiOLED to avoid confussion - 1/14/2015 by Erik Kettenburg/Digistump 2 | 3 | Ported to Arduino CPP and working on DigiStump Pro 1/11/15 by defragster 4 | 5 | SSD1306xLED - Drivers for SSD1306 controlled dot matrix OLED/PLED 128x64 displays 6 | 7 | SSD1306xLED is a C library for working with the SSD1306 display driver to control dot matrix OLED/PLED 128x64 displays. It is intended to be used with the Tinusaur board but should also work with any other board based on ATtiny85 or similar microcontroller. 8 | 9 | SSD1306xLED is written in plain C and does not require any additional libraries to function except those that come with the WinAVR SDK. 10 | 11 | 12 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkOLED/RESEARCH.txt: -------------------------------------------------------------------------------- 1 | RESEARCH 2 | 3 | 4 | SSD1306 5 | http://www.solomon-systech.com/en/product/display-ic/oled-driver-controller/ssd1306/ 6 | SSD1306 is a single-chip CMOS OLED/PLED driver with controller for organic / polymer light emitting diode dot-matrix graphic display system. It consists of 128 segments and 64 commons. This IC is designed for Common Cathode type OLED panel. 7 | 8 | 9 | ---- SSD1306 Datasheets ---- 10 | 11 | https://www.adafruit.com/datasheets/SSD1306.pdf 12 | 13 | http://www.crystalfontz.com/controllers/Solomon_Systech_SSD1306_v1.1_April_2008.pdf 14 | 15 | 16 | ---- Other SSD1306 Libraries ---- 17 | 18 | 19 | 20 | ---- Projects ---- 21 | 22 | 23 | 24 | ---- Other References ---- 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkOLED/TODO.txt: -------------------------------------------------------------------------------- 1 | TODO 2 | 3 | 4 | - Implement power saving mode 5 | 6 | 7 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkOLED/examples/DigisparkOLED/DigisparkOLED.ino: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | // ============================================================================ 4 | 5 | #include "img0_128x64c1.h" 6 | #include "digistump_128x64c1.h" 7 | 8 | 9 | void setup() { 10 | // put your setup code here, to run once: 11 | 12 | oled.begin(); 13 | 14 | } 15 | 16 | void loop() { 17 | 18 | // put your main code here, to run repeatedly: 19 | oled.fill(0xFF); //fill screen with color 20 | delay(1000); 21 | oled.clear(); //all black 22 | delay(1000); 23 | //usage: oled.setCursor(X IN PIXELS, Y IN ROWS OF 8 PIXELS STARTING WITH 0); 24 | oled.setCursor(0, 0); //top left 25 | oled.setFont(FONT8X16); 26 | oled.print(F("DIGISTUMP")); //wrap strings in F() to save RAM! 27 | oled.setFont(FONT6X8); 28 | oled.print(F(" OLED!")); 29 | oled.setCursor(0, 2); //two rows down because the 8x16 font takes two rows of 8 30 | oled.println(F("test")); //println will move the cursor 8 or 16 pixels down (based on the front) and back to X=0 31 | oled.print(F("test test test test test")); //lines auto wrap 32 | 33 | delay(3000); 34 | //usage oled.bitmap(START X IN PIXELS, START Y IN ROWS OF 8 PIXELS, END X IN PIXELS, END Y IN ROWS OF 8 PIXELS, IMAGE ARRAY); 35 | oled.bitmap(0, 0, 128, 8, img0_128x64c1); 36 | delay(3000); 37 | oled.bitmap(0, 0, 128, 8, digistumplogo); 38 | delay(3000); 39 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkRGB/DigisparkRGB.h: -------------------------------------------------------------------------------- 1 | /* 2 | DigisparkPWM.h - Library for pwm on PB2 on ATTINY85. 3 | Created by Digistump 4 | Released into the public domain. 5 | */ 6 | #ifndef DigisparkRGB_h 7 | #define DigisparkRGB_h 8 | 9 | 10 | void DigisparkRGBBegin(); 11 | void DigisparkRGBDelay(int ms); 12 | void DigisparkRGB(int pin,int value); 13 | 14 | #endif -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkRGB/examples/DigisparkRGB/DigisparkRGB.ino: -------------------------------------------------------------------------------- 1 | #include 2 | /* 3 | Digispark RGB 4 | 5 | This example shows how to use soft PWM to fade 3 colors. 6 | Note: This is only necessary for PB2 (pin 2) - Blue, as Red (pin 0) and Green (pin 1) as well as pin 4 support the standard Arduino analogWrite() function. 7 | 8 | This example code is in the public domain. 9 | */ 10 | byte RED = 0; 11 | byte BLUE = 2; 12 | byte GREEN = 1; 13 | byte COLORS[] = {RED, BLUE, GREEN}; 14 | 15 | // the setup routine runs once when you press reset: 16 | void setup() { 17 | DigisparkRGBBegin(); 18 | } 19 | 20 | 21 | void loop() { 22 | //direction: up = true, down = false 23 | boolean dir = true; 24 | int i = 0; 25 | 26 | while(1) { 27 | fade(COLORS[i%3], dir); 28 | i++; 29 | dir = !dir; 30 | } 31 | } 32 | 33 | void fade(byte Led, boolean dir) { 34 | int i; 35 | 36 | //if fading up 37 | if (dir) { 38 | for (i = 0; i < 256; i++) { 39 | DigisparkRGB(Led, i); 40 | DigisparkRGBDelay(25);//1); 41 | } 42 | } else { 43 | for (i = 255; i >= 0; i--) { 44 | DigisparkRGB(Led, i); 45 | DigisparkRGBDelay(25);//1); 46 | } 47 | } 48 | } 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkRGB/keywords.txt: -------------------------------------------------------------------------------- 1 | DigisparkRGBBegin KEYWORD2 2 | DigisparkRGB KEYWORD2 3 | DigisparkRGBDelay KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkRcSeq/keywords.txt: -------------------------------------------------------------------------------- 1 | ############################################ 2 | # Syntax Coloring Map RcSeq 3 | ############################################ 4 | 5 | ############################################ 6 | # Datatypes (KEYWORD1) 7 | ############################################ 8 | RcSeq KEYWORD1 9 | 10 | ############################################ 11 | # Methods and Functions (KEYWORD2) 12 | ############################################ 13 | RcSeq_LibVersion KEYWORD2 14 | RcSeq_LibRevision KEYWORD2 15 | RcSeq_LibTextVersionRevision KEYWORD2 16 | RcSeq_Init KEYWORD2 17 | RcSeq_DeclareSignal KEYWORD2 18 | RcSeq_SignalTimeout KEYWORD2 19 | RcSeq_DeclareKeyboard KEYWORD2 20 | RcSeq_DeclareClavier KEYWORD2 21 | RcSeq_DeclareStick KEYWORD2 22 | RcSeq_DeclareManche KEYWORD2 23 | RcSeq_DeclareServo KEYWORD2 24 | RcSeq_ServoWrite KEYWORD2 25 | RcSeq_DeclareCustomKeyboard KEYWORD2 26 | RcSeq_DeclareClavierMaison KEYWORD2 27 | RcSeq_DeclareMultiPosSwitch KEYWORD2 28 | RcSeq_DeclareInterMultiPos KEYWORD2 29 | RcSeq_DeclareCommandAndSequence KEYWORD2 30 | RcSeq_DeclareCommandeEtSequence KEYWORD2 31 | RcSeq_DeclareCommandAndShortAction KEYWORD2 32 | RcSeq_DeclareCommandeEtActionCourte KEYWORD2 33 | RcSeq_LaunchSequence KEYWORD2 34 | RcSeq_LanceSequence KEYWORD2 35 | RcSeq_LaunchShortAction KEYWORD2 36 | RcSeq_LanceActionCourte KEYWORD2 37 | RcSeq_Refresh KEYWORD2 38 | RcSeq_Rafraichit KEYWORD2 39 | 40 | ############################################ 41 | # Constants (LITERAL1) 42 | ############################################ 43 | SequenceSt_t LITERAL1 44 | KeyMap_t LITERAL1 45 | SHORT_ACTION_TO_PERFORM LITERAL1 46 | ACTION_COURTE_A_EFFECTUER LITERAL1 47 | MOTION_WITH_SOFT_START_AND_STOP LITERAL1 48 | MOTION_WITHOUT_SOFT_START_AND_STOP LITERAL1 49 | MVT_AVEC_DEBUT_ET_FIN_MVT_LENTS LITERAL1 50 | MVT_SANS_DEBUT_ET_FIN_MVT_LENTS LITERAL1 51 | RC_CUSTOM_KEYBOARD LITERAL1 52 | RC_CLAVIER_MAISON LITERAL1 53 | RC_SEQUENCE LITERAL1 54 | CENTER_VALUE_US LITERAL1 55 | VALEUR_CENTRALE_US LITERAL1 56 | RC_SEQ_START_CONDITION LITERAL1 57 | RC_SEQ_CONDITION_DE_DEPART LITERAL1 58 | RC_SEQ_END_OF_SEQ LITERAL1 59 | RC_SEQ_FIN_DE_SEQ LITERAL1 60 | 61 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSimpleServo/README.txt: -------------------------------------------------------------------------------- 1 | ================== 2 | SimpleServo - v0.8 3 | ================== 4 | 5 | "Shh, ya hear that? Me neither… It's simple… Maybe *too* simple…" 6 | 7 | This is a simplistic library to bundle up and generalize bit-banging servo PWM. It has some good points and trade-offs and is primarily being developed for the Digispark. 8 | 9 | First the good: 10 | - Can control any number of servos 11 | - All software, no fancy hardware required 12 | - Produces a relatively clean signal 13 | - Allows (or will) tuning pulse parameters to suit the widely varied tastes of different servos 14 | - A single instance can be used with multiple similar servos 15 | 16 | Now some limitations: 17 | - It can only control one servo at a time 18 | - The program can't do anything else while the servo is being signaled 19 | - Documentation is incomplete (at the moment) 20 | 21 | When typical servos stop receiving a control signal, they stay where they are; while they won't actively hold their position, most require some force to backdrive. So if that's enough for your project, you can move each servo in turn, and sample inputs, set LEDs and such in between. 22 | 23 | ======= 24 | Methods 25 | ======= 26 | 27 | See comments in SimpleServo.h (and SimpleServo.m) for now. 28 | 29 | *(( TODO: Document the additional methods in detail, add an example ))* 30 | 31 | ======= 32 | License 33 | ======= 34 | 35 | The MIT License (MIT) 36 | Copyright (c) 2013 Benjamin Holt 37 | 38 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 39 | 40 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 41 | 42 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 43 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSimpleServo/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map SimpleServo 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | SimpleServo KEYWORD1 10 | 11 | ####################################### 12 | # Methods and Functions (KEYWORD2) 13 | ####################################### 14 | 15 | attach KEYWORD2 16 | attached KEYWORD2 17 | detach KEYWORD2 18 | read KEYWORD2 19 | setMaximumPulse KEYWORD2 20 | setMinimumPulse KEYWORD2 21 | write KEYWORD2 22 | writeMillis KEYWORD2 23 | writeMicrosecondsMillis KEYWORD2 24 | 25 | ####################################### 26 | # Constants (LITERAL1) 27 | ####################################### 28 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseIn/Readme.md: -------------------------------------------------------------------------------- 1 | SoftRcPulseIn library 2 | ====================== 3 | 4 | **SoftRcPulseIn** is an asynchronous library designed to read RC pulse signals. It is a non-blocking version of arduino **pulseIn()** function. 5 | 6 | Some examples of use cases: 7 | ------------------------- 8 | * **RC Servo/ESC/Brushless Controller** 9 | * **Multi-switch (RC Channel to digital outputs converter)** (look at **RcSeq** library) 10 | * **Servo sequencer** (look at **RcSeq** library which uses **SoftRcPulseOut** library) 11 | * **RC Robot using wheels with modified Servo to support 360° rotation** 12 | * **RC pulse stretcher** (in conjunction with **SoftRcPulseOut** library) 13 | 14 | Supported Arduinos: 15 | ------------------ 16 | * **ATmega328 (UNO)** 17 | * **ATmega2560 (MEGA)** 18 | * **ATtiny84 (Standalone)** 19 | * **ATtiny85 (Standalone or Digispark)** 20 | * **ATtiny167 (Digispark pro)** 21 | 22 | Tip and Tricks: 23 | -------------- 24 | Develop your project on an arduino UNO or MEGA, and then shrink it by loading the sketch in an ATtiny or Digispark (pro). 25 | 26 | API/methods: 27 | ----------- 28 | * attach() 29 | * available() 30 | * width_us() 31 | * timeout() 32 | * LibVersion() 33 | * LibRevision() 34 | * LibTextVersionRevision() 35 | 36 | Design considerations: 37 | --------------------- 38 | The **SoftRcPulseIn** library relies the **TinyPinChange** library. This one shall be included in the sketch as well. 39 | 40 | On the arduino MEGA, as all the pins do not support "pin change interrupt", only the following pins are supported: 41 | 42 | * 10 -> 15 43 | * 50 -> 53 44 | * A8 -> A15 45 | 46 | On other devices (ATmega328, ATtiny84, ATtiny85 and ATtiny167), all the pins are usable. 47 | 48 | Contact 49 | ------- 50 | 51 | If you have some ideas of enhancement, please contact me by clicking on: [RC Navy](http://p.loussouarn.free.fr/contact.html). 52 | 53 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseIn/SoftRcPulseIn.h: -------------------------------------------------------------------------------- 1 | /* 2 | English: by RC Navy (2012-2015) 3 | ======= 4 | : an asynchronous library to read Input Pulse Width from standard Hobby Radio-Control. This library is a non-blocking version of pulseIn(). 5 | http://p.loussouarn.free.fr 6 | 7 | Francais: par RC Navy (2012-2015) 8 | ======== 9 | : une librairie asynchrone pour lire les largeur d'impulsions des Radio-Commandes standards. Cette librairie est une version non bloquante de pulsIn(). 10 | http://p.loussouarn.free.fr 11 | */ 12 | 13 | #ifndef SOFT_RC_PULSE_IN_H 14 | #define SOFT_RC_PULSE_IN_H 15 | 16 | #if defined(ARDUINO) && ARDUINO >= 100 17 | #include "Arduino.h" 18 | #else 19 | #include "WProgram.h" 20 | #endif 21 | 22 | #include 23 | 24 | #include 25 | 26 | #define SOFT_RC_PULSE_IN_TIMEOUT_SUPPORT 27 | 28 | class SoftRcPulseIn 29 | { 30 | public: 31 | SoftRcPulseIn(); 32 | static int LibVersion(void); 33 | static int LibRevision(void); 34 | static char *LibTextVersionRevision(void); 35 | static void SoftRcPulseInInterrupt(void); 36 | uint8_t attach(uint8_t Pin, uint16_t PulseMin_us = 600, uint16_t PulseMax_us = 2400); 37 | boolean available(); 38 | boolean timeout(uint8_t TimeoutMs, uint8_t *State); 39 | uint16_t width_us(); 40 | private: 41 | class SoftRcPulseIn *next; 42 | static SoftRcPulseIn *first; 43 | uint8_t _Pin; 44 | uint8_t _PinMask; 45 | uint8_t _VirtualPortIdx; 46 | uint16_t _Min_us; 47 | uint16_t _Max_us; 48 | uint32_t _Start_us; 49 | uint32_t _Width_us; 50 | boolean _Available; 51 | #ifdef SOFT_RC_PULSE_IN_TIMEOUT_SUPPORT 52 | uint8_t _LastTimeStampMs; 53 | #endif 54 | }; 55 | /*******************************************************/ 56 | /* Application Programming Interface (API) en Francais */ 57 | /*******************************************************/ 58 | 59 | /* Methodes en Francais English native methods */ 60 | #define attache attach 61 | #define disponible available 62 | #define largeur_us width_us 63 | 64 | #endif 65 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseIn/examples/SoftRcPulseInDemo/SoftRcPulseInDemo.ino: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #define BROCHE_VOIE1 2 5 | 6 | SoftRcPulseIn ImpulsionVoie1; 7 | 8 | 9 | void setup() 10 | { 11 | #if !defined(__AVR_ATtiny24__) && !defined(__AVR_ATtiny44__) && !defined(__AVR_ATtiny84__) && !defined(__AVR_ATtiny25__) && !defined(__AVR_ATtiny45__) && !defined(__AVR_ATtiny85__) 12 | Serial.begin(9600); 13 | Serial.print("SoftRcPulseIn library V");Serial.print(SoftRcPulseIn::LibTextVersionRevision());Serial.print(" demo"); 14 | #endif 15 | ImpulsionVoie1.attache(BROCHE_VOIE1); 16 | } 17 | 18 | void loop() 19 | { 20 | if(ImpulsionVoie1.disponible()) 21 | { 22 | #if !defined(__AVR_ATtiny24__) && !defined(__AVR_ATtiny44__) && !defined(__AVR_ATtiny84__) && !defined(__AVR_ATtiny25__) && !defined(__AVR_ATtiny45__) && !defined(__AVR_ATtiny85__) 23 | Serial.print("Pulse=");Serial.println(ImpulsionVoie1.largeur_us()); 24 | #endif 25 | } 26 | } 27 | 28 | 29 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseIn/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map SoftRcPulseIn 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | SoftRcPulseIn KEYWORD1 10 | 11 | ####################################### 12 | # Methods and Functions (KEYWORD2) 13 | ####################################### 14 | LibVersion KEYWORD2 15 | LibRevision KEYWORD2 16 | LibTextVersionRevision KEYWORD2 17 | attach KEYWORD2 18 | attache KEYWORD2 19 | available KEYWORD2 20 | disponible KEYWORD2 21 | timeout KEYWORD2 22 | width_us KEYWORD2 23 | largeur_us KEYWORD2 24 | 25 | ####################################### 26 | # Constants (LITERAL1) 27 | ####################################### 28 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseOut/examples/Knob/Knob.ino: -------------------------------------------------------------------------------- 1 | // Controlling a servo position using a potentiometer (variable resistor) 2 | // by Michal Rinott 3 | // Adapted to SoftRcPulseOut library by RC Navy (http://p.loussouarn.free.fr) 4 | // This sketch can work with ATtiny and Arduino UNO, MEGA, etc... 5 | 6 | #include 7 | 8 | SoftRcPulseOut myservo; // create servo object to control a servo 9 | 10 | #if defined(__AVR_ATtiny24__) || defined(__AVR_ATtiny44__) || defined(__AVR_ATtiny84__) || defined(__AVR_ATtiny25__) || defined(__AVR_ATtiny45__) || defined(__AVR_ATtiny85__) 11 | //Here is the POT_PIN definition for ATtiny, they do NOT need a 'A' prefix for Analogic definition 12 | #define POT_PIN 2 // --analog pin-- (not digital) used to connect the potentiometer 13 | #else 14 | //Here is the POT_PIN definition for Arduino UNO, MEGA, they do need a 'A' prefix for Analogic definition 15 | #define POT_PIN A3 // --analog pin-- (not digital) used to connect the potentiometer 16 | #endif 17 | 18 | #define SERVO_PIN 3 // --digital pin-- (not analog) used to connect the servo 19 | 20 | #define REFRESH_PERIOD_MS 20 21 | 22 | #define NOW 1 23 | 24 | int val; // variable to read the value from the analog pin 25 | 26 | void setup() 27 | { 28 | myservo.attach(SERVO_PIN); // attaches the servo on pin defined by SERVO_PIN to the servo object 29 | } 30 | 31 | void loop() 32 | { 33 | val = analogRead(POT_PIN); // reads the value of the potentiometer (value between 0 and 1023) 34 | val = map(val, 0, 1023, 0, 179); // scale it to use it with the servo (value between 0 and 180) 35 | myservo.write(val); // sets the servo position according to the scaled value 36 | delay(REFRESH_PERIOD_MS); // waits for the servo to get there 37 | SoftRcPulseOut::refresh(NOW); // generates the servo pulse Now 38 | } 39 | 40 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseOut/examples/SerialServo/SerialServo.ino: -------------------------------------------------------------------------------- 1 | // This SoftwareServo library example sketch was initially delivered without any comments. 2 | // Below my own comments for SoftRcPulseOut library: by RC Navy (http://p.loussouarn.free.fr) 3 | // Controlling the position of 2 servos using the Arduino built-in hardware UART (Arduino Serial object). 4 | // This sketch do NOT work with an ATtinyX4 and ATtinyX5 since they do not have a built-in harware UART (no Arduino Serial object). 5 | 6 | // The command (issued in the Arduino Serial Console or in a Terminal) is: 7 | // S=P with: 8 | // S=A for Servo1 and S=B for Servo2 9 | // P=Position number x 20° (Possible positions are from 0 to 9 which correspond to from 0° to 180°) 10 | // Ex: 11 | // A=7 sets Servo1 at 7 x 20 =140° 12 | // B=3 sets Servo2 at 3 x 20 =60° 13 | 14 | #include 15 | 16 | SoftRcPulseOut servo1; 17 | SoftRcPulseOut servo2; 18 | 19 | void setup() 20 | { 21 | pinMode(13,OUTPUT); 22 | servo1.attach(2); 23 | servo1.setMaximumPulse(2200); 24 | servo2.attach(4); 25 | servo2.setMaximumPulse(2200); 26 | Serial.begin(9600); 27 | Serial.print("Ready"); 28 | } 29 | 30 | void loop() 31 | { 32 | static int value = 0; 33 | static char CurrentServo = 0; 34 | 35 | if ( Serial.available()) { 36 | char ch = Serial.read(); 37 | switch(ch) { 38 | case 'A': 39 | CurrentServo='A'; 40 | digitalWrite(13,LOW); 41 | break; 42 | case 'B': 43 | CurrentServo='B'; 44 | digitalWrite(13,HIGH); 45 | break; 46 | case '0' ... '9': 47 | value=(ch-'0')*20; 48 | if (CurrentServo=='A') 49 | { 50 | servo1.write(value); 51 | } 52 | else if (CurrentServo=='B') 53 | { 54 | servo2.write(value); 55 | } 56 | break; 57 | } 58 | } 59 | SoftRcPulseOut::refresh(); 60 | } 61 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseOut/examples/Sweep/Sweep.ino: -------------------------------------------------------------------------------- 1 | // Sweep 2 | // by BARRAGAN 3 | // Adapted to SoftRcPulseOut library by RC Navy (http://p.loussouarn.free.fr) 4 | // This sketch can work with ATtiny and Arduino UNO, MEGA, etc... 5 | // This example code is in the public domain. 6 | 7 | #include 8 | 9 | SoftRcPulseOut myservo; // create servo object to control a servo 10 | // a maximum of eight servo objects can be created 11 | #define SERVO_PIN 3 12 | 13 | #define REFRESH_PERIOD_MS 20 14 | 15 | #define NOW 1 16 | 17 | int pos = 0; // variable to store the servo position 18 | 19 | void setup() 20 | { 21 | myservo.attach(SERVO_PIN); // attaches the servo on pin defined by SERVO_PIN to the servo object 22 | } 23 | 24 | 25 | void loop() 26 | { 27 | for(pos = 0; pos < 180; pos += 1) // goes from 0 degrees to 180 degrees 28 | { // in steps of 1 degree 29 | myservo.write(pos); // tell servo to go to position in variable 'pos' 30 | delay(REFRESH_PERIOD_MS); // waits 20ms for refresh period 31 | SoftRcPulseOut::refresh(NOW); // generates the servo pulse Now 32 | } 33 | for(pos = 180; pos>=1; pos-=1) // goes from 180 degrees to 0 degrees 34 | { 35 | myservo.write(pos); // tell servo to go to position in variable 'pos' 36 | delay(REFRESH_PERIOD_MS); // waits 20ms for for refresh period 37 | SoftRcPulseOut::refresh(NOW); // generates the servo pulse Now 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseOut/examples/SweepNoDelay/SweepNoDelay.ino: -------------------------------------------------------------------------------- 1 | // SweepNoDelay 2 | // by RC Navy (http://p.loussouarn.free.fr/arduino/arduino.html>) 3 | // This sketch can work with ATtiny and Arduino UNO, MEGA, etc... 4 | // This example code is in the public domain. 5 | 6 | #include 7 | 8 | SoftRcPulseOut myservo; // create servo object to control a servo 9 | // a maximum of eight servo objects can be created 10 | #define SERVO_PIN 0 11 | 12 | #define UP_DIRECTION +1 13 | #define DOWN_DIRECTION -1 14 | 15 | #define POS_MIN 0 16 | #define POS_MAX 180 17 | 18 | int pos = POS_MIN; // variable to store the servo position 19 | int step = UP_DIRECTION; 20 | 21 | void setup() 22 | { 23 | myservo.attach(SERVO_PIN); // attaches the servo on pin defined by SERVO_PIN to the servo object 24 | myservo.write(pos); 25 | } 26 | 27 | void loop() 28 | { 29 | if (SoftRcPulseOut::refresh()) // refresh() returns 1 every 20ms (after pulse update) 30 | { 31 | // We arrive here every 20ms 32 | pos += step; 33 | if(pos >= POS_MAX) step = DOWN_DIRECTION; //180 degrees reached -> Change direction 34 | if(pos <= POS_MIN) step = UP_DIRECTION; // 0 degrees reached -> Change direction 35 | myservo.write(pos); 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseOut/examples/Usb2Servos/Usb2Servos.ino: -------------------------------------------------------------------------------- 1 | // This sketch demonstrates how to command 2 servos through the USB of the Digispark. 2 | // It uses: 3 | // - library to easily generates the RC pulses for the servos. 4 | // - library to communicate with the PC 5 | // By RC Navy (http://p.loussouarn.free.fr) 6 | 7 | // The command (issued in the DigiUSB Monitor or the digiterm) is: 8 | // S=P with: 9 | // S=A for ServoA and S=B for ServoB 10 | // P=Position number x 20° (Possible positions are from 0 to 9 which correspond to from 0° to 180°) 11 | // Ex: 12 | // A=7 sets Servo1 at 7 x 20 =140° 13 | // B=3 sets Servo2 at 3 x 20 =60° 14 | // Once the servo selected, just type the value between 0 and 9 15 | // Please, note this sketch is derived from the SerialServo example of library. 16 | 17 | #include 18 | #include 19 | 20 | #define LED_PIN 1 /* Builtin Led on Rev2 ModelA Digispark */ 21 | #define SERVO_A_PIN 2 22 | /* /!\ Do not use Pin 3 (used by USB) /!\ */ 23 | /* /!\ Do not use Pin 4 (used by USB) /!\ */ 24 | #define SERVO_B_PIN 5 25 | 26 | SoftRcPulseOut ServoA; 27 | SoftRcPulseOut ServoB; 28 | 29 | 30 | void setup() 31 | { 32 | pinMode(LED_PIN,OUTPUT); 33 | ServoA.attach(SERVO_A_PIN); 34 | ServoB.attach(SERVO_B_PIN); 35 | DigiUSB.begin(); 36 | DigiUSB.println(" Ready"); 37 | } 38 | 39 | void loop() 40 | { 41 | static int value = 0; 42 | static char CurrentServo = 0; 43 | 44 | if ( DigiUSB.available()) { 45 | char ch = DigiUSB.read(); 46 | switch(ch) { 47 | case 'A': 48 | CurrentServo='A'; 49 | digitalWrite(LED_PIN,LOW); 50 | break; 51 | case 'B': 52 | CurrentServo='B'; 53 | digitalWrite(LED_PIN,HIGH); 54 | break; 55 | case '0' ... '9': 56 | value=(ch-'0')*20; 57 | if (CurrentServo=='A') 58 | { 59 | ServoA.write(value); 60 | } 61 | else if (CurrentServo=='B') 62 | { 63 | ServoB.write(value); 64 | } 65 | break; 66 | } 67 | } 68 | DigiUSB.refresh(); 69 | SoftRcPulseOut::refresh(); 70 | /* 71 | Put here your non-blocking code 72 | */ 73 | } 74 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftRcPulseOut/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map SoftRcPulseOut 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | SoftRcPulseOut KEYWORD1 10 | 11 | ####################################### 12 | # Methods and Functions (KEYWORD2) 13 | ####################################### 14 | attach KEYWORD2 15 | attache KEYWORD2 16 | detach KEYWORD2 17 | detache KEYWORD2 18 | write KEYWORD2 19 | ecrit KEYWORD2 20 | write_us KEYWORD2 21 | ecrit_us KEYWORD2 22 | read KEYWORD2 23 | lit KEYWORD2 24 | read_us KEYWORD2 25 | lit_us KEYWORD2 26 | attached KEYWORD2 27 | estAttache KEYWORD2 28 | setMinimumPulse KEYWORD2 29 | definitImpulsionMinimum KEYWORD2 30 | setMaximumPulse KEYWORD2 31 | definitImpulsionMaximum KEYWORD2 32 | refresh KEYWORD2 33 | rafraichit KEYWORD2 34 | 35 | ####################################### 36 | # Constants (LITERAL1) 37 | ####################################### 38 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftSerial/Readme.md: -------------------------------------------------------------------------------- 1 | SoftSerial library 2 | ================== 3 | 4 | The **SoftSerial** library is exactly the same as the **SoftwareSerial** library but used with the **TinyPinChange** library which allows to share 5 | the "Pin Change Interrupt" Vector. 6 | 7 | **SoftwareSerial** monopolizes the Pin Change Interrupt Vector and do not allow sharing. 8 | 9 | With **SoftSerial**, it's possible. Don't forget to #include **TinyPinChange** in your sketch! 10 | 11 | Additionally, for small devices such as **ATtiny85** (Digispark), it's possible to declare **the same pin for TX and RX**. 12 | Data direction is set by using the new **txMode()** and **rxMode()** methods. 13 | 14 | Some examples of use cases: 15 | ------------------------- 16 | * **half-duplex bi-directional serial port on a single wire for debuging purpose** 17 | * **half-duplex serial port to interface with Bluetooth module** 18 | * **half-duplex serial port to interconnect an arduino with another one** 19 | 20 | Supported Arduinos: 21 | ------------------ 22 | * **ATmega368 (UNO)** 23 | * **ATmega2560 (MEGA)** 24 | * **ATtiny84 (Standalone)** 25 | * **ATtiny85 (Standalone or Digispark)** 26 | * **ATtiny167 (Digispark pro)** 27 | 28 | Tip and Tricks: 29 | -------------- 30 | Develop your project on an arduino UNO or MEGA, and then shrink it by loading the sketch in an ATtiny or Digispark (pro). 31 | 32 | API/methods: 33 | ----------- 34 | * The **SoftSerial** library uses the same API as the regular **SoftwareSerial** library: 35 | * begin() 36 | * end() 37 | * available() 38 | * read() 39 | * listen() 40 | * isListening() 41 | * overflow() 42 | * flush() 43 | 44 | * Two additional methods are used to manage the serial port on a single pin: 45 | * txMode() 46 | * rxMode() 47 | 48 | Design considerations: 49 | --------------------- 50 | The **SoftSerial** library relies the **TinyPinChange** library **for the RX pin**. This one shall be included in the sketch as well. 51 | 52 | On the arduino MEGA, as all the pins do not support "pin change interrupt", only the following pins are supported **for the RX pin**: 53 | 54 | * 10 -> 15 55 | * 50 -> 53 56 | * A8 -> A15 57 | 58 | On other devices (ATmega328, ATtiny84, ATtiny85 and ATtiny167), all the pins are usable. 59 | 60 | Contact 61 | ------- 62 | 63 | If you have some ideas of enhancement, please contact me by clicking on: [RC Navy](http://p.loussouarn.free.fr/contact.html). 64 | 65 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftSerial/examples/SoftSerialExample/SoftSerialExample.ino: -------------------------------------------------------------------------------- 1 | /* 2 | Software serial multiple serial test 3 | 4 | Receives from the hardware serial, sends to software serial. 5 | Receives from software serial, sends to hardware serial. 6 | 7 | The circuit: 8 | * RX is digital pin 2 (connect to TX of other device) 9 | * TX is digital pin 3 (connect to RX of other device) 10 | 11 | created back in the mists of time 12 | modified 9 Apr 2012 13 | by Tom Igoe 14 | based on Mikal Hart's example 15 | 16 | This example code is in the public domain. 17 | 18 | adapted from for library which allows sharing the Pin Change Interrupt Vector. 19 | Single difference with : add #include at the top of your sketch. 20 | RC Navy (2012): http://p.loussouarn.free.fr 21 | 22 | */ 23 | #include /* Allows Pin Change Interrupt Vector Sharing */ 24 | #include /* Ne pas oublier d'inclure la librairie qui est utilisee par la librairie */ 25 | 26 | SoftSerial mySerial(2, 3); // RX, TX 27 | 28 | void setup() 29 | { 30 | // Open serial communications and wait for port to open: 31 | Serial.begin(57600); 32 | while (!Serial) { 33 | ; // wait for serial port to connect. Needed for Leonardo only 34 | } 35 | 36 | 37 | Serial.println("Goodnight moon!"); 38 | 39 | // set the data rate for the SoftwareSerial port 40 | mySerial.begin(4800); 41 | mySerial.println("Hello, world?"); 42 | } 43 | 44 | void loop() // run over and over 45 | { 46 | if (mySerial.available()) 47 | Serial.write(mySerial.read()); 48 | if (Serial.available()) 49 | mySerial.write(Serial.read()); 50 | } 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftSerial/examples/TwoPortReceive/TwoPortReceive.ino: -------------------------------------------------------------------------------- 1 | /* 2 | Software serial multple serial test 3 | 4 | Receives from the two software serial ports, 5 | sends to the hardware serial port. 6 | 7 | In order to listen on a software port, you call port.listen(). 8 | When using two software serial ports, you have to switch ports 9 | by listen()ing on each one in turn. Pick a logical time to switch 10 | ports, like the end of an expected transmission, or when the 11 | buffer is empty. This example switches ports when there is nothing 12 | more to read from a port 13 | 14 | The circuit: 15 | Two devices which communicate serially are needed. 16 | * First serial device's TX attached to digital pin 2, RX to pin 3 17 | * Second serial device's TX attached to digital pin 4, RX to pin 5 18 | 19 | created 18 Apr. 2011 20 | modified 9 Apr 2012 21 | by Tom Igoe 22 | based on Mikal Hart's twoPortRXExample 23 | 24 | This example code is in the public domain. 25 | 26 | */ 27 | 28 | #include 29 | #include /* Ne pas oublier d'inclure la librairie qui est utilisee par la librairie */ 30 | 31 | // software serial #1: TX = digital pin 2, RX = digital pin 3 32 | SoftSerial portOne(2, 3); 33 | 34 | // software serial #2: TX = digital pin 4, RX = digital pin 5 35 | SoftSerial portTwo(4, 5); 36 | 37 | void setup() 38 | { 39 | // Open serial communications and wait for port to open: 40 | Serial.begin(9600); 41 | while (!Serial) { 42 | ; // wait for serial port to connect. Needed for Leonardo only 43 | } 44 | 45 | 46 | // Start each software serial port 47 | portOne.begin(9600); 48 | portTwo.begin(9600); 49 | } 50 | 51 | void loop() 52 | { 53 | // By default, the last intialized port is listening. 54 | // when you want to listen on a port, explicitly select it: 55 | portOne.listen(); 56 | Serial.println("Data from port one:"); 57 | // while there is data coming in, read it 58 | // and send to the hardware serial port: 59 | while (portOne.available() > 0) { 60 | char inByte = portOne.read(); 61 | Serial.write(inByte); 62 | } 63 | 64 | // blank line to separate data from the two ports: 65 | Serial.println(); 66 | 67 | // Now listen on the second port 68 | portTwo.listen(); 69 | // while there is data coming in, read it 70 | // and send to the hardware serial port: 71 | Serial.println("Data from port two:"); 72 | while (portTwo.available() > 0) { 73 | char inByte = portTwo.read(); 74 | Serial.write(inByte); 75 | } 76 | 77 | // blank line to separate data from the two ports: 78 | Serial.println(); 79 | } 80 | 81 | 82 | 83 | 84 | 85 | 86 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkSoftSerial/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map for SoftSerial 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | SoftSerial KEYWORD1 10 | 11 | ####################################### 12 | # Methods and Functions (KEYWORD2) 13 | ####################################### 14 | 15 | begin KEYWORD2 16 | end KEYWORD2 17 | read KEYWORD2 18 | available KEYWORD2 19 | isListening KEYWORD2 20 | overflow KEYWORD2 21 | flush KEYWORD2 22 | listen KEYWORD2 23 | txMode KEYWORD2 24 | rxMode KEYWORD2 25 | 26 | ####################################### 27 | # Constants (LITERAL1) 28 | ####################################### 29 | 30 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkTinyPinChange/Readme.md: -------------------------------------------------------------------------------- 1 | TinyPinChange library 2 | ===================== 3 | 4 | **TinyPinChange** is an asynchronous (interrupt-driven) library designed to detect event (rising or falling edege) on pins. 5 | 6 | Very often in the arduino world, users complain about conflicts between libraries. 7 | 8 | This **TinyPinChange** library allows to share the "pin change interrupt" vector for several "clients". 9 | 10 | For example, it's possible to use the **SoftRcPulseIn** library whilst using the **SoftSerial** library: both libraries rely on the **TinyPinChange** library. 11 | 12 | Some examples of use cases: 13 | ------------------------- 14 | * **Event detector** (on pins) 15 | * **Frequency meter** 16 | * **Pulse width meter** 17 | * **Tachometer** 18 | * **Duty cycle measurement** 19 | * **Software serial port** (see **SoftSerial** library which relies on TinyPinChange) 20 | 21 | Supported Arduinos: 22 | ------------------ 23 | * **ATmega368 (UNO)** 24 | * **ATmega2560 (MEGA)** 25 | * **ATtiny84 (Standalone)** 26 | * **ATtiny85 (Standalone or Digispark)** 27 | * **ATtiny167 (Digispark pro)** 28 | 29 | Tip and Tricks: 30 | -------------- 31 | Develop your project on an arduino UNO or MEGA, and then shrink it by loading the sketch in an ATtiny or Digispark (pro). 32 | 33 | API/methods: 34 | ----------- 35 | * TinyPinChange_Init() 36 | * TinyPinChange_RegisterIsr() 37 | * TinyPinChange_EnablePin() 38 | * TinyPinChange_DisablePin() 39 | * TinyPinChange_GetPortEvent() 40 | * TinyPinChange_GetCurPortSt() 41 | * TinyPinChange_PinToMsk() 42 | * TinyPinChange_Edge() 43 | * TinyPinChange_RisingEdge 44 | * TinyPinChange_FallingEdge 45 | 46 | Design considerations: 47 | --------------------- 48 | On the arduino MEGA, as all the pins do not support "pin change interrupt", only the following pins are supported: 49 | 50 | * 10 -> 15 51 | * 50 -> 53 52 | * A8 -> A15 53 | 54 | On other devices (ATmega328, ATtiny84, ATtiny85 and ATtiny167), all the pins are usable. 55 | 56 | Contact 57 | ------- 58 | 59 | If you have some ideas of enhancement, please contact me by clicking on: [RC Navy](http://p.loussouarn.free.fr/contact.html). 60 | 61 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkTinyPinChange/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map TinyPinChange 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | TinyPinChange KEYWORD1 9 | 10 | ####################################### 11 | # Methods and Functions (KEYWORD2) 12 | ####################################### 13 | TinyPinChange_Init KEYWORD2 14 | TinyPinChange_RegisterIsr KEYWORD2 15 | TinyPinChange_EnregistreFonctionInterruption KEYWORD2 16 | TinyPinChange_EnablePin KEYWORD2 17 | TinyPinChange_ActiveBroche KEYWORD2 18 | TinyPinChange_DisablePin KEYWORD2 19 | TinyPinChange_DesactiveBroche KEYWORD2 20 | TinyPinChange_GetPortEvent KEYWORD2 21 | TinyPinChange_RetourneEvenemenPort KEYWORD2 22 | TinyPinChange_GetCurPortSt KEYWORD2 23 | TinyPinChange_RetourneEtatCourantPort KEYWORD2 24 | TinyPinChange_PinToMsk KEYWORD2 25 | TinyPinChange_MasqueDeBroche KEYWORD2 26 | TinyPinChange_Edge KEYWORD2 27 | TinyPinChange_Front KEYWORD2 28 | TinyPinChange_RisingEdge KEYWORD2 29 | TinyPinChange_FrontMontant KEYWORD2 30 | TinyPinChange_FallingEdge KEYWORD2 31 | TinyPinChange_FrontDescendant KEYWORD2 32 | 33 | ####################################### 34 | # Constants (LITERAL1) 35 | ####################################### 36 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkTinySoftPwm/Readme.md: -------------------------------------------------------------------------------- 1 | TinySoftPwm library 2 | =================== 3 | 4 | **TinySoftPwm** is a library designed to generate PWM signals by software. 5 | 6 | Some examples of use cases: 7 | ------------------------- 8 | * **RGB strip LED Controller** 9 | * **DC Motor controller** 10 | * **Digital to Analog converter** 11 | 12 | Supported Arduinos: 13 | ------------------ 14 | * **ATtiny85 (Standalone or Digispark)** (up to 6 software PWM supported) 15 | * **ATtiny167 (Digispark pro)** (up to 13 software PWM supported) 16 | 17 | API/methods: 18 | ----------- 19 | * TinySoftPwm_begin() 20 | * TinySoftPwm_analogWrite() 21 | * TinySoftPwm_process() 22 | 23 | 24 | Design considerations: 25 | --------------------- 26 | In order to reduce **program** and **RAM** memories, PWM pins shall be declared in the **TinySoftPwm.h** file. All the required amount of **program** and **RAM** memories are allocated at compilation time. 27 | 28 | The **TinySoftPwm_process()** method shall be called periodically: 29 | 30 | * using micros() in the loop(): in this case, asynchronous programmation shall be used: no call to blocking functions such as delay() is permitted. 31 | * or better using periodic interruption. 32 | 33 | In order to reduce the memory footprint (programm and RAM), try to use the PWM on pins which are part of the same port: PORTA or PORTB. 34 | 35 | Contact 36 | ------- 37 | 38 | If you have some ideas of enhancement, please contact me by clicking on: [RC Navy](http://p.loussouarn.free.fr/contact.html). 39 | 40 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkTinySoftPwm/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map TinySoftPwm 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | TinySoftPwm KEYWORD1 9 | 10 | ####################################### 11 | # Methods and Functions (KEYWORD2) 12 | ####################################### 13 | TinySoftPwm_begin KEYWORD2 14 | TinySoftPwm_analogWrite KEYWORD2 15 | TinySoftPwm_process KEYWORD2 16 | 17 | ####################################### 18 | # Constants (LITERAL1) 19 | ####################################### 20 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/ArduinoNotes.txt: -------------------------------------------------------------------------------- 1 | Notes On Integrating AVRUSB with Arduino 2 | ======================================== 3 | 4 | * Note the license(s) under which AVRUSB is distributed. 5 | 6 | * See also: http://code.rancidbacon.com/ProjectLogArduinoUSB 7 | 8 | * Note: The pins we use on the PCB (not protoboard) hardware shield are: 9 | 10 | INT0 == PD2 == IC Pin 4 == Arduino Digital Pin 2 == D+ 11 | 12 | ---- == PD4 == -------- == Arduino Digital Pin 4 == D- 13 | 14 | ---- == PD5 == -------- == Arduino Digital Pin 5 == pull-up 15 | 16 | (DONE: Change to not use PD3 so INT1 is left free?) 17 | 18 | * In order to compile a valid 'usbconfig.h' file must exit. The content of this 19 | file will vary depending on whether the device is a generic USB device, 20 | generic HID device or specific class of HID device for example. 21 | 22 | The file 'usbconfig-prototype.h' can be used as a starting point, however 23 | it might be easier to use the 'usbconfig.h' from one of the example projects. 24 | 25 | TODO: Specify the settings that need to be changed to match the shield 26 | design we use. 27 | 28 | * (NOTE: Initial 'usbconfig.h' used will be based on the file from 29 | 'HIDKeys.2007-03-29'.) (Note: Have now upgraded to V-USB 2009-08-22.) 30 | 31 | * At present the IDE won't compile our library so it needs to be pre-compiled 32 | with: 33 | 34 | avr-g++ -Wall -Os -I. -DF_CPU=16000000 -mmcu=atmega168 -c usbdrvasm.S -c usbdrv.c 35 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/DigiUSB.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Based on Obdev's AVRUSB code and under the same license. 3 | * 4 | * TODO: Make a proper file header. :-) 5 | */ 6 | #ifndef __DigiUSB_h__ 7 | #define __DigiUSB_h__ 8 | 9 | #include 10 | #include 11 | #include 12 | #include "usbdrv.h" 13 | #include "Print.h" 14 | 15 | 16 | typedef uint8_t byte; 17 | 18 | #include /* for _delay_ms() */ 19 | 20 | #define RING_BUFFER_SIZE 128 21 | 22 | 23 | struct ring_buffer { 24 | unsigned char buffer[RING_BUFFER_SIZE]; 25 | int head; 26 | int tail; 27 | }; 28 | 29 | 30 | 31 | 32 | 33 | class DigiUSBDevice : public Print { 34 | private: 35 | ring_buffer *_rx_buffer; 36 | ring_buffer *_tx_buffer; 37 | 38 | public: 39 | DigiUSBDevice (ring_buffer *rx_buffer, ring_buffer *tx_buffer); 40 | 41 | void begin(); 42 | 43 | // TODO: Deprecate update 44 | void update(); 45 | 46 | void refresh(); 47 | void delay(long milliseconds); 48 | 49 | int available(); 50 | int tx_remaining(); 51 | 52 | int read(); 53 | virtual size_t write(byte c); 54 | using Print::write; 55 | 56 | }; 57 | 58 | extern DigiUSBDevice DigiUSB; 59 | 60 | #endif // __DigiUSB_h__ 61 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/DigisparkReadme.txt: -------------------------------------------------------------------------------- 1 | Modified for use with an Attiny85 running at 16.5Mhz by Digistump for the Digispark MCU -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/examples/DigiBlink/DigiBlink.ino: -------------------------------------------------------------------------------- 1 | #define USB_CFG_DEVICE_NAME 'D','i','g','i','B','l','i','n','k' 2 | #define USB_CFG_DEVICE_NAME_LEN 9 3 | #include 4 | byte in = 0; 5 | int Blue = 0; 6 | int Red = 0; 7 | int Green = 0; 8 | 9 | int next = 0; 10 | 11 | void setup() { 12 | DigiUSB.begin(); 13 | pinMode(0,OUTPUT); 14 | pinMode(1,OUTPUT); 15 | pinMode(2,OUTPUT); 16 | } 17 | 18 | 19 | void loop() { 20 | setBlue(); 21 | DigiUSB.refresh(); 22 | setBlue(); 23 | if (DigiUSB.available() > 0) { 24 | in = 0; 25 | 26 | in = DigiUSB.read(); 27 | if (next == 0){ 28 | if(in == 115){ 29 | next = 1; 30 | DigiUSB.println("Start"); 31 | } 32 | } 33 | else if (next == 1){ 34 | Red = in; 35 | DigiUSB.print("Red "); 36 | DigiUSB.println(in,DEC); 37 | next = 2; 38 | } 39 | else if (next == 2){ 40 | Green = in; 41 | DigiUSB.print("Green "); 42 | DigiUSB.println(in,DEC); 43 | next = 3; 44 | } 45 | else if (next == 3){ 46 | Blue = in; 47 | DigiUSB.print("Blue "); 48 | DigiUSB.println(in,DEC); 49 | next = 0; 50 | } 51 | 52 | 53 | 54 | 55 | } 56 | 57 | 58 | analogWrite(0,Red); 59 | analogWrite(1,Green); 60 | setBlue(); 61 | 62 | 63 | 64 | } 65 | 66 | void setBlue(){ 67 | if(Blue == 0){ 68 | digitalWrite(2,LOW); 69 | return; 70 | } 71 | else if(Blue == 255){ 72 | digitalWrite(2,HIGH); 73 | return; 74 | } 75 | // On period 76 | for (int x=0;x 2 | 3 | void setup() { 4 | DigiUSB.begin(); 5 | } 6 | 7 | void get_input() { 8 | // when there are no characters to read 9 | while (1==1) { 10 | if(DigiUSB.available()){ 11 | //something to read 12 | DigiUSB.read(); 13 | break; 14 | } 15 | // refresh the usb port 16 | DigiUSB.refresh(); 17 | delay(10); 18 | 19 | } 20 | 21 | } 22 | 23 | 24 | void loop() { 25 | DigiUSB.refresh(); 26 | //print output 27 | float value = analogRead(1); //This is Pin3 28 | if(value>1020) 29 | value = 255; 30 | else if(value<2) 31 | value = 0; 32 | else 33 | value = value/4; 34 | //send value 35 | 36 | value = round(byte(value)); 37 | DigiUSB.write(value); 38 | 39 | //wait for response 40 | get_input(); 41 | 42 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/examples/DigiUSB2LCD/DigiUSB2LCD.ino: -------------------------------------------------------------------------------- 1 | /* USB LCD */ 2 | 3 | //#define DEBUG 4 | #include // I2C Master lib for ATTinys which use USI - comment this out to use with standard arduinos 5 | #include // for LCD w/ GPIO MODIFIED for the ATtiny85 6 | #include 7 | 8 | #define GPIO_ADDR 0x27 // (PCA8574A A0-A2 @5V) typ. A0-A3 Gnd 0x20 / 0x38 for A - 0x27 is the address of the Digispark LCD modules. 9 | int currentLine = 0; 10 | boolean clearOnNext = 0; 11 | boolean backlight = 1; 12 | 13 | LiquidCrystal_I2C lcd(GPIO_ADDR,16,2); // set address & 16 chars / 2 lines 14 | 15 | 16 | void setup(){ 17 | DigiUSB.begin(); 18 | Wire.begin(); // initialize I2C lib - comment this out to use with standard arduinos 19 | lcd.init(); // initialize the lcd 20 | lcd.backlight(); // Print a message to the LCD. 21 | lcd.setCursor(0, currentLine); 22 | } 23 | 24 | 25 | void get_input() { 26 | 27 | int lastRead; 28 | // when there are no characters to read, or the character isn't a newline 29 | while (1==1) { 30 | if(DigiUSB.available()){ 31 | //something to read 32 | lastRead = DigiUSB.read(); 33 | if(lastRead == '\n'){ 34 | 35 | 36 | if(currentLine > 0) 37 | currentLine = 0; 38 | else 39 | currentLine = 1; 40 | 41 | clearOnNext = 1; 42 | 43 | lcd.setCursor(0, currentLine); 44 | 45 | } 46 | else if(lastRead == 172){ //not sign "¬" send it with the send program to toggle the backlight 47 | if(backlight){ 48 | lcd.noBacklight(); 49 | backlight = 0; 50 | } 51 | else{ 52 | lcd.backlight(); 53 | backlight = 1; 54 | } 55 | DigiUSB.read(); //read to nothing to get rid of newline that should come after it 56 | 57 | } 58 | else{ 59 | if(clearOnNext){ 60 | lcd.print(" "); //clear a single line 61 | lcd.setCursor(0, currentLine); 62 | clearOnNext=0; 63 | } 64 | lcd.print(char(lastRead)); 65 | } 66 | 67 | 68 | 69 | } 70 | // refresh the usb port 71 | DigiUSB.refresh(); 72 | delay(10); 73 | 74 | } 75 | 76 | } 77 | 78 | 79 | void loop(){ 80 | get_input(); 81 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/examples/Echo/Echo.ino: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | void setup() { 4 | DigiUSB.begin(); 5 | } 6 | 7 | void get_input() { 8 | int lastRead; 9 | // when there are no characters to read, or the character isn't a newline 10 | while (true) { // loop forever 11 | if (DigiUSB.available()) { 12 | // something to read 13 | lastRead = DigiUSB.read(); 14 | DigiUSB.write(lastRead); 15 | 16 | if (lastRead == '\n') { 17 | break; // when we get a newline, break out of loop 18 | } 19 | } 20 | 21 | // refresh the usb port for 10 milliseconds 22 | DigiUSB.delay(10); 23 | } 24 | } 25 | 26 | void loop() { 27 | // print output 28 | DigiUSB.println("Waiting for input..."); 29 | // get input 30 | get_input(); 31 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/keywords.txt: -------------------------------------------------------------------------------- 1 | DigiUSB KEYWORD1 2 | refresh KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/libs-device/Readme.txt: -------------------------------------------------------------------------------- 1 | This is the Readme file for the libs-device directory. This directory contains 2 | code snippets which may be useful for USB device firmware. 3 | 4 | 5 | WHAT IS INCLUDED IN THIS DIRECTORY? 6 | =================================== 7 | 8 | osccal.c and osccal.h 9 | This module contains a function which calibrates the AVR's built-in RC 10 | oscillator based on the USB frame clock. See osccal.h for a documentation 11 | of the API. 12 | 13 | osctune.h 14 | This header file contains a code snippet for usbconfig.h. With this code, 15 | you can keep the AVR's internal RC oscillator in sync with the USB frame 16 | clock. This is a continuous synchronization, not a single calibration at 17 | USB reset as with osccal.c above. Please note that this code works only 18 | if D- is wired to the interrupt, not D+. 19 | 20 | ---------------------------------------------------------------------------- 21 | (c) 2008 by OBJECTIVE DEVELOPMENT Software GmbH. 22 | http://www.obdev.at/ 23 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/libs-device/osccal.c: -------------------------------------------------------------------------------- 1 | /* Name: osccal.c 2 | * Author: Christian Starkjohann 3 | * Creation Date: 2008-04-10 4 | * Tabsize: 4 5 | * Copyright: (c) 2008 by OBJECTIVE DEVELOPMENT Software GmbH 6 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 7 | * This Revision: $Id: osccal.c 762 2009-08-12 17:10:30Z cs $ 8 | */ 9 | 10 | #include 11 | 12 | #ifndef uchar 13 | #define uchar unsigned char 14 | #endif 15 | 16 | /* ------------------------------------------------------------------------- */ 17 | /* ------------------------ Oscillator Calibration ------------------------- */ 18 | /* ------------------------------------------------------------------------- */ 19 | 20 | /* Calibrate the RC oscillator. Our timing reference is the Start Of Frame 21 | * signal (a single SE0 bit) repeating every millisecond immediately after 22 | * a USB RESET. We first do a binary search for the OSCCAL value and then 23 | * optimize this value with a neighboorhod search. 24 | */ 25 | void calibrateOscillator(void) 26 | { 27 | uchar step = 128; 28 | uchar trialValue = 0, optimumValue; 29 | int x, optimumDev, targetValue = (unsigned)(1499 * (double)F_CPU / 10.5e6 + 0.5); 30 | 31 | /* do a binary search: */ 32 | do{ 33 | OSCCAL = trialValue + step; 34 | x = usbMeasureFrameLength(); /* proportional to current real frequency */ 35 | if(x < targetValue) /* frequency still too low */ 36 | trialValue += step; 37 | step >>= 1; 38 | }while(step > 0); 39 | /* We have a precision of +/- 1 for optimum OSCCAL here */ 40 | /* now do a neighborhood search for optimum value */ 41 | optimumValue = trialValue; 42 | optimumDev = x; /* this is certainly far away from optimum */ 43 | for(OSCCAL = trialValue - 1; OSCCAL <= trialValue + 1; OSCCAL++){ 44 | x = usbMeasureFrameLength() - targetValue; 45 | if(x < 0) 46 | x = -x; 47 | if(x < optimumDev){ 48 | optimumDev = x; 49 | optimumValue = OSCCAL; 50 | } 51 | } 52 | OSCCAL = optimumValue; 53 | } 54 | /* 55 | Note: This calibration algorithm may try OSCCAL values of up to 192 even if 56 | the optimum value is far below 192. It may therefore exceed the allowed clock 57 | frequency of the CPU in low voltage designs! 58 | You may replace this search algorithm with any other algorithm you like if 59 | you have additional constraints such as a maximum CPU clock. 60 | For version 5.x RC oscillators (those with a split range of 2x128 steps, e.g. 61 | ATTiny25, ATTiny45, ATTiny85), it may be useful to search for the optimum in 62 | both regions. 63 | */ 64 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/libs-device/osccal.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/DigisparkUSB/libs-device/osccal.o -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/oddebug.c: -------------------------------------------------------------------------------- 1 | /* Name: oddebug.c 2 | * Project: AVR library 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2005-01-16 5 | * Tabsize: 4 6 | * Copyright: (c) 2005 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id: oddebug.c 692 2008-11-07 15:07:40Z cs $ 9 | */ 10 | 11 | #include "oddebug.h" 12 | 13 | #if DEBUG_LEVEL > 0 14 | 15 | #warning "Never compile production devices with debugging enabled" 16 | 17 | static void uartPutc(char c) 18 | { 19 | while(!(ODDBG_USR & (1 << ODDBG_UDRE))); /* wait for data register empty */ 20 | ODDBG_UDR = c; 21 | } 22 | 23 | static uchar hexAscii(uchar h) 24 | { 25 | h &= 0xf; 26 | if(h >= 10) 27 | h += 'a' - (uchar)10 - '0'; 28 | h += '0'; 29 | return h; 30 | } 31 | 32 | static void printHex(uchar c) 33 | { 34 | uartPutc(hexAscii(c >> 4)); 35 | uartPutc(hexAscii(c)); 36 | } 37 | 38 | void odDebug(uchar prefix, uchar *data, uchar len) 39 | { 40 | printHex(prefix); 41 | uartPutc(':'); 42 | while(len--){ 43 | uartPutc(' '); 44 | printHex(*data++); 45 | } 46 | uartPutc('\r'); 47 | uartPutc('\n'); 48 | } 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/rx_buffer.h: -------------------------------------------------------------------------------- 1 | #ifndef __rx_buffer_h__ 2 | #define __rx_buffer_h__ 3 | 4 | #ifdef __cplusplus 5 | extern "C"{ 6 | #endif 7 | uchar rx_buffer[8]; // Buffer 8 bytes 8 | extern int rx_read_offset; // = -1; 9 | extern int rx_write_offset; // = 0; 10 | #ifdef __cplusplus 11 | } // extern "C" 12 | #endif 13 | 14 | #endif // __rx_buffer_h__ 15 | -------------------------------------------------------------------------------- /digistump-avr/libraries/DigisparkUSB/usbdrvasm.asm: -------------------------------------------------------------------------------- 1 | /* Name: usbdrvasm.asm 2 | * Project: V-USB, virtual USB port for Atmel's(r) AVR(r) microcontrollers 3 | * Author: Christian Starkjohann 4 | * Creation Date: 2006-03-01 5 | * Tabsize: 4 6 | * Copyright: (c) 2006 by OBJECTIVE DEVELOPMENT Software GmbH 7 | * License: GNU GPL v2 (see License.txt), GNU GPL v3 or proprietary (CommercialLicense.txt) 8 | * This Revision: $Id$ 9 | */ 10 | 11 | /* 12 | General Description: 13 | The IAR compiler/assembler system prefers assembler files with file extension 14 | ".asm". We simply provide this file as an alias for usbdrvasm.S. 15 | 16 | Thanks to Oleg Semyonov for his help with the IAR tools port! 17 | */ 18 | 19 | #include "usbdrvasm.S" 20 | 21 | end 22 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/BasicRobot/BasicRobot.ino: -------------------------------------------------------------------------------- 1 | void setup() { 2 | // put your setup code here, to run once: 3 | botInit(); 4 | } 5 | 6 | 7 | void loop() { 8 | // put your main code here, to run repeatedly: 9 | botForward(255); //speed can be any value from 0 (stopped) to 255 (full) 10 | delay(5000); 11 | botReverse(255); 12 | delay(5000); 13 | botRight(255); 14 | delay(5000); 15 | botHardRight(255); 16 | delay(5000); 17 | botLeft(255); 18 | delay(5000); 19 | botHardLeft(255); 20 | delay(5000); 21 | botStop(); 22 | delay(5000); 23 | } 24 | 25 | void botForward(int botSpeed){ 26 | digitalWrite(2, HIGH); 27 | digitalWrite(5, HIGH); 28 | analogWrite(0, 255 - botSpeed); 29 | analogWrite(1, 255 - botSpeed); 30 | } 31 | 32 | void botReverse(int botSpeed){ 33 | digitalWrite(2, LOW); 34 | digitalWrite(5, LOW); 35 | analogWrite(0, botSpeed); 36 | analogWrite(1, botSpeed); 37 | } 38 | 39 | void botRight(int botSpeed){ 40 | digitalWrite(2, LOW); 41 | digitalWrite(5, HIGH); 42 | analogWrite(0, 0); 43 | analogWrite(1, 255 - botSpeed); 44 | } 45 | 46 | void botHardRight(int botSpeed){ 47 | digitalWrite(2, LOW); 48 | digitalWrite(5, HIGH); 49 | analogWrite(0, botSpeed); 50 | analogWrite(1, 255 - botSpeed); 51 | } 52 | 53 | void botLeft(int botSpeed){ 54 | digitalWrite(2, HIGH); 55 | digitalWrite(5, LOW); 56 | analogWrite(0, 255 - botSpeed); 57 | analogWrite(1, 0); 58 | } 59 | 60 | void botHardLeft(int botSpeed){ 61 | digitalWrite(2, HIGH); 62 | digitalWrite(5, LOW); 63 | analogWrite(0, 255 - botSpeed); 64 | analogWrite(1, botSpeed); 65 | } 66 | 67 | void botStop(){ 68 | digitalWrite(2,LOW); 69 | digitalWrite(5,LOW); 70 | analogWrite(0,0); 71 | analogWrite(1,0); 72 | } 73 | 74 | void botInit(){ 75 | pinMode(0,OUTPUT); 76 | pinMode(1,OUTPUT); 77 | pinMode(2,OUTPUT); 78 | pinMode(5,OUTPUT); 79 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/Blink/Blink.ino: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | // the setup routine runs once when you press reset: 4 | void setup() { 5 | // initialize the digital pin as an output. 6 | pinMode(0, OUTPUT); //LED on MH-ET LIVE Tiny88 or Model B - Never seen Model B in the wild 7 | pinMode(LED_BUILTIN, OUTPUT); //LED on Model A or Pro 8 | } 9 | 10 | // the loop routine runs over and over again forever: 11 | // If you only see short flashes, you own a Model B Or you have an MH-ET LIVE Tiny88 board 12 | void loop() { 13 | digitalWrite(0, HIGH); // turn the LED on (HIGH is the voltage level) 14 | digitalWrite(LED_BUILTIN, HIGH); 15 | delay(100); // wait for 100 ms 16 | digitalWrite(0, LOW); // turn the Model B LED off by making the voltage LOW 17 | delay(900); // wait for a second 18 | digitalWrite(LED_BUILTIN, LOW); // turn the Model A or Pro LED off by making the voltage LOW 19 | delay(1000); // wait for a second 20 | } 21 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/Charlieplex/Charlieplex.ino: -------------------------------------------------------------------------------- 1 | void setup() { 2 | // initialize the digital pin as an output. 3 | 4 | 5 | } 6 | 7 | // the loop routine runs over and over again forever: 8 | void loop() { 9 | LEDon(0, 1); 10 | delay(1000); 11 | LEDon(0, 2); 12 | delay(1000); 13 | LEDon(0, 3); 14 | delay(1000); 15 | LEDon(0, 4); 16 | delay(1000); 17 | LEDon(1, 0); 18 | delay(1000); 19 | LEDon(1, 2); 20 | delay(1000); 21 | LEDon(1, 3); 22 | delay(1000); 23 | LEDon(1, 4); 24 | delay(1000); 25 | LEDon(2, 0); 26 | delay(1000); 27 | LEDon(2, 1); 28 | delay(1000); 29 | LEDon(2, 3); 30 | delay(1000); 31 | LEDon(2, 4); 32 | delay(1000); 33 | LEDon(3, 0); 34 | delay(1000); 35 | LEDon(3, 1); 36 | delay(1000); 37 | LEDon(3, 2); 38 | delay(1000); 39 | LEDon(3, 4); 40 | delay(1000); 41 | LEDon(4, 0); 42 | delay(1000); 43 | LEDon(4, 1); 44 | delay(1000); 45 | LEDon(4, 2); 46 | delay(1000); 47 | LEDon(4, 3); 48 | delay(1000); 49 | } 50 | 51 | void LEDon(int vin, int gnd) { 52 | pinMode(0, INPUT); 53 | pinMode(1, INPUT); 54 | pinMode(2, INPUT); 55 | pinMode(3, INPUT); 56 | pinMode(4, INPUT); 57 | pinMode(5, INPUT); 58 | 59 | pinMode(vin, OUTPUT); 60 | pinMode(gnd, OUTPUT); 61 | digitalWrite(vin, HIGH); 62 | digitalWrite(gnd, LOW); 63 | } 64 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/Digispark_Examples.h: -------------------------------------------------------------------------------- 1 | //This file allows the Digispark_Examples to appear in the File > Examples menu and fixes the Invalid library warning in Arduino IDE 1.6.6+ 2 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/EEPROM/EEPROM.ino: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define disk1 0x50 //Address of 24LC256 eeprom chip 4 | int returned = 0; 5 | void setup(void) 6 | { 7 | //Serial.begin(9600); 8 | Wire.begin(); 9 | 10 | unsigned int address = 0; 11 | pinMode(5, OUTPUT); 12 | 13 | writeEEPROM(disk1, address, 5); 14 | returned = readEEPROM(disk1, address); 15 | 16 | while(returned>0){ 17 | digitalWrite(5,HIGH); 18 | delay(500); 19 | digitalWrite(5,LOW); 20 | delay(500); 21 | returned--; 22 | } 23 | 24 | } 25 | 26 | void loop(){} 27 | 28 | void writeEEPROM(int deviceaddress, unsigned int eeaddress, byte data ) 29 | { 30 | Wire.beginTransmission(deviceaddress); 31 | Wire.send((int)(eeaddress >> 8)); // MSB 32 | Wire.send((int)(eeaddress & 0xFF)); // LSB 33 | Wire.send(data); 34 | Wire.endTransmission(); 35 | 36 | delay(5); 37 | } 38 | 39 | byte readEEPROM(int deviceaddress, unsigned int eeaddress ) 40 | { 41 | byte rdata = 0xFF; 42 | 43 | Wire.beginTransmission(deviceaddress); 44 | Wire.send((int)(eeaddress >> 8)); // MSB 45 | Wire.send((int)(eeaddress & 0xFF)); // LSB 46 | Wire.endTransmission(); 47 | 48 | Wire.requestFrom(deviceaddress,1); 49 | 50 | if (Wire.available()) rdata = Wire.receive(); 51 | 52 | return rdata; 53 | } 54 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/Expander/Expander.ino: -------------------------------------------------------------------------------- 1 | #include 2 | #define expander 0x20 3 | 4 | byte expanderStatus = B11111111; //all off 5 | 6 | void setup() 7 | { 8 | Wire.begin(); 9 | } 10 | 11 | void loop() 12 | { 13 | expanderWrite(0,HIGH); 14 | delay(1000); 15 | expanderWrite(0,LOW); 16 | delay(1000); 17 | } 18 | 19 | 20 | void expanderWrite(byte pinNumber, boolean state){ 21 | if(state == HIGH) 22 | expanderStatus &= ~(1 << pinNumber); 23 | else 24 | expanderStatus |= (1 << pinNumber); 25 | 26 | expanderWrite(expanderStatus); 27 | } 28 | 29 | void expanderWrite(byte _data ) { 30 | Wire.beginTransmission(expander); 31 | Wire.send(_data); 32 | Wire.endTransmission(); 33 | } 34 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/MotorShield/MotorShield.ino: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | This example code is in the public domain. 4 | */ 5 | 6 | int MotorADir = 2; 7 | int MotorASpeed = 0; 8 | int MotorBDir = 5; 9 | int MotorBSpeed = 1; 10 | 11 | // the setup routine runs once when you press reset: 12 | void setup() { 13 | // initialize the outputs. 14 | pinMode(MotorADir, OUTPUT); 15 | pinMode(MotorASpeed, OUTPUT); 16 | pinMode(MotorBDir, OUTPUT); 17 | pinMode(MotorBSpeed, OUTPUT); 18 | } 19 | 20 | // the loop routine runs over and over again forever: 21 | void loop() { 22 | //both motors forward full speed 23 | digitalWrite(MotorADir, HIGH); //forward 24 | digitalWrite(MotorBDir, HIGH); 25 | analogWrite(MotorASpeed, 255); //full speed 26 | analogWrite(MotorBSpeed, 255); 27 | delay(5000); // wait for 5 seconds 28 | //turn in place (if using a skid steer configuration) 29 | digitalWrite(MotorADir, HIGH); //forward 30 | digitalWrite(MotorBDir, HIGH); 31 | analogWrite(MotorASpeed, 255); 32 | analogWrite(MotorBSpeed, 0); //off 33 | delay(5000); // wait for 5 seconds 34 | //turn gradually - the other direction (if using a skid steer configuration) 35 | digitalWrite(MotorADir, HIGH); //forward 36 | digitalWrite(MotorBDir, HIGH); 37 | analogWrite(MotorASpeed, 100); 38 | analogWrite(MotorBSpeed, 255); 39 | delay(5000); // wait for 5 seconds 40 | //stop 41 | digitalWrite(MotorADir, HIGH); //forward 42 | digitalWrite(MotorBDir, HIGH); 43 | analogWrite(MotorASpeed, 0); 44 | analogWrite(MotorBSpeed, 0); //off 45 | //reverse slowly 46 | digitalWrite(MotorADir, LOW); //reverse 47 | digitalWrite(MotorBDir, LOW); 48 | analogWrite(MotorASpeed, 100); 49 | analogWrite(MotorBSpeed, 100); 50 | } 51 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/SerialEcho/SerialEcho.ino: -------------------------------------------------------------------------------- 1 | 2 | void setup() { 3 | Serial.begin(9600); 4 | } 5 | 6 | // the loop routine runs over and over again forever: 7 | void loop() { 8 | if (Serial.available()) { 9 | Serial.write(Serial.read()); 10 | } 11 | 12 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/SerialRobot/SerialRobot.ino: -------------------------------------------------------------------------------- 1 | void setup() { 2 | // put your setup code here, to run once: 3 | Serial.begin(9600); 4 | botInit(); //setup the pins for the bot 5 | 6 | } 7 | 8 | 9 | void loop() { 10 | 11 | if(Serial.available()){ 12 | 13 | char input = Serial.read(); 14 | 15 | //route based on input 16 | 17 | if(input == 'f'){ 18 | botForward(255); 19 | } 20 | else if(input == 'b'){ 21 | botReverse(255); 22 | } 23 | else if(input == 'r'){ 24 | botRight(255); 25 | } 26 | else if(input == 'l'){ 27 | botLeft(255); 28 | } 29 | else if(input == 's'){ 30 | botStop(); 31 | } 32 | } 33 | 34 | 35 | } 36 | 37 | 38 | void botForward(int botSpeed){ 39 | digitalWrite(2, HIGH); 40 | digitalWrite(5, HIGH); 41 | analogWrite(0, 255 - botSpeed); 42 | analogWrite(1, 255 - botSpeed); 43 | } 44 | 45 | void botReverse(int botSpeed){ 46 | digitalWrite(2, LOW); 47 | digitalWrite(5, LOW); 48 | analogWrite(0, botSpeed); 49 | analogWrite(1, botSpeed); 50 | } 51 | 52 | void botRight(int botSpeed){ 53 | digitalWrite(2, LOW); 54 | digitalWrite(5, HIGH); 55 | analogWrite(0, 0); 56 | analogWrite(1, 255 - botSpeed); 57 | } 58 | 59 | void botHardRight(int botSpeed){ 60 | digitalWrite(2, LOW); 61 | digitalWrite(5, HIGH); 62 | analogWrite(0, botSpeed); 63 | analogWrite(1, 255 - botSpeed); 64 | } 65 | 66 | void botLeft(int botSpeed){ 67 | digitalWrite(2, HIGH); 68 | digitalWrite(5, LOW); 69 | analogWrite(0, 255 - botSpeed); 70 | analogWrite(1, 0); 71 | } 72 | 73 | void botHardLeft(int botSpeed){ 74 | digitalWrite(2, HIGH); 75 | digitalWrite(5, LOW); 76 | analogWrite(0, 255 - botSpeed); 77 | analogWrite(1, botSpeed); 78 | } 79 | 80 | void botStop(){ 81 | digitalWrite(2,LOW); 82 | digitalWrite(5,LOW); 83 | analogWrite(0,0); 84 | analogWrite(1,0); 85 | } 86 | 87 | void botInit(){ 88 | pinMode(0,OUTPUT); 89 | pinMode(1,OUTPUT); 90 | pinMode(2,OUTPUT); 91 | pinMode(5,OUTPUT); 92 | } 93 | 94 | 95 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/WiFiServerExample/WiFiServerExample.ino: -------------------------------------------------------------------------------- 1 | void setup() { 2 | // put your setup code here, to run once: 3 | pinMode(1,OUTPUT); //use onboard LED as output 4 | delay(10000);//wait for wifi to connect 5 | Serial.begin(9600); //open connection to wifi module 6 | /*========================================================== 7 | = NOTE: This assumes you have used the wifi module = 8 | = web interface to set it up as a server and 9600 baud = 9 | = See the wifi shield page for more info. = 10 | ========================================================== 11 | 12 | Goto: http://[WIFI IP ADDRESS]:[WIFI SERVER PORT]/ to see the response 13 | ie. http://192.168.0.123:8899/ 14 | 15 | */ 16 | } 17 | 18 | 19 | void loop() { 20 | 21 | if(serverRequest()){ 22 | //new request 23 | //find the path requested 24 | String path = getRequestPath(); 25 | 26 | //route based on path 27 | 28 | ///wrap responses and other strings in F() to save ram 29 | 30 | if(path == F("/on")){ 31 | digitalWrite(1,HIGH); 32 | sendResponse(F("LED ON
LED OFF")); 33 | } 34 | else if(path == F("/off")){ 35 | digitalWrite(1,LOW); 36 | sendResponse(F("LED OFF
LED ON")); 37 | } 38 | else{ 39 | sendResponse(F("WELCOME
LED ON
LED OFF")); 40 | } 41 | } 42 | 43 | 44 | } 45 | 46 | bool serverRequest(){ 47 | if(Serial.available()>4){ 48 | return Serial.find("GET "); 49 | } 50 | return false; 51 | } 52 | 53 | String getRequestPath(){ 54 | String path = Serial.readStringUntil(' '); 55 | while(Serial.read() != -1); //clear read buffer 56 | return path; 57 | } 58 | void sendResponse(String response){ 59 | sendResponseStart(); 60 | sendResponseChunk(response); 61 | sendResponseEnd(); 62 | } 63 | 64 | 65 | void sendResponseStart(){ 66 | //sends a chunked response 67 | Serial.println(F("HTTP/1.1 200 OK")); 68 | Serial.println(F("Content-Type: text/html")); 69 | Serial.println(F("Connection: close")); 70 | Serial.println(F("Transfer-Encoding: chunked")); 71 | Serial.println(); 72 | } 73 | void sendResponseChunk(String response){ 74 | 75 | Serial.println(response.length()+2,HEX); 76 | Serial.println(response); 77 | Serial.println(); 78 | 79 | } 80 | void sendResponseEnd(){ 81 | Serial.println(F("0")); 82 | Serial.println(); 83 | } 84 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Digispark_Examples/i2cScanner/i2cScanner.ino: -------------------------------------------------------------------------------- 1 | // -------------------------------------- 2 | // i2c_scanner 3 | // 4 | // Version 1 5 | // This program (or code that looks like it) 6 | // can be found in many places. 7 | // For example on the Arduino.cc forum. 8 | // The original author is not know. 9 | // Version 2, Juni 2012, Using Arduino 1.0.1 10 | // Adapted to be as simple as possible by Arduino.cc user Krodal 11 | // Version 3, Feb 26 2013 12 | // V3 by louarnold 13 | // Version 4, March 3, 2013, Using Arduino 1.0.3 14 | // by Arduino.cc user Krodal. 15 | // Changes by louarnold removed. 16 | // Scanning addresses changed from 0...127 to 1...119, 17 | // according to the i2c scanner by Nick Gammon 18 | // http://www.gammon.com.au/forum/?id=10896 19 | // Version 5, March 28, 2013 20 | // As version 4, but address scans now to 127. 21 | // A sensor seems to use address 120. 22 | // 23 | // 24 | // This sketch tests the standard 7-bit addresses 25 | // Devices with higher bit address might not be seen properly. 26 | // 27 | 28 | #include 29 | #include 30 | 31 | void setup() 32 | { 33 | 34 | Wire.begin(); 35 | DigiKeyboard.delay(3000); 36 | 37 | DigiKeyboard.println("\nI2C Scanner"); 38 | } 39 | 40 | 41 | void loop() 42 | { 43 | byte error, address; 44 | int nDevices; 45 | 46 | DigiKeyboard.println("Scanning..."); 47 | 48 | nDevices = 0; 49 | for (address = 1; address < 127; address++ ) 50 | { 51 | // The i2c_scanner uses the return value of 52 | // the Write.endTransmisstion to see if 53 | // a device did acknowledge to the address. 54 | Wire.beginTransmission(address); 55 | error = Wire.endTransmission(); 56 | 57 | if (error == 0) 58 | { 59 | DigiKeyboard.print("I2C device found at address 0x"); 60 | if (address < 16) 61 | DigiKeyboard.print("0"); 62 | DigiKeyboard.print(address, HEX); 63 | DigiKeyboard.println(" !"); 64 | 65 | nDevices++; 66 | } 67 | else if (error == 4) 68 | { 69 | DigiKeyboard.print("Unknow error at address 0x"); 70 | if (address < 16) 71 | DigiKeyboard.print("0"); 72 | DigiKeyboard.println(address, HEX); 73 | } 74 | } 75 | if (nDevices == 0) 76 | DigiKeyboard.println("No I2C devices found\n"); 77 | else 78 | DigiKeyboard.println("done\n"); 79 | 80 | DigiKeyboard.delay(5000); // wait 5 seconds for next scan 81 | } 82 | 83 | 84 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_clear/eeprom_clear.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * EEPROM Clear 3 | * 4 | * Sets all of the bytes of the EEPROM to 0. 5 | * Please see eeprom_iteration for a more in depth 6 | * look at how to traverse the EEPROM. 7 | * 8 | * This example code is in the public domain. 9 | */ 10 | 11 | #include 12 | 13 | void setup() { 14 | // initialize the LED pin as an output. 15 | pinMode(13, OUTPUT); 16 | 17 | /*** 18 | Iterate through each byte of the EEPROM storage. 19 | 20 | Larger AVR processors have larger EEPROM sizes, E.g: 21 | - Arduno Duemilanove: 512b EEPROM storage. 22 | - Arduino Uno: 1kb EEPROM storage. 23 | - Arduino Mega: 4kb EEPROM storage. 24 | 25 | Rather than hard-coding the length, you should use the pre-provided length function. 26 | This will make your code portable to all AVR processors. 27 | ***/ 28 | 29 | for (int i = 0 ; i < EEPROM.length() ; i++) { 30 | EEPROM.write(i, 0); 31 | } 32 | 33 | // turn the LED on when we're done 34 | digitalWrite(13, HIGH); 35 | } 36 | 37 | void loop() { 38 | /** Empty loop. **/ 39 | } 40 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_crc/eeprom_crc.ino: -------------------------------------------------------------------------------- 1 | /*** 2 | Written by Christopher Andrews. 3 | CRC algorithm generated by pycrc, MIT licence ( https://github.com/tpircher/pycrc ). 4 | 5 | A CRC is a simple way of checking whether data has changed or become corrupted. 6 | This example calculates a CRC value directly on the EEPROM values. 7 | The purpose of this example is to highlight how the EEPROM object can be used just like an array. 8 | ***/ 9 | 10 | #include 11 | #include 12 | 13 | void setup() { 14 | 15 | //Start serial 16 | Serial.begin(9600); 17 | while (!Serial) { 18 | ; // wait for serial port to connect. Needed for native USB port only 19 | } 20 | 21 | //Print length of data to run CRC on. 22 | Serial.print("EEPROM length: "); 23 | Serial.println(EEPROM.length()); 24 | 25 | //Print the result of calling eeprom_crc() 26 | Serial.print("CRC32 of EEPROM data: 0x"); 27 | Serial.println(eeprom_crc(), HEX); 28 | Serial.print("\n\nDone!"); 29 | } 30 | 31 | void loop() { 32 | /* Empty loop */ 33 | } 34 | 35 | unsigned long eeprom_crc(void) { 36 | 37 | const unsigned long crc_table[16] = { 38 | 0x00000000, 0x1db71064, 0x3b6e20c8, 0x26d930ac, 39 | 0x76dc4190, 0x6b6b51f4, 0x4db26158, 0x5005713c, 40 | 0xedb88320, 0xf00f9344, 0xd6d6a3e8, 0xcb61b38c, 41 | 0x9b64c2b0, 0x86d3d2d4, 0xa00ae278, 0xbdbdf21c 42 | }; 43 | 44 | unsigned long crc = ~0L; 45 | 46 | for (int index = 0 ; index < EEPROM.length() ; ++index) { 47 | crc = crc_table[(crc ^ EEPROM[index]) & 0x0f] ^ (crc >> 4); 48 | crc = crc_table[(crc ^ (EEPROM[index] >> 4)) & 0x0f] ^ (crc >> 4); 49 | crc = ~crc; 50 | } 51 | return crc; 52 | } 53 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_get/eeprom_get.ino: -------------------------------------------------------------------------------- 1 | /*** 2 | eeprom_get example. 3 | 4 | This shows how to use the EEPROM.get() method. 5 | 6 | To pre-set the EEPROM data, run the example sketch eeprom_put. 7 | This sketch will run without it, however, the values shown 8 | will be shown from what ever is already on the EEPROM. 9 | 10 | This may cause the serial object to print out a large string 11 | of garbage if there is no null character inside one of the strings 12 | loaded. 13 | 14 | Written by Christopher Andrews 2015 15 | Released under MIT licence. 16 | ***/ 17 | 18 | #include 19 | 20 | void setup() { 21 | 22 | float f = 0.00f; //Variable to store data read from EEPROM. 23 | int eeAddress = 0; //EEPROM address to start reading from 24 | 25 | Serial.begin(9600); 26 | while (!Serial) { 27 | ; // wait for serial port to connect. Needed for native USB port only 28 | } 29 | Serial.print("Read float from EEPROM: "); 30 | 31 | //Get the float data from the EEPROM at position 'eeAddress' 32 | EEPROM.get(eeAddress, f); 33 | Serial.println(f, 3); //This may print 'ovf, nan' if the data inside the EEPROM is not a valid float. 34 | 35 | /*** 36 | As get also returns a reference to 'f', you can use it inline. 37 | E.g: Serial.print( EEPROM.get( eeAddress, f ) ); 38 | ***/ 39 | 40 | /*** 41 | Get can be used with custom structures too. 42 | I have separated this into an extra function. 43 | ***/ 44 | 45 | secondTest(); //Run the next test. 46 | } 47 | 48 | struct MyObject { 49 | float field1; 50 | byte field2; 51 | char name[10]; 52 | }; 53 | 54 | void secondTest() { 55 | int eeAddress = sizeof(float); //Move address to the next byte after float 'f'. 56 | 57 | MyObject customVar; //Variable to store custom object read from EEPROM. 58 | EEPROM.get(eeAddress, customVar); 59 | 60 | Serial.println("Read custom object from EEPROM: "); 61 | Serial.println(customVar.field1); 62 | Serial.println(customVar.field2); 63 | Serial.println(customVar.name); 64 | } 65 | 66 | void loop() { 67 | /* Empty loop */ 68 | } 69 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_iteration/eeprom_iteration.ino: -------------------------------------------------------------------------------- 1 | /*** 2 | eeprom_iteration example. 3 | 4 | A set of example snippets highlighting the 5 | simplest methods for traversing the EEPROM. 6 | 7 | Running this sketch is not necessary, this is 8 | simply highlighting certain programming methods. 9 | 10 | Written by Christopher Andrews 2015 11 | Released under MIT licence. 12 | ***/ 13 | 14 | #include 15 | 16 | void setup() { 17 | 18 | /*** 19 | Iterate the EEPROM using a for loop. 20 | ***/ 21 | 22 | for (int index = 0 ; index < EEPROM.length() ; index++) { 23 | 24 | //Add one to each cell in the EEPROM 25 | EEPROM[ index ] += 1; 26 | } 27 | 28 | /*** 29 | Iterate the EEPROM using a while loop. 30 | ***/ 31 | 32 | int index = 0; 33 | 34 | while (index < EEPROM.length()) { 35 | 36 | //Add one to each cell in the EEPROM 37 | EEPROM[ index ] += 1; 38 | index++; 39 | } 40 | 41 | /*** 42 | Iterate the EEPROM using a do-while loop. 43 | ***/ 44 | 45 | int idx = 0; //Used 'idx' to avoid name conflict with 'index' above. 46 | 47 | do { 48 | 49 | //Add one to each cell in the EEPROM 50 | EEPROM[ idx ] += 1; 51 | idx++; 52 | } while (idx < EEPROM.length()); 53 | 54 | 55 | } //End of setup function. 56 | 57 | void loop() {} -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_put/eeprom_put.ino: -------------------------------------------------------------------------------- 1 | /*** 2 | eeprom_put example. 3 | 4 | This shows how to use the EEPROM.put() method. 5 | Also, this sketch will pre-set the EEPROM data for the 6 | example sketch eeprom_get. 7 | 8 | Note, unlike the single byte version EEPROM.write(), 9 | the put method will use update semantics. As in a byte 10 | will only be written to the EEPROM if the data is actually 11 | different. 12 | 13 | Written by Christopher Andrews 2015 14 | Released under MIT licence. 15 | ***/ 16 | 17 | #include 18 | 19 | struct MyObject { 20 | float field1; 21 | byte field2; 22 | char name[10]; 23 | }; 24 | 25 | void setup() { 26 | 27 | Serial.begin(9600); 28 | while (!Serial) { 29 | ; // wait for serial port to connect. Needed for native USB port only 30 | } 31 | 32 | float f = 123.456f; //Variable to store in EEPROM. 33 | int eeAddress = 0; //Location we want the data to be put. 34 | 35 | 36 | //One simple call, with the address first and the object second. 37 | EEPROM.put(eeAddress, f); 38 | 39 | Serial.println("Written float data type!"); 40 | 41 | /** Put is designed for use with custom structures also. **/ 42 | 43 | //Data to store. 44 | MyObject customVar = { 45 | 3.14f, 46 | 65, 47 | "Working!" 48 | }; 49 | 50 | eeAddress += sizeof(float); //Move address to the next byte after float 'f'. 51 | 52 | EEPROM.put(eeAddress, customVar); 53 | Serial.print("Written custom data type! \n\nView the example sketch eeprom_get to see how you can retrieve the values!"); 54 | } 55 | 56 | void loop() { 57 | /* Empty loop */ 58 | } 59 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * EEPROM Read 3 | * 4 | * Reads the value of each byte of the EEPROM and prints it 5 | * to the computer. 6 | * This example code is in the public domain. 7 | */ 8 | 9 | #include 10 | 11 | // start reading from the first byte (address 0) of the EEPROM 12 | int address = 0; 13 | byte value; 14 | 15 | void setup() { 16 | // initialize serial and wait for port to open: 17 | Serial.begin(9600); 18 | while (!Serial) { 19 | ; // wait for serial port to connect. Needed for native USB port only 20 | } 21 | } 22 | 23 | void loop() { 24 | // read a byte from the current address of the EEPROM 25 | value = EEPROM.read(address); 26 | 27 | Serial.print(address); 28 | Serial.print("\t"); 29 | Serial.print(value, DEC); 30 | Serial.println(); 31 | 32 | /*** 33 | Advance to the next address, when at the end restart at the beginning. 34 | 35 | Larger AVR processors have larger EEPROM sizes, E.g: 36 | - Arduno Duemilanove: 512b EEPROM storage. 37 | - Arduino Uno: 1kb EEPROM storage. 38 | - Arduino Mega: 4kb EEPROM storage. 39 | 40 | Rather than hard-coding the length, you should use the pre-provided length function. 41 | This will make your code portable to all AVR processors. 42 | ***/ 43 | address = address + 1; 44 | if (address == EEPROM.length()) { 45 | address = 0; 46 | } 47 | 48 | /*** 49 | As the EEPROM sizes are powers of two, wrapping (preventing overflow) of an 50 | EEPROM address is also doable by a bitwise and of the length - 1. 51 | 52 | ++address &= EEPROM.length() - 1; 53 | ***/ 54 | 55 | delay(500); 56 | } 57 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_update/eeprom_update.ino: -------------------------------------------------------------------------------- 1 | /*** 2 | EEPROM Update method 3 | 4 | Stores values read from analog input 0 into the EEPROM. 5 | These values will stay in the EEPROM when the board is 6 | turned off and may be retrieved later by another sketch. 7 | 8 | If a value has not changed in the EEPROM, it is not overwritten 9 | which would reduce the life span of the EEPROM unnecessarily. 10 | 11 | Released using MIT licence. 12 | ***/ 13 | 14 | #include 15 | 16 | /** the current address in the EEPROM (i.e. which byte we're going to write to next) **/ 17 | int address = 0; 18 | 19 | void setup() { 20 | /** EMpty setup **/ 21 | } 22 | 23 | void loop() { 24 | /*** 25 | need to divide by 4 because analog inputs range from 26 | 0 to 1023 and each byte of the EEPROM can only hold a 27 | value from 0 to 255. 28 | ***/ 29 | int val = analogRead(0) / 4; 30 | 31 | /*** 32 | Update the particular EEPROM cell. 33 | these values will remain there when the board is 34 | turned off. 35 | ***/ 36 | EEPROM.update(address, val); 37 | 38 | /*** 39 | The function EEPROM.update(address, val) is equivalent to the following: 40 | 41 | if( EEPROM.read(address) != val ){ 42 | EEPROM.write(address, val); 43 | } 44 | ***/ 45 | 46 | 47 | /*** 48 | Advance to the next address, when at the end restart at the beginning. 49 | 50 | Larger AVR processors have larger EEPROM sizes, E.g: 51 | - Arduno Duemilanove: 512b EEPROM storage. 52 | - Arduino Uno: 1kb EEPROM storage. 53 | - Arduino Mega: 4kb EEPROM storage. 54 | 55 | Rather than hard-coding the length, you should use the pre-provided length function. 56 | This will make your code portable to all AVR processors. 57 | ***/ 58 | address = address + 1; 59 | if (address == EEPROM.length()) { 60 | address = 0; 61 | } 62 | 63 | /*** 64 | As the EEPROM sizes are powers of two, wrapping (preventing overflow) of an 65 | EEPROM address is also doable by a bitwise and of the length - 1. 66 | 67 | ++address &= EEPROM.length() - 1; 68 | ***/ 69 | 70 | delay(100); 71 | } 72 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/examples/eeprom_write/eeprom_write.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * EEPROM Write 3 | * 4 | * Stores values read from analog input 0 into the EEPROM. 5 | * These values will stay in the EEPROM when the board is 6 | * turned off and may be retrieved later by another sketch. 7 | */ 8 | 9 | #include 10 | 11 | /** the current address in the EEPROM (i.e. which byte we're going to write to next) **/ 12 | int addr = 0; 13 | 14 | void setup() { 15 | /** Empty setup. **/ 16 | } 17 | 18 | void loop() { 19 | /*** 20 | Need to divide by 4 because analog inputs range from 21 | 0 to 1023 and each byte of the EEPROM can only hold a 22 | value from 0 to 255. 23 | ***/ 24 | 25 | int val = analogRead(0) / 4; 26 | 27 | /*** 28 | Write the value to the appropriate byte of the EEPROM. 29 | these values will remain there when the board is 30 | turned off. 31 | ***/ 32 | 33 | EEPROM.write(addr, val); 34 | 35 | /*** 36 | Advance to the next address, when at the end restart at the beginning. 37 | 38 | Larger AVR processors have larger EEPROM sizes, E.g: 39 | - Arduno Duemilanove: 512b EEPROM storage. 40 | - Arduino Uno: 1kb EEPROM storage. 41 | - Arduino Mega: 4kb EEPROM storage. 42 | 43 | Rather than hard-coding the length, you should use the pre-provided length function. 44 | This will make your code portable to all AVR processors. 45 | ***/ 46 | addr = addr + 1; 47 | if (addr == EEPROM.length()) { 48 | addr = 0; 49 | } 50 | 51 | /*** 52 | As the EEPROM sizes are powers of two, wrapping (preventing overflow) of an 53 | EEPROM address is also doable by a bitwise and of the length - 1. 54 | 55 | ++addr &= EEPROM.length() - 1; 56 | ***/ 57 | 58 | 59 | delay(100); 60 | } 61 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map For EEPROM 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | EEPROM KEYWORD1 10 | EERef KEYWORD1 11 | EEPtr KEYWORD2 12 | 13 | ####################################### 14 | # Methods and Functions (KEYWORD2) 15 | ####################################### 16 | 17 | update KEYWORD2 18 | 19 | ####################################### 20 | # Constants (LITERAL1) 21 | ####################################### 22 | 23 | -------------------------------------------------------------------------------- /digistump-avr/libraries/EEPROM/library.properties: -------------------------------------------------------------------------------- 1 | name=EEPROM 2 | version=2.0 3 | author=Arduino, Christopher Andrews 4 | maintainer=Arduino 5 | sentence=Enables reading and writing to the permanent board storage. 6 | paragraph=This library allows to read and write data in a memory type, the EEPROM, that keeps its content also when the board is powered off. The amount of EEPROM available depends on the microcontroller type. 7 | category=Data Storage 8 | url=http://www.arduino.cc/en/Reference/EEPROM 9 | architectures=avr 10 | 11 | -------------------------------------------------------------------------------- /digistump-avr/libraries/NewExamples/New_Examples.h: -------------------------------------------------------------------------------- 1 | //This file allows the Digispark_Examples to appear in the File > Examples menu and fixes the Invalid library warning in Arduino IDE 1.6.6+ 2 | -------------------------------------------------------------------------------- /digistump-avr/libraries/NewExamples/OpenWindowAlarm/OpenWindowAlarm.ino: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/libraries/NewExamples/OpenWindowAlarm/OpenWindowAlarm.ino -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/ArduinoNunchuk.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * ArduinoNunchuk.cpp - Improved Wii Nunchuk library for Arduino 3 | * 4 | * Copyright 2011-2013 Gabriel Bianconi, http://www.gabrielbianconi.com/ 5 | * 6 | * Project URL: http://www.gabrielbianconi.com/projects/arduinonunchuk/ 7 | * 8 | * Based on the following resources: 9 | * http://www.windmeadow.com/node/42 10 | * http://todbot.com/blog/2008/02/18/wiichuck-wii-nunchuck-adapter-available/ 11 | * http://wiibrew.org/wiki/Wiimote/Extension_Controllers 12 | * 13 | */ 14 | 15 | #include 16 | #include 17 | #include "ArduinoNunchuk.h" 18 | 19 | #define ADDRESS 0x52 20 | 21 | void ArduinoNunchuk::init() 22 | { 23 | TinyWireM.begin(); 24 | 25 | ArduinoNunchuk::_sendByte(0x55, 0xF0); 26 | ArduinoNunchuk::_sendByte(0x00, 0xFB); 27 | 28 | ArduinoNunchuk::update(); 29 | } 30 | 31 | void ArduinoNunchuk::update() 32 | { 33 | int count = 0; 34 | int values[6]; 35 | 36 | TinyWireM.requestFrom(ADDRESS, 6); 37 | 38 | while(TinyWireM.available()) 39 | { 40 | values[count] = TinyWireM.receive(); 41 | count++; 42 | } 43 | 44 | ArduinoNunchuk::analogX = values[0]; 45 | ArduinoNunchuk::analogY = values[1]; 46 | ArduinoNunchuk::accelX = (values[2] << 2) | ((values[5] >> 2) & 3); 47 | ArduinoNunchuk::accelY = (values[3] << 2) | ((values[5] >> 4) & 3); 48 | ArduinoNunchuk::accelZ = (values[4] << 2) | ((values[5] >> 6) & 3); 49 | ArduinoNunchuk::zButton = !((values[5] >> 0) & 1); 50 | ArduinoNunchuk::cButton = !((values[5] >> 1) & 1); 51 | 52 | ArduinoNunchuk::_sendByte(0x00, 0x00); 53 | } 54 | 55 | void ArduinoNunchuk::_sendByte(byte data, byte location) 56 | { 57 | TinyWireM.beginTransmission(ADDRESS); 58 | 59 | TinyWireM.send(location); 60 | TinyWireM.send(data); 61 | 62 | TinyWireM.endTransmission(); 63 | 64 | delay(10); 65 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/ArduinoNunchuk.h: -------------------------------------------------------------------------------- 1 | /* 2 | * ArduinoNunchuk.h - Improved Wii Nunchuk library for Arduino 3 | * 4 | * Copyright 2011-2013 Gabriel Bianconi, http://www.gabrielbianconi.com/ 5 | * 6 | * Project URL: http://www.gabrielbianconi.com/projects/arduinonunchuk/ 7 | * 8 | * Based on the following resources: 9 | * http://www.windmeadow.com/node/42 10 | * http://todbot.com/blog/2008/02/18/wiichuck-wii-nunchuck-adapter-available/ 11 | * http://wiibrew.org/wiki/Wiimote/Extension_Controllers 12 | * 13 | */ 14 | 15 | #ifndef ArduinoNunchuk_H 16 | #define ArduinoNunchuk_H 17 | 18 | #include 19 | 20 | class ArduinoNunchuk 21 | { 22 | public: 23 | int analogX; 24 | int analogY; 25 | int accelX; 26 | int accelY; 27 | int accelZ; 28 | int zButton; 29 | int cButton; 30 | 31 | void init(); 32 | void update(); 33 | 34 | private: 35 | void _sendByte(byte data, byte location); 36 | }; 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/LICENSE.txt: -------------------------------------------------------------------------------- 1 | LICENSE 2 | 3 | This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 444 Castro Street, Suite 900, Mountain View, California, 94041, USA. -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/README.txt: -------------------------------------------------------------------------------- 1 | ArduinoNunchuk - Improved Wii Nunchuk library for Arduino 2 | 3 | Copyright 2011-2013 Gabriel Bianconi, http://www.gabrielbianconi.com/ 4 | 5 | Project URL: http://www.gabrielbianconi.com/projects/arduinonunchuk/ 6 | 7 | Based on the following resources: 8 | - http://www.windmeadow.com/node/42 9 | - http://todbot.com/blog/2008/02/18/wiichuck-wii-nunchuck-adapter-available/ 10 | - http://wiibrew.org/wiki/Wiimote/Extension_Controllers 11 | 12 | 13 | INSTALLATION: 14 | 15 | Copy the 'ArduinoNunchuk' folder, located in the same folder as this 'README' file, to the Arduino libraries folder (Arduino/libraries). -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/examples/ArduinoNunchukDemo/ArduinoNunchukDemo.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * ArduinoNunchukDemo.ino 3 | * 4 | * Copyright 2011-2013 Gabriel Bianconi, http://www.gabrielbianconi.com/ 5 | * 6 | * Project URL: http://www.gabrielbianconi.com/projects/arduinonunchuk/ 7 | * 8 | */ 9 | 10 | #include 11 | #include 12 | 13 | #define BAUDRATE 19200 14 | 15 | ArduinoNunchuk nunchuk = ArduinoNunchuk(); 16 | 17 | void setup() 18 | { 19 | Serial.begin(BAUDRATE); 20 | nunchuk.init(); 21 | } 22 | 23 | void loop() 24 | { 25 | nunchuk.update(); 26 | 27 | Serial.print(nunchuk.analogX, DEC); 28 | Serial.print(' '); 29 | Serial.print(nunchuk.analogY, DEC); 30 | Serial.print(' '); 31 | Serial.print(nunchuk.accelX, DEC); 32 | Serial.print(' '); 33 | Serial.print(nunchuk.accelY, DEC); 34 | Serial.print(' '); 35 | Serial.print(nunchuk.accelZ, DEC); 36 | Serial.print(' '); 37 | Serial.print(nunchuk.zButton, DEC); 38 | Serial.print(' '); 39 | Serial.println(nunchuk.cButton, DEC); 40 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/examples/DigisparkJoystickDemo/DigisparkJoystickDemo.ino: -------------------------------------------------------------------------------- 1 | //DigiJoystick Nunchuck Demo 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | ArduinoNunchuk nunchuk = ArduinoNunchuk(); 8 | 9 | void setup() { 10 | nunchuk.init(); 11 | } 12 | 13 | 14 | void loop() { 15 | nunchuk.update(); 16 | DigiJoystick.setX((byte) nunchuk.analogX); // scroll X left to right repeatedly 17 | DigiJoystick.setY((byte) nunchuk.analogY); 18 | DigiJoystick.setXROT((byte) map(nunchuk.accelX,255,700,0,255)); 19 | DigiJoystick.setYROT((byte) map(nunchuk.accelY,255,850,0,255)); 20 | DigiJoystick.setZROT((byte) map(nunchuk.accelZ,255,750,0,255)); 21 | int buttonByte = 0; 22 | bitWrite(buttonByte, 0, nunchuk.zButton); 23 | bitWrite(buttonByte, 1, nunchuk.cButton); 24 | DigiJoystick.setButtons((byte) buttonByte, (byte) 0); 25 | DigiJoystick.delay(10); 26 | 27 | 28 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/examples/DigisparkUSBDemo/DigisparkUSBDemo.ino: -------------------------------------------------------------------------------- 1 | /* 2 | * Digispark Nunchuck shield demo 3 | * 4 | * Uses arduinonunchuk - Copyright 2011-2013 Gabriel Bianconi, http://www.gabrielbianconi.com/ - http://www.gabrielbianconi.com/projects/arduinonunchuk/ 5 | * 6 | */ 7 | 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | ArduinoNunchuk nunchuk = ArduinoNunchuk(); 14 | 15 | void setup() 16 | { 17 | DigiUSB.begin(); 18 | nunchuk.init(); 19 | } 20 | 21 | void loop() 22 | { 23 | nunchuk.update(); 24 | 25 | DigiUSB.println(nunchuk.analogX, DEC); 26 | 27 | DigiUSB.println(nunchuk.analogY, DEC); 28 | 29 | DigiUSB.println(nunchuk.accelX, DEC); 30 | 31 | DigiUSB.println(nunchuk.accelY, DEC); 32 | 33 | DigiUSB.println(nunchuk.accelZ, DEC); 34 | 35 | DigiUSB.println(nunchuk.zButton, DEC); 36 | 37 | DigiUSB.println(nunchuk.cButton, DEC); 38 | 39 | DigiUSB.delay(250); 40 | } -------------------------------------------------------------------------------- /digistump-avr/libraries/Nunchuk/keywords.txt: -------------------------------------------------------------------------------- 1 | ArduinoNunchuk KEYWORD1 2 | init KEYWORD2 3 | update KEYWORD2 -------------------------------------------------------------------------------- /digistump-avr/libraries/OneWire/examples/DS2408_Switch/DS2408_Switch.ino: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | /* 4 | * DS2408 8-Channel Addressable Switch 5 | * 6 | * Writte by Glenn Trewitt, glenn at trewitt dot org 7 | * 8 | * Some notes about the DS2408: 9 | * - Unlike most input/output ports, the DS2408 doesn't have mode bits to 10 | * set whether the pins are input or output. If you issue a read command, 11 | * they're inputs. If you write to them, they're outputs. 12 | * - For reading from a switch, you should use 10K pull-up resisters. 13 | */ 14 | 15 | void PrintBytes(uint8_t* addr, uint8_t count, bool newline=0) { 16 | for (uint8_t i = 0; i < count; i++) { 17 | Serial.print(addr[i]>>4, HEX); 18 | Serial.print(addr[i]&0x0f, HEX); 19 | } 20 | if (newline) 21 | Serial.println(); 22 | } 23 | 24 | void ReadAndReport(OneWire* net, uint8_t* addr) { 25 | Serial.print(" Reading DS2408 "); 26 | PrintBytes(addr, 8); 27 | Serial.println(); 28 | 29 | uint8_t buf[13]; // Put everything in the buffer so we can compute CRC easily. 30 | buf[0] = 0xF0; // Read PIO Registers 31 | buf[1] = 0x88; // LSB address 32 | buf[2] = 0x00; // MSB address 33 | net->write_bytes(buf, 3); 34 | net->read_bytes(buf+3, 10); // 3 cmd bytes, 6 data bytes, 2 0xFF, 2 CRC16 35 | net->reset(); 36 | 37 | if (!OneWire::check_crc16(buf, 11, &buf[11])) { 38 | Serial.print("CRC failure in DS2408 at "); 39 | PrintBytes(addr, 8, true); 40 | return; 41 | } 42 | Serial.print(" DS2408 data = "); 43 | // First 3 bytes contain command, register address. 44 | Serial.println(buf[3], BIN); 45 | } 46 | 47 | OneWire net(10); // on pin 10 48 | 49 | void setup(void) { 50 | Serial.begin(9600); 51 | } 52 | 53 | void loop(void) { 54 | byte i; 55 | byte present = 0; 56 | byte addr[8]; 57 | 58 | if (!net.search(addr)) { 59 | Serial.print("No more addresses.\n"); 60 | net.reset_search(); 61 | delay(1000); 62 | return; 63 | } 64 | 65 | if (OneWire::crc8(addr, 7) != addr[7]) { 66 | Serial.print("CRC is not valid!\n"); 67 | return; 68 | } 69 | 70 | if (addr[0] != 0x29) { 71 | PrintBytes(addr, 8); 72 | Serial.print(" is not a DS2408.\n"); 73 | return; 74 | } 75 | 76 | ReadAndReport(&net, addr); 77 | } 78 | -------------------------------------------------------------------------------- /digistump-avr/libraries/OneWire/examples/Digispark_Example/Digispark_Example.ino: -------------------------------------------------------------------------------- 1 | 2 | #include 3 | #include 4 | #define DS18S20_ID 0x10 5 | #define DS18B20_ID 0x28 6 | int temp; 7 | 8 | 9 | OneWire ds(5); 10 | 11 | byte data[12]; 12 | byte addr[8]; 13 | 14 | boolean readTemperature(){ 15 | 16 | 17 | 18 | //find a device 19 | 20 | 21 | if (!ds.search(addr)) { 22 | ds.reset_search(); 23 | return false; 24 | } 25 | if (OneWire::crc8( addr, 7) != addr[7]) { 26 | return false; 27 | } 28 | if (addr[0] != DS18S20_ID && addr[0] != DS18B20_ID) { 29 | return false; 30 | } 31 | 32 | ds.reset(); 33 | ds.select(addr); 34 | // Start conversion 35 | ds.write(0x44, 1); 36 | // Wait some time... 37 | } 38 | 39 | boolean getTemperature(){ 40 | byte i; 41 | byte present = 0; 42 | present = ds.reset(); 43 | ds.select(addr); 44 | // Issue Read scratchpad command 45 | ds.write(0xBE); 46 | // Receive 9 bytes 47 | for ( i = 0; i < 9; i++) { 48 | data[i] = ds.read(); 49 | } 50 | // Calculate temperature value 51 | temp = ((( (data[1] << 8) + data[0] )*0.0625)*1.8)+32; 52 | return true; 53 | 54 | } 55 | 56 | void setup(){ 57 | DigiUSB.begin(); 58 | DigiUSB.print("Start"); 59 | } 60 | 61 | 62 | void loop(){ 63 | 64 | 65 | readTemperature(); 66 | DigiUSB.delay(1000); 67 | getTemperature(); 68 | DigiUSB.println(temp); 69 | 70 | DigiUSB.delay(1000); 71 | 72 | 73 | 74 | } 75 | 76 | 77 | -------------------------------------------------------------------------------- /digistump-avr/libraries/OneWire/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map For OneWire 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | OneWire KEYWORD1 10 | 11 | ####################################### 12 | # Methods and Functions (KEYWORD2) 13 | ####################################### 14 | 15 | reset KEYWORD2 16 | write_bit KEYWORD2 17 | read_bit KEYWORD2 18 | write KEYWORD2 19 | write_bytes KEYWORD2 20 | read KEYWORD2 21 | read_bytes KEYWORD2 22 | select KEYWORD2 23 | skip KEYWORD2 24 | depower KEYWORD2 25 | reset_search KEYWORD2 26 | search KEYWORD2 27 | crc8 KEYWORD2 28 | crc16 KEYWORD2 29 | check_crc16 KEYWORD2 30 | 31 | ####################################### 32 | # Instances (KEYWORD2) 33 | ####################################### 34 | 35 | 36 | ####################################### 37 | # Constants (LITERAL1) 38 | ####################################### 39 | -------------------------------------------------------------------------------- /digistump-avr/libraries/TinyWireM/README.md: -------------------------------------------------------------------------------- 1 | TinyWireM 2 | ========= 3 | 4 | ATtiny (e.g. Adafruit Trinket, Gemma) I2C library, adapted from BroHogan's code on Arduino Playground: http://playground.arduino.cc/Code/USIi2c 5 | 6 | Minor changes for consistency with the Arduino 1.0 Wire library (e.g. uses write() instead of send()). Buffer size slightly increased for Adafruit_LEDBackpack use. 7 | 8 | On the Trinket boards, pin #0 is SDA (I2C data), pin #2 is SCK (I2C clock). 9 | -------------------------------------------------------------------------------- /digistump-avr/libraries/TinyWireM/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map For TinyWireM 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | ####################################### 10 | # Methods and Functions (KEYWORD2) 11 | ####################################### 12 | 13 | begin KEYWORD2 14 | beginTransmission KEYWORD2 15 | endTransmission KEYWORD2 16 | requestFrom KEYWORD2 17 | write KEYWORD2 18 | read KEYWORD2 19 | 20 | ####################################### 21 | # Instances (KEYWORD2) 22 | ####################################### 23 | 24 | TinyWireM KEYWORD2 25 | 26 | ####################################### 27 | # Constants (LITERAL1) 28 | ####################################### 29 | 30 | -------------------------------------------------------------------------------- /digistump-avr/libraries/TinyWireM/library.properties: -------------------------------------------------------------------------------- 1 | name=TinyWireM 2 | version=1.0.0 3 | author=Adafruit 4 | maintainer=Adafruit 5 | sentence=I2C library for Trinket and Gemma, adapted from BroHogan's code on Arduino Playground 6 | paragraph=I2C library for Trinket and Gemma, adapted from BroHogan's code on Arduino Playground 7 | category=Signal Input/Output 8 | url=https://github.com/adafruit/TinyWireM 9 | architectures=* 10 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino: -------------------------------------------------------------------------------- 1 | // I2C Digital Potentiometer 2 | // by Nicholas Zambetti 3 | // and Shawn Bonkowski 4 | 5 | // Demonstrates use of the Wire library 6 | // Controls AD5171 digital potentiometer via I2C/TWI 7 | 8 | // Created 31 March 2006 9 | 10 | // This example code is in the public domain. 11 | 12 | // This example code is in the public domain. 13 | 14 | 15 | #include 16 | 17 | void setup() { 18 | Wire.begin(); // join i2c bus (address optional for master) 19 | } 20 | 21 | byte val = 0; 22 | 23 | void loop() { 24 | Wire.beginTransmission(44); // transmit to device #44 (0x2c) 25 | // device address is specified in datasheet 26 | Wire.write(byte(0x00)); // sends instruction byte 27 | Wire.write(val); // sends potentiometer value byte 28 | Wire.endTransmission(); // stop transmitting 29 | 30 | val++; // increment value 31 | if (val == 64) { // if reached 64th position (max) 32 | val = 0; // start over from lowest value 33 | } 34 | delay(500); 35 | } 36 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/examples/master_reader/master_reader.ino: -------------------------------------------------------------------------------- 1 | // Wire Master Reader 2 | // by Nicholas Zambetti 3 | 4 | // Demonstrates use of the Wire library 5 | // Reads data from an I2C/TWI slave device 6 | // Refer to the "Wire Slave Sender" example for use with this 7 | 8 | // Created 29 March 2006 9 | 10 | // This example code is in the public domain. 11 | 12 | 13 | #include 14 | 15 | void setup() { 16 | Wire.begin(); // join i2c bus (address optional for master) 17 | Serial.begin(9600); // start serial for output 18 | } 19 | 20 | void loop() { 21 | Wire.requestFrom(8, 6); // request 6 bytes from slave device #8 22 | 23 | //while (Wire.available()) { // slave may send less than requested 24 | char c = Wire.read(); // receive a byte as character 25 | Serial.print(c); // print the character 26 | //} 27 | 28 | delay(500); 29 | } 30 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/examples/master_writer/master_writer.ino: -------------------------------------------------------------------------------- 1 | // Wire Master Writer 2 | // by Nicholas Zambetti 3 | 4 | // Demonstrates use of the Wire library 5 | // Writes data to an I2C/TWI slave device 6 | // Refer to the "Wire Slave Receiver" example for use with this 7 | 8 | // Created 29 March 2006 9 | 10 | // This example code is in the public domain. 11 | 12 | 13 | #include 14 | 15 | void setup() { 16 | Wire.begin(); // join i2c bus (address optional for master) 17 | } 18 | 19 | byte x = 0; 20 | 21 | void loop() { 22 | Wire.beginTransmission(8); // transmit to device #8 23 | Wire.write("x is "); // sends five bytes 24 | Wire.write(x); // sends one byte 25 | Wire.endTransmission(); // stop transmitting 26 | 27 | x++; 28 | delay(500); 29 | } 30 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/examples/slave_receiver/slave_receiver.ino: -------------------------------------------------------------------------------- 1 | // Wire Slave Receiver 2 | // by Nicholas Zambetti 3 | 4 | // Demonstrates use of the Wire library 5 | // Receives data as an I2C/TWI slave device 6 | // Refer to the "Wire Master Writer" example for use with this 7 | 8 | // Created 29 March 2006 9 | 10 | // This example code is in the public domain. 11 | 12 | 13 | #include 14 | 15 | void setup() { 16 | Wire.begin(8); // join i2c bus with address #8 17 | Wire.onReceive(receiveEvent); // register event 18 | Serial.begin(9600); // start serial for output 19 | } 20 | 21 | void loop() { 22 | delay(100); 23 | } 24 | 25 | // function that executes whenever data is received from master 26 | // this function is registered as an event, see setup() 27 | void receiveEvent(int howMany) { 28 | while (1 < Wire.available()) { // loop through all but the last 29 | char c = Wire.read(); // receive byte as a character 30 | Serial.print(c); // print the character 31 | } 32 | int x = Wire.read(); // receive byte as an integer 33 | Serial.println(x); // print the integer 34 | } 35 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/examples/slave_sender/slave_sender.ino: -------------------------------------------------------------------------------- 1 | // Wire Slave Sender 2 | // by Nicholas Zambetti 3 | 4 | // Demonstrates use of the Wire library 5 | // Sends data as an I2C/TWI slave device 6 | // Refer to the "Wire Master Reader" example for use with this 7 | 8 | // Created 29 March 2006 9 | 10 | // This example code is in the public domain. 11 | 12 | 13 | #include 14 | 15 | void setup() { 16 | Wire.begin(8); // join i2c bus with address #8 17 | Wire.onRequest(requestEvent); // register event 18 | } 19 | 20 | void loop() { 21 | delay(100); 22 | } 23 | 24 | // function that executes whenever data is requested by master 25 | // this function is registered as an event, see setup() 26 | void requestEvent() { 27 | Wire.write("hello "); // respond with message of 6 bytes 28 | // as expected by master 29 | } 30 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/keywords.txt: -------------------------------------------------------------------------------- 1 | ####################################### 2 | # Syntax Coloring Map For Wire 3 | ####################################### 4 | 5 | ####################################### 6 | # Datatypes (KEYWORD1) 7 | ####################################### 8 | 9 | ####################################### 10 | # Methods and Functions (KEYWORD2) 11 | ####################################### 12 | 13 | begin KEYWORD2 14 | setClock KEYWORD2 15 | beginTransmission KEYWORD2 16 | endTransmission KEYWORD2 17 | requestFrom KEYWORD2 18 | send KEYWORD2 19 | receive KEYWORD2 20 | onReceive KEYWORD2 21 | onRequest KEYWORD2 22 | 23 | ####################################### 24 | # Instances (KEYWORD2) 25 | ####################################### 26 | 27 | Wire KEYWORD2 28 | 29 | ####################################### 30 | # Constants (LITERAL1) 31 | ####################################### 32 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/library.properties: -------------------------------------------------------------------------------- 1 | name=Wire 2 | version=1.0 3 | author=Arduino 4 | maintainer=Arduino 5 | sentence=Allows the communication between devices or sensors connected via Two Wire Interface Bus. For all Arduino boards, BUT Arduino DUE. 6 | paragraph= 7 | category=Communication 8 | url=http://www.arduino.cc/en/Reference/Wire 9 | architectures=avr 10 | -------------------------------------------------------------------------------- /digistump-avr/libraries/Wire/src/twi.h: -------------------------------------------------------------------------------- 1 | /* 2 | twi.h - TWI/I2C library for Wiring & Arduino 3 | Copyright (c) 2006 Nicholas Zambetti. All right reserved. 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | */ 19 | #ifdef TWDR 20 | #ifndef twi_h 21 | #define twi_h 22 | 23 | #include 24 | 25 | //#define ATMEGA8 26 | 27 | #ifndef TWI_FREQ 28 | #define TWI_FREQ 100000L 29 | #endif 30 | 31 | #ifndef TWI_BUFFER_LENGTH 32 | #define TWI_BUFFER_LENGTH 32 33 | #endif 34 | 35 | #define TWI_READY 0 36 | #define TWI_MRX 1 37 | #define TWI_MTX 2 38 | #define TWI_SRX 3 39 | #define TWI_STX 4 40 | 41 | void twi_init(void); 42 | void twi_disable(void); 43 | void twi_setAddress(uint8_t); 44 | void twi_setFrequency(uint32_t); 45 | uint8_t twi_readFrom(uint8_t, uint8_t*, uint8_t, uint8_t); 46 | uint8_t twi_writeTo(uint8_t, uint8_t*, uint8_t, uint8_t, uint8_t); 47 | uint8_t twi_transmit(const uint8_t*, uint8_t); 48 | void twi_attachSlaveRxEvent( void (*)(uint8_t*, int) ); 49 | void twi_attachSlaveTxEvent( void (*)(void) ); 50 | void twi_reply(uint8_t); 51 | void twi_stop(void); 52 | void twi_releaseBus(void); 53 | 54 | #endif 55 | #endif 56 | -------------------------------------------------------------------------------- /digistump-avr/variants/digispark/pins_arduino.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/digistump-avr/variants/digispark/pins_arduino.c -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.6.8.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.6.8.zip -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.7.0.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.7.0.zip -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.7.1.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.7.1.zip -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.7.2.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.7.2.zip -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.7.3.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.7.3.zip -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.7.4.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.7.4.zip -------------------------------------------------------------------------------- /framework-arduino-avr-digistump-1.7.5.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/framework-arduino-avr-digistump-1.7.5.zip -------------------------------------------------------------------------------- /pictures/Bootloader2.5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/pictures/Bootloader2.5.jpg -------------------------------------------------------------------------------- /pictures/Digistump1.6.8.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/pictures/Digistump1.6.8.jpg -------------------------------------------------------------------------------- /pictures/Micronucleus_Burn_Bootloader.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/pictures/Micronucleus_Burn_Bootloader.jpg -------------------------------------------------------------------------------- /tools/Digistump_Drivers/DPinst.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/DPinst.exe -------------------------------------------------------------------------------- /tools/Digistump_Drivers/DPinst64.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/DPinst64.exe -------------------------------------------------------------------------------- /tools/Digistump_Drivers/Digispark_Bootloader.cat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/Digispark_Bootloader.cat -------------------------------------------------------------------------------- /tools/Digistump_Drivers/Digispark_Bootloader.inf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/Digispark_Bootloader.inf -------------------------------------------------------------------------------- /tools/Digistump_Drivers/Digistump.Drivers.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/Digistump.Drivers.zip -------------------------------------------------------------------------------- /tools/Digistump_Drivers/amd64/libusb0.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/amd64/libusb0.dll -------------------------------------------------------------------------------- /tools/Digistump_Drivers/amd64/libusb0.sys: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/amd64/libusb0.sys -------------------------------------------------------------------------------- /tools/Digistump_Drivers/amd64/libusbK.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/amd64/libusbK.dll -------------------------------------------------------------------------------- /tools/Digistump_Drivers/amd64/lowcdc.sys: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/amd64/lowcdc.sys -------------------------------------------------------------------------------- /tools/Digistump_Drivers/digiserial.cat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/digiserial.cat -------------------------------------------------------------------------------- /tools/Digistump_Drivers/post_install.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | echo Detecting OS processor type 3 | echo Launching Driver Installer 4 | 5 | @echo off 6 | if "%PROCESSOR_ARCHITECTURE%" == "AMD64" ( 7 | DPinst64.exe 8 | rem check the processor achitecture from within a 32 bit program/installer running on a 64 bis system 9 | ) ELSE IF "%PROCESSOR_ARCHITEW6432%" == "AMD64" ( 10 | DPinst64.exe 11 | ) ELSE ( 12 | DPinst.exe %ARGS% 13 | ) 14 | -------------------------------------------------------------------------------- /tools/Digistump_Drivers/readme.txt: -------------------------------------------------------------------------------- 1 | Install_Digistump_Drivers.bat just executes DPinst64.exe or DPinst.exe according to your operating system. 2 | DigiUSB.inf and DigiX.inf are not longer contained in this version, since they seem to be useless for Windows 10. -------------------------------------------------------------------------------- /tools/Digistump_Drivers/x86/libusb0.sys: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/x86/libusb0.sys -------------------------------------------------------------------------------- /tools/Digistump_Drivers/x86/libusb0_x86.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/x86/libusb0_x86.dll -------------------------------------------------------------------------------- /tools/Digistump_Drivers/x86/libusbK_x86.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/x86/libusbK_x86.dll -------------------------------------------------------------------------------- /tools/Digistump_Drivers/x86/lowcdc.sys: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/Digistump_Drivers/x86/lowcdc.sys -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-aarch64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-aarch64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-arm-linux-gnueabihf.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-arm-linux-gnueabihf.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-i686-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-i686-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-i686-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-i686-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-aarch64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-aarch64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-arm-linux-gnueabihf.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-arm-linux-gnueabihf.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-i686-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-i686-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-i686-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-i686-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-x86_64-apple-darwin.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-x86_64-apple-darwin.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-x86_64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-x86_64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-pio-x86_64-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-pio-x86_64-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-x86_64-apple-darwin.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-x86_64-apple-darwin.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-x86_64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-x86_64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.5-x86_64-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.5-x86_64-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-aarch64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-aarch64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-arm-linux-gnueabihf.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-arm-linux-gnueabihf.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-i686-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-i686-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-i686-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-i686-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-aarch64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-aarch64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-arm-linux-gnueabihf.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-arm-linux-gnueabihf.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-i686-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-i686-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-i686-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-i686-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-x86_64-apple-darwin.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-x86_64-apple-darwin.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-x86_64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-x86_64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-pio-x86_64-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-pio-x86_64-mingw32.zip -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-x86_64-apple-darwin.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-x86_64-apple-darwin.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-x86_64-linux-gnu.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-x86_64-linux-gnu.tar.gz -------------------------------------------------------------------------------- /tools/micronucleus-cli-2.6-x86_64-mingw32.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ArminJo/DigistumpArduino/e4991379b73919a3798febb5446027422e6a74b3/tools/micronucleus-cli-2.6-x86_64-mingw32.zip --------------------------------------------------------------------------------