From adebe9cd1f00275eabb5eff1dea3902803c9fb38 Mon Sep 17 00:00:00 2001 From: cpldcpu Date: Sun, 16 Mar 2014 17:57:32 +0100 Subject: firmware: config update t841,t85 --- firmware/configuration/t841_default/bootloaderconfig.h | 15 +++++++++++---- .../configuration/t85_aggressive/bootloaderconfig.h | 17 ++++++++++++----- firmware/configuration/t85_default/Makefile.inc | 8 ++++---- firmware/configuration/t85_default/bootloaderconfig.h | 17 +++++++++++------ firmware/main.c | 2 +- 5 files changed, 39 insertions(+), 20 deletions(-) diff --git a/firmware/configuration/t841_default/bootloaderconfig.h b/firmware/configuration/t841_default/bootloaderconfig.h index 8930bcc..4a6a148 100644 --- a/firmware/configuration/t841_default/bootloaderconfig.h +++ b/firmware/configuration/t841_default/bootloaderconfig.h @@ -1,11 +1,18 @@ /* Name: bootloaderconfig.h * Micronucleus configuration file. - * This file (together with some settings in Makefile) configures the boot loader + * This file (together with some settings in Makefile.inc) configures the boot loader * according to the hardware. * - * Controller type: ATtiny 85 - * Configuration: Digispark default configuration. - * Last Change: Feb 21,2014 + * Controller type: ATtiny 841 - 12 MHz + * Configuration: Default configuration + * USB D- : PB0 + * USB D+ : PB1 + * Entry : Always + * LED : PB2, Active Low + * OSCCAL : Revert to precalibrated value (8 MHz) + * Note: can use 12 MHz V-USB without PLL due to stable RC-osc in ATTiny841 + * Flash write time may be too + * Last Change: Mar 16,2014 * * License: GNU GPL v2 (see License.txt */ diff --git a/firmware/configuration/t85_aggressive/bootloaderconfig.h b/firmware/configuration/t85_aggressive/bootloaderconfig.h index 0613d79..805d332 100644 --- a/firmware/configuration/t85_aggressive/bootloaderconfig.h +++ b/firmware/configuration/t85_aggressive/bootloaderconfig.h @@ -1,15 +1,22 @@ -/* Name: bootloaderconfig.h + /* Name: bootloaderconfig.h * Micronucleus configuration file. - * This file (together with some settings in Makefile) configures the boot loader + * This file (together with some settings in Makefile.inc) configures the boot loader * according to the hardware. * - * Controller type: ATtiny 85 - * Configuration: Size optimized. Uses 16 MHz V-USB implementation, which may be instable with some computers + * Controller type: ATtiny 85 - 16 MHz + * Configuration: Aggresively size optimized configuration + * USB D- : PB3 + * USB D+ : PB4 + * Entry : Always + * LED : None + * OSCCAL : Stays at 16 MHz + * Note: Uses 16 MHz V-USB implementation. + * Worked reliable in all tests, but is possibly less stable then 16.5M Hz Implementation with PLL * Last Change: Mar 16,2014 * * License: GNU GPL v2 (see License.txt */ - + #ifndef __bootloaderconfig_h_included__ #define __bootloaderconfig_h_included__ diff --git a/firmware/configuration/t85_default/Makefile.inc b/firmware/configuration/t85_default/Makefile.inc index d933082..53a4682 100644 --- a/firmware/configuration/t85_default/Makefile.inc +++ b/firmware/configuration/t85_default/Makefile.inc @@ -1,12 +1,12 @@ # Name: Makefile # Project: Micronucleus # License: GNU GPL v2 (see License.txt) -# -# Controller type: ATtiny 85 -# Configuration: Digispark default configuration. + +# Controller type: ATtiny 85 - 16.5 MHz +# Configuration: Default # Last Change: Mar 16,2014 - + F_CPU = 16500000 DEVICE = attiny85 diff --git a/firmware/configuration/t85_default/bootloaderconfig.h b/firmware/configuration/t85_default/bootloaderconfig.h index 4ea59dd..32beedf 100644 --- a/firmware/configuration/t85_default/bootloaderconfig.h +++ b/firmware/configuration/t85_default/bootloaderconfig.h @@ -1,15 +1,20 @@ /* Name: bootloaderconfig.h * Micronucleus configuration file. - * This file (together with some settings in Makefile) configures the boot loader + * This file (together with some settings in Makefile.inc) configures the boot loader * according to the hardware. * - * Controller type: ATtiny 85 - * Configuration: Digispark default configuration. - * Last Change: Feb 21,2014 + * Controller type: ATtiny 85 - 16.5 MHz + * Configuration: Default configuration + * USB D- : PB3 + * USB D+ : PB4 + * Entry : Always + * LED : None + * OSCCAL : Stays at 16 MHz + * Note: Uses 16.5 MHz V-USB implementation with PLL + * Last Change: Mar 16,2014 * * License: GNU GPL v2 (see License.txt */ - #ifndef __bootloaderconfig_h_included__ #define __bootloaderconfig_h_included__ @@ -200,7 +205,7 @@ * */ -#define LED_MODE ACTIVE_HIGH +#define LED_MODE NONE #define LED_DDR DDRB #define LED_PORT PORTB diff --git a/firmware/main.c b/firmware/main.c index 8a86b33..63979ac 100644 --- a/firmware/main.c +++ b/firmware/main.c @@ -181,7 +181,7 @@ static uint8_t usbFunctionSetup(uint8_t data[8]) { static void initHardware (void) { // Disable watchdog and set timeout to maximum in case the WDT is fused on -#ifdef WDTCSR +#ifdef CCP // New ATtinies841/441 use a different unlock sequence and renamed registers MCUSR=0; CCP = 0xD8; -- cgit v1.2.3