Questions tagged [samd21]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
0answers
49 views

How to program and then flash an ARM SAMD21 baremetal?

I want to make a simple program for a custom board with a SAMD21 core, without using any previously existing framework, like the arduino framework. The code to start with is just a simple main() with ...
0
votes
0answers
27 views

How do I configure the ADC/DMA in Atmel start?

I am working on a project that requires the ADC, and I want to use the DMA.  I have been able to get the adc to work using the sync drivers (I haven't tried async), but when I use the DMA no ...
0
votes
1answer
26 views

Very Noob Question: How to connect Seeeduino Xiao to CR2032 battery holder with switch?

I am planning on soldering together a seeeduino xiao along with an adafruit 20mm Coin Cell Breakout w/On-Off Switch for use in a portable trinket to inject code. Problem is, I've never really done ...
0
votes
0answers
23 views

Issue using TCC3 of microchip SAMD21J in variant file

I am writing variant files for SAMD21J/G/E. I am unable to use TCC3 of SAMD21J/G/E in Variant.cpp for arduino IDE. If it is used Arduino IDE shows error TCC3 undeclared variable whereas, all other ...
0
votes
2answers
128 views

I2C design consideration for several slaves

In an application I have multiple I2C slave devices: display, RTC, and EEPROM. The most crititcal is the RTC, which needs to work 100%. I read that I2C freezes from time to time. At the moment all 3 ...
1
vote
0answers
176 views

Problem SAMD21 : ASF4 USB CDC Echo example cdcdf_acm_write() doesn't allow to send data to usb port

I'm using the USB_CDC Echo Example for Atmel start, for ATSAMD21G18A. the code example runs Ok, but when I try to modify the code in order to send data "Hello World" in the infinity while ...
0
votes
1answer
74 views

Arduino MKR analog maximum frequency input

I know the Arduino ATMega based boards’ maximum reading rate of analog pin is 10kHz but what about MKR Family SAMD21 based boards? I couldn’t find any info for it. I will appreciate your responses
1
vote
1answer
135 views

Considering trying Atmel SAM and have some questions

I've been designing boards with STM32 chips for the last couple of years and my curiosity keeps saying that I should try something in the Atmel SAM line of chips. Most of the time, when someone asks ...
1
vote
0answers
190 views

Is it possible to use internal pullups on SAMD21 when pins are configured for SERCOM (SPI) mode?

According to the datasheet screen clip shown below, the internal pull up/dn configured in the PORT registers is still supposed to work even when the pin is configured for use by the SERCOM/SPI ...
4
votes
2answers
2k views

This ADC code works, but I don't understand why

I have the following code for reading a battery voltage on the ADC on a microcontroller (Atmel SAM D21 to be precise.) The reference voltage is 3.3V and the ADC is reading at 12 bit resolution: ...
0
votes
0answers
22 views

SAMD20/21 development on Ubuntu without IDE

As someone who is trying to break away from high-level APIs for embedded development, I wanted to try out programming Atmel's (or Microchip's) SAMD20 or 21 mcus directly without any IDEs or tools ...
0
votes
0answers
63 views

SAMD21 Xplained pro + Arduino IDE

How can I install board files into the Arduino IDE in order to upload my code to the ATSAMD21 Xplained Pro evaluation board. Can I know how can I do it? I Googled it but I didn't get any correct ...
0
votes
0answers
123 views

Can't upload to SAMD21 over SWD port. Tried Black Magic Probe and Atmel-ICE, Arduino IDE and PlatformIO

I must be missing something here. I’m unable to upload to a SAMD21 microcontroller with either a Black Magic Probe (v2.1) or Atmel-ICE. I have tried using both Arduino IDE and PlatformIO and haven’t ...
2
votes
2answers
207 views

SAMD21 SERCOM / UART problem: cannot enable RX and TX

I've been trying to set up a USART on an ATSAMD21E18A-MU and have been running into issues. Currently, I've narrowed the problem down to the fact that ...
2
votes
0answers
97 views

USB Audio device won't open in windows

I'm working on a simple USB audio input device based on the Microchip/Atmel ATSAMD21. The descriptors identify it as a single channel microphone with a single feature unit for volume control. As I ...
0
votes
1answer
96 views

