Skip to content

Commit b180f33

Browse files
committed
fixed wrong location for call to mapResolution(), doc updates
1 parent b9aa95d commit b180f33

File tree

3 files changed

+11
-9
lines changed

3 files changed

+11
-9
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -527,10 +527,10 @@ Vista, 7, 8, and 10. Note that the Windows 10 generic CDC drivers work as well.
527527
*OS X support was added in version 1.6.7-beta-b0.*
528528

529529
0. No driver installation is needed.
530-
5. Plug in the board. You may get a dialog box asking if you wish to open the “Network Preferences”:
530+
1. Plug in the board. You may get a dialog box asking if you wish to open the “Network Preferences”:
531531
* Click the "Network Preferences..." button, then click "Apply".
532532
* The board will show up as “Not Configured”, but it will work fine.
533-
5. Continue with SAM M0+ Core Installation below.
533+
2. Continue with SAM M0+ Core Installation below.
534534

535535

536536
### SAM M0+ Core Installation
@@ -539,14 +539,14 @@ Vista, 7, 8, and 10. Note that the Windows 10 generic CDC drivers work as well.
539539

540540
* To update from a previous version, click on MattairTech SAM M0+ Boards in Boards Manager, then click Update.
541541

542-
1. The MattairTech SAM M0+ Core requires Arduino 1.6.7 or above (including 1.8.x).
542+
1. The MattairTech SAM M0+ Core requires Arduino IDE 1.6.7 or above (including 1.8.x).
543543
2. In the Arduino IDE, click File->Preferences.
544544
3. Click the button next to Additional Boards Manager URLs.
545545
4. Add https://www.mattairtech.com/software/arduino/package_MattairTech_index.json.
546546
5. Save preferences, then open the Boards Manager.
547547
6. Install the Arduino SAMD Boards package. Use version 1.6.2 or higher.
548548
7. Install the MattairTech SAM M0+ Boards package.
549-
8. Close Boards Manager, then click Tools->Board->MattairTech MT-D21E (or MT-D11).
549+
8. Close Boards Manager, then click Tools->Board->(choose board).
550550
9. Select the MCU with the now visible Tools->Microcontroller menu (if present).
551551
10. If you do not already have the bootloader or blink sketch installed, see SAM-BA USB CDC Bootloader below.
552552
11. Plug in the board. The blink sketch should be running.

bootloaders/zero/README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -254,13 +254,15 @@ This driver is the same as the one used by the MattairTech SAM M0+ Core.
254254
4. Continue with driver installation above.
255255

256256

257-
### Bossac Utility Installation
257+
### Bossac Utility
258258

259-
This version of the bootloader requires bossac (1.7.0-mattairtech-1) from the package "MattairTech SAM M0+ Boards".
260-
If using the Arduino IDE to upload firmware, then download the core.
259+
This version of the bootloader requires bossac (1.7.0-mattairtech-1) or above.
261260

262261
**See the MattairTech SAM M0+ Core [README.md](https://github.com/mattairtech/ArduinoCore-samd/tree/master/README.md) "Driver Installation" for installation instructions.).**
263262

263+
#### Bossac Utility Installation
264+
265+
If using the Arduino IDE to upload firmware, then this will be installed automatically when intalling the core.
264266
If using Bossac standalone, download bossac directly at:
265267

266268
* https://www.mattairtech.com/software/arduino/bossac-1.7.0-mattairtech-1-mingw32.tar.gz (Windows 32 bit and 64 bit)

cores/arduino/wiring_analog.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,8 @@ void analogWrite(uint32_t pin, uint32_t value)
354354
timerIndex = (uint8_t)(((uint32_t)TCCx - (uint32_t)TCC0) >> 10);
355355
}
356356

357+
value = mapResolution(value, _writeResolution, 16);
358+
357359
if (!tcEnabled[timerIndex]) {
358360
tcEnabled[timerIndex] = true;
359361

@@ -365,8 +367,6 @@ void analogWrite(uint32_t pin, uint32_t value)
365367
while ( GCLK->SYNCBUSY.reg & GCLK_SYNCBUSY_MASK );
366368
#endif
367369

368-
value = mapResolution(value, _writeResolution, 16);
369-
370370
// Set PORT
371371
if ( TCx )
372372
{

0 commit comments

Comments
 (0)