You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 957c9fd
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: Installation.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@ If you use an alternative development environment, be aware that no official tes
13
13
14
14
Of course, bugs in that are discovered in PlatformIO or VisualMicro, but also reproduce on Arduino IDE are normal bugs, and can be reported without that additional requirement!
This board package can be installed via the board manager. The boards manager URL is:
19
19
@@ -25,7 +25,7 @@ This board package can be installed via the board manager. The boards manager UR
25
25
4. Select "megaTinyCore by Spence Konde" and click "Install". For best results, choose the most recent version.
26
26
27
27
## Manual Installation
28
-
Manual installation allows the latest version of the core to be installed, with fixes that may not yet be available in the board manager version of the core. Manual installation is recommended if you are working on developing or modifying the core - however, the reqirements are brutal.
28
+
Manual installation allows the latest version of the core to be installed, with fixes that may not yet be available in the board manager version of the core. Manual installation is recommended if you are working on developing or modifying the core - however, the requirements are brutal.
29
29
30
30
* You must be using a copy of the Arduino IDE that has never had an AVR board definition package installed on it (typically this means the .zip archive, extract, and create a portable folder inside before first run)
31
31
* You must update the toolchain. Search the .json file above `"tools": [` Of the 4 hits, you're looking for the avr-gcc one.
@@ -36,7 +36,7 @@ Manual installation allows the latest version of the core to be installed, with
36
36
* Copy this into `arduino root folder)/hardware/tools` - if you did this right, you'll be told that hundreds of files are different. Replace them all!
37
37
***NOTE:** if you also intend to use DxCore manually installed, check the json entries for that one too, and see if it specifies a later toolchain version. Use whichever one has higher version (Azduinio4 is higher than Azduino3)
38
38
39
-
* If you want SerialUPFI, you need to also follow [megaavr/tools/ManualPython.md](megaavr/tools/ManualPython.md).
39
+
* If you want SerialUPDI, you need to also follow [megaavr/tools/ManualPython.md](megaavr/tools/ManualPython.md).
40
40
41
41
Once that all is done, you've only got a minor step or two left - you need to create a "hardware" folder inside the sketchbook folder (inside portable assuming you went that route, which you should) amd then and only then should you install the core.
Copy file name to clipboardExpand all lines: megaavr/extras/ATtiny_x02.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -56,10 +56,10 @@ The tuned options are new in 2.4.0 - see the [tuned internal oscillator guide](R
56
56
This matches the megaTinyCore 412/402 Rev. - and Rev. A breakout boards below. **In 2.0.0 and later, this is no longer the case!** You must call Serial.swap(1) prior to Serial.begin() to move it to the alt pins (or connect your adapter to pins 0 and 1 instead of 2 and 3). It should never have been done that way in the first place. A Rev. B of the breakout boards that has the FTDI header tied to the standard serial pins is planned for availability in May 2020.
57
57
58
58
## Signature Issue
59
-
There exist ATtiny402's in the wild where the last byte of the signature is 0x25, instead of 0x27. Currently shipping parts from Atmel/Microchip have the correct signature, and this problem appears to be in the past, for the most part. Hoerver, if you're stuck with wrong-signature ATtiny402's, choose ATtiny402 (bad signature) from the tools -> chip menu.
59
+
There exist ATtiny402's in the wild where the last byte of the signature is 0x25, instead of 0x27. Currently shipping parts from Atmel/Microchip have the correct signature, and this problem appears to be in the past, for the most part. However, if you're stuck with wrong-signature ATtiny402's, choose ATtiny402 (bad signature) from the tools -> chip menu.
60
60
61
61
## The issue with bootloader
62
-
* There's no dedicated reset pin. So there is no way to do the traditional autoreset circuit to reset the chip to upload with a bootloader unless you disable UPDI (requiring HV UPDI to undo - I've got a half dozen boards that are bricked until I have time to get an HVUPDI programming setup together to resurrect them). Either you manually power cycle it just prior to trying to upload, or you have some sort of ersatz-reset solution coupled to an autoreset circuit, or handle it in some other bespoke way. Regardless of the approach, short of disabling UPDI to get a reset pin, none of them are as convenient a development cycle as we're used to. In most cases, the most convenient development configuration is to simply use UPDI programming, and leave any serial connection open while programming via UPDI using a programmer on a different port. Note that the 2-series 20 and 24 pin parts have enhancements that make a bootloader capabloe of providing a better developer experience possible.
62
+
* There's no dedicated reset pin. So there is no way to do the traditional autoreset circuit to reset the chip to upload with a bootloader unless you disable UPDI (requiring HV UPDI to undo - I've got a half dozen boards that are bricked until I have time to get an HVUPDI programming setup together to resurrect them). Either you manually power cycle it just prior to trying to upload, or you have some sort of ersatz-reset solution coupled to an autoreset circuit, or handle it in some other bespoke way. Regardless of the approach, short of disabling UPDI to get a reset pin, none of them are as convenient a development cycle as we're used to. In most cases, the most convenient development configuration is to simply use UPDI programming, and leave any serial connection open while programming via UPDI using a programmer on a different port. Note that the 2-series 20 and 24 pin parts have enhancements that make a bootloader capable of providing a better developer experience possible.
63
63
* It takes 512b of flash - 1/4th or 1/8th of the total, but offers little, if any, advantages.
64
64
65
65
## Buy official megaTinyCore breakouts and support continued development
Bootloader(optional) | Optiboot (No! Don't waste a quarter of the flash!) | Optiboot (strongly not recommended due to size) | Optiboot (awkard but viable, not recommended) | Optiboot (awkard but viable, not recommended)
10
+
Bootloader(optional) | Optiboot (No! Don't waste a quarter of the flash!) | Optiboot (strongly not recommended due to size) | Optiboot (awkward but viable, not recommended) | Optiboot (awkward but viable, not recommended)
Bootloader (optional) | Optiboot (absolutely not recommended) | Optiboot (not recommended)| Optiboot (awkard but viable, not recommended) | Optiboot (awkard but viable, not recommended)
10
+
Bootloader (optional) | Optiboot (absolutely not recommended) | Optiboot (not recommended)| Optiboot (awkward but viable, not recommended) | Optiboot (awkward but viable, not recommended)
Copy file name to clipboardExpand all lines: megaavr/extras/Errata.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ Microcontrollers, like any other product, often have bugs which are discovered o
4
4
5
5
Well, for the tinyAVR 0/1-series, the list of issues is a tiny bit longer. By which I mean, the index of errata is longer than the entire errata section of most classic AVRs - likely because these were some of the first parts released with many of the new peripherals (though the megaAVR 0-series had come out slightly earlier, the 1-series had many peripherals not featured in the megaAVR 0-series, and where a peripheral was on both series, it is broken the same way over there too).
6
6
7
-
The lists of errata are ~hidden~ located in a separate docukent, the "Errata and datasheet clarification" sheet for the part now, instead of being in the datasheet proper like it was on classic AVRs. You know, just to make it easier for the users, so we don't have to skip over a few pages of highly relevant information on errata if we have one of the non-existent versions that doesn't have all these problems. Nope, they're *totally* not trying to hush up the bugs until you've made the buying decision and gotten too deep in the design process to switch MCUs to a competitors' one or anything, nosiree - it's just to make things easier you you, the users! The specific errata relevant to a given part vary depending on the specific part and and silicon revision. The silicon revision can be read from the `SYSCFG.REVID` register (0 = A, 1 = B, etc). It is also marked on the chip - though my understanding is that us mere mortals are not trusted with the secret of how to do so, and must have Microchip folks help with that.
7
+
The lists of errata are ~hidden~ located in a separate document, the "Errata and datasheet clarification" sheet for the part now, instead of being in the datasheet proper like it was on classic AVRs. You know, just to make it easier for the users, so we don't have to skip over a few pages of highly relevant information on errata if we have one of the non-existent versions that doesn't have all these problems. Nope, they're *totally* not trying to hush up the bugs until you've made the buying decision and gotten too deep in the design process to switch MCUs to a competitors' one or anything, no siree - it's just to make things easier you you, the users! The specific errata relevant to a given part vary depending on the specific part and and silicon revision. The silicon revision can be read from the `SYSCFG.REVID` register (0 = A, 1 = B, etc). It is also marked on the chip - though my understanding is that us mere mortals are not trusted with the secret of how to do so, and must have Microchip folks help with that.
8
8
9
9
Note that Rev. C of the 32k parts has been released and fixes a substantial amount of errata. It fixes some of the RTC stuff, it fixes the
10
10
D-latch and the fact that you had to enable pin output to use the link output source on a downstream LUT as well as assorted other issues. Hopefully we will see these changes brought to other parts in the tinyAVR 0/1-series in the future.
@@ -14,11 +14,11 @@ Serial.print("Silicon revision is: ");
14
14
Serial.println(SYSCFG.REVID);
15
15
```
16
16
17
-
Thankfully, most of these issues will not be encountered by most Arduino users. The impact column indicates the liklihood that someone working with an effected part through megaTinyCore and Arduino would encounter it.
17
+
Thankfully, most of these issues will not be encountered by most Arduino users. The impact column indicates the likelihood that someone working with an effected part through megaTinyCore and Arduino would encounter it.
18
18
* 0 - Impact unlikely and non-serious if it does occur.
19
-
* 1 - Impact unlikely to cause issue or degrade functionality under ordinary conditions. Things that can only manifest under extreme corner cases are usaually in this category. There are usually a number of approaches to working around these, as well,
19
+
* 1 - Impact unlikely to cause issue or degrade functionality under ordinary conditions. Things that can only manifest under extreme corner cases are usually in this category. There are usually a number of approaches to working around these, as well,
20
20
* 2 - Impact likely when using features that are not particularly exotic, but has viable workaround and is not visible through the API provided by the core. This includes cases where the feature is inoperable but the workaround is truly trivial.
21
-
* 3 - Issue impacted functions provided by megaTinyCore or included libraries in previous versions, but worked around in current version, and will impact users of this functionality if reconfigured manually, or unavoidably impacts functionality exposed by core or included libraries, but can be worked around with little overall mipact..
21
+
* 3 - Issue impacted functions provided by megaTinyCore or included libraries in previous versions, but worked around in current version, and will impact users of this functionality if reconfigured manually, or unavoidably impacts functionality exposed by core or included libraries, but can be worked around with little overall impact..
22
22
* 4 - Issue has a large impact on the relevant functionality in configurations other than the most common ones, without requiring an exotic corner case to trigger. In cases where the impacted features are exposed by the core or included libraries, it may not be possible to hide the issue.
23
23
* 5 - Issue has a large impact on the relevant functionality in all or the most common configurations. If that is provided by the core or library, we may be unable to hide the issue. If it involves manual configuration, that functionality will be completely and totally unusable without workarounds, and those may not hide it entirely.
24
24
*`*` - Issue is high impact but effected devices are rare
@@ -400,7 +400,7 @@ Event detection will fail if TCBn receives an input event with a high/low period
400
400
401
401
**Workaround:** Read both `TCBn.CCMPL` and `TCBn.CCMPH`.
402
402
403
-
**megaTinyCore note:** Only impacts users who reconfigure a Type B timer for input capture, but only cares about the low byte, not the high byte, and doesn't immediately recognize that when running into the bug that the interrupt flag isn't getting cleared and clear it manually (which is the most obvious cause and something to check first whenever sketch activity nearly hangs as soon as an interrupt is triggered, especially if it's only "nearly" hung). In addition to the suggested workaround of reading both bytes, you can also just manually clear the interrupt flag. Under typical conditions, whether you readthe second byte or manually clear the flag will have the same run time - but manually clearing it will typically take 3 extra words of flash, while reading it will only take 1. `uint8_t val=TCBn.CCMP`will generate correct code.
403
+
**megaTinyCore note:** Only impacts users who reconfigure a Type B timer for input capture, but only cares about the low byte, not the high byte, and doesn't immediately recognize that when running into the bug that the interrupt flag isn't getting cleared and clear it manually (which is the most obvious cause and something to check first whenever sketch activity nearly hangs as soon as an interrupt is triggered, especially if it's only "nearly" hung). In addition to the suggested workaround of reading both bytes, you can also just manually clear the interrupt flag. Under typical conditions, whether you read the second byte or manually clear the flag will have the same run time - but manually clearing it will typically take 3 extra words of flash, while reading it will only take 1. `uint8_t val=TCBn.CCMP`will generate correct code.
404
404
405
405
#### TCB Input Capture Frequency and Pulse-Width Measurement Mode Not Working with Prescaled
406
406
Clock The TCB Input Capture Frequency and Pulse-Width Measurement mode may lock to Freeze state if CLKSEL in
@@ -496,7 +496,7 @@ A false start bit detection will trigger if receiving a frame with `RXDATAH.FERR
496
496
497
497
**Workaround:** Wait for the RXD pin to go high before reading RXDATA, for instance, by polling the bit in `PORTn.IN` where the RXD
498
498
pin is located.
499
-
**megaTinyCore note:** This, technically, impacts our serial implementation on effected parts. However, if you are receiving framing errors, the baud rates or port settings are wrong on one or both side - so instead of receiving one byte of garbage, you'd receive two bytes of slightly different garbage. I do not believe there are cases where this can result in data that would have otherwise been inteligible coming out as garbage short of a transient framing error in a long string of continuous data, where it never has a change to regain it's bearings.
499
+
**megaTinyCore note:** This, technically, impacts our serial implementation on effected parts. However, if you are receiving framing errors, the baud rates or port settings are wrong on one or both side - so instead of receiving one byte of garbage, you'd receive two bytes of slightly different garbage. I do not believe there are cases where this can result in data that would have otherwise been intelligible coming out as garbage short of a transient framing error in a long string of continuous data, where it never has a change to regain it's bearings.
500
500
501
501
#### Open-Drain Mode Does Not Work When TXD is Configured as Output
502
502
When the USART TXD pin is configured as an output, it can drive the pin high regardless of whether the Open-Drain mode is enabled or not.
0 commit comments