Change the USB pins on SAMD21

I would like to use the pin mux in the SAMD21 mcu, to set different pins for the USB peripheral. The datasheet makes it sound like it is possible, but is very confusing. datasheet : https://cdn....
0
votes
0answers
56 views

SAMD21G18 not working at 1.8V

I am working with a SAMD21G18 and a custom board based on Sparkfun design and I am using VSC + PlatformIO. Actually I want to run at 1.8V instead of 3.3V. Now, the hardware works well at 3.3V but ...
0
votes
0answers
203 views

understanding bootloader with linker

I'm using chip SAMD21G18 SAM-BA bootloader Bossac code I'm looking at how bootloader works. but found some questions that i cant get an answer for: looking into source code of PC client software (...
0
votes
1answer
99 views

SAMD21J18 abnormal boot

SAMD21J18 in a custom made circuit behaves abnormally as following: Delayed boot time between 2 to 5 seconds randomly Boots on touching the MCU crystal's metal top with a metal pin Boots on touching ...
0
votes
1answer
94 views

Generate unique IP/Mac from samd21 serial

We created 100 custom PCB around the samd21. And I'd like to generate some unique IP/Mac addresses from the Serial number of the samd21. In the datasheet they say the following Each device has a ...
0
votes
1answer
411 views

Atmel SAMD21 DMA Transfer Complete Interrupt not firing

I have configured the SAMD21 peripherals so that incoming audio data from I2S will be copied into a memory buffer with DMA. As the controller allows linked DMA descriptors, I have two descriptors ...
4
votes
2answers
375 views

SAMD21 1μs timer handler taking longer than the timer period?

Before I begin I'd like to mention that I'm relatively new to working with microcontrollers at this low level, so please bear with me. I am trying to use an Adafruit Trinket M0 to process and ...
0
votes
1answer
196 views

ASF SAMD21G18 2x timers usage

im trying to use ASF to schedule repeated tasks. using TC4 and TC5: in atmel start both using generic clock generator 0 (48MHz). both are HAL:DRIVER:Timer driver init.c is generated automatically ...
3
votes
2answers
2k views

SAMD21 - How do I write to NVM fuses?

I'm trying to program the ATSAMD21G18 on Adafruit Feather M0 and over SWD Using a Segger J-Link EDU Nano. When I try to download the program to the chip through Atmel Studio it fails verification at ...
1
vote
0answers
957 views

Adapt existing usb-2 otg device to usb-c but use usb-2 mode

there are number of articles out there, like this one: http://www.ti.com/lit/wp/slly017/slly017.pdf But I'm not super confident in my abilities here so I'm wondering if someone could proof my ...
2
votes
1answer
432 views

ATSAMR21 sleep high current draw

I have an ATSAMR21B18-MZ210PA, which is an ATSAMR21E18 packaged with MX25L2006E flash. The SAMR21 is itself a SAMD21 paired with an AT86RF233 wireless module. So that's a SAMD21 + low power wireless + ...
0
votes
1answer
572 views

difference between CMSIS and ASF

im trying to make c++ project using atmel asf. the compiler have: ...
0
votes
1answer
286 views

Intermittent NVM programming error

Occasionally I'll get the following errors while programming my SAMD21 chip. Anyone know the reason? ...
2
votes
1answer
1k views

SAMD21 DAC example [closed]

beginner here in need for starting directions. I have SAMD21 Xplained Pro Board. I would like to produce DC DAC output, based on 8 bits on the input. Range of my DC output values should be around ...
-2
votes
1answer
496 views

Using Adafruit Trinket M0 (SAMD21) as a USB to Serial converter

I wanted to know if it is possible to use SAMD21 as a USB to Serial converter like the usual FTDI chips ? If yes could you please point how to achieve that. I believe that Adafruit Trinket was used ...
2
votes
3answers
2k views

Combining a bootloader and user program into single flash-able binary

I want to flash the UF2 bootloader for SAMD21 MCUs together with a compiled binary of a user program onto a SAMD21 MCU. From what I understand how any bootloader works, the bootloader sits in a ...