Coder Social home page Coder Social logo

asf4's Introduction

asf4 - Microchip/Atmel ASF4 Code Libraries

http://start.atmel.com is the way to access the ASF4 code libraries from Microchip. It is a code selection tool: you specify the libraries you need and some parameters, and then you download a package of code for your selected chip and application.

Since we need to support multiple chips and use a large chunk of the library, the scheme above is awkward, and it's difficult to update cleanly.

This repo contains a code tree of a large selection of ASF4 code, downloaded for both SAMD21 and SAMD51 (and more chips later).

Branches

Master Branch

Branch master contains the code as downloaded, with very minor adjustments (see below). It should be updated periodically. As of this writing there is no way to know when the code is updated on the website, so we must check periodically.

Note that a few files are moved to different locations to regularize the different chip trees. See tools/update _from_atmel_start.py for details.

Bugfix Branch

Branch master-bugfixes is a branch from master that contains bugfixes needed by potentially all users of ASF4.

Project Branches

These branches contain enhancements for specific Adafruit projects and families of products. A project would typically use a git submodule that points to commits in its project branch.

Tools

tools/ contains scripts that are useful for updating and organizing the code trees.

asf4's People

Contributors

dhalbert avatar sommersoft avatar tannewt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

asf4's Issues

ASF4 - Astart file up to date?

Hello

I don't know if this is an issue, a problem with my understanding of Atmel Start, or some other thing.
In the Adafruit asf4 repository /SAMD51 there is an file

"atmel_start_config.atstart"

I assume this is the source for Atmel Start to produce the other files, however, when I go to start.atmel.com and load atmel_start_config.atstart, the resulting clock configuration is "strange" if you look at in in Atmel Start. When I subsequently export the project I get completely different files. Most of the differences are immaterial (copyright notices) but several important files (hpl_gclk.c, hpl_osc32kctrl.c, hpl_oscctrl.c, and others) seem to be somewhat different.

Many of these differences are likely Atmel bug fixes, however, it is possible that the atmel_start_config.atstart file is obsolete or perhaps Start is parsing it differently.

I have a problem in that I hang at a hri_gclk_wait_for_sync(hw, GCLK_SYNCBUSY_SWRST); in hri_glck_d51.h and these "... wait_for_sync(" calls are no present in the Adafruit files.

I suspect my problem is that the clock configuration produced by Atmel Start is wrong. I was wondering if there was an update version of the .astart file or even this repository.

Thanks

LITTLE_ENDIAN is commented out in some devices, not others (and causes errors while building)

All of the samd21 files in samd21/include have a "#define LITTLE_ENDIAN 1", but some of them have it commented out (samd21e18a.h, samd21g18a.h, samr21g18a.h).

When I tried to build for a different device (a SAMD21J18A), the fact that it wasn't commented out caused build errors:

In file included from asf4/samd21/include/sam.h:58:0,
from ./mpconfigport.h:31,
from ../../py/mpconfig.h:45,
from ../../py/gc.h:31,
from ../../py/gc.c:31:
asf4/samd21/include/samd21j18a.h:228:0: error: "LITTLE_ENDIAN" redefined [-Werror]
#define LITTLE_ENDIAN 1

In file included from /usr/include/newlib/sys/types.h:67:0,
from /usr/include/newlib/stdio.h:61,
from ../../py/gc.c:28:
/usr/include/newlib/machine/endian.h:17:0: note: this is the location of the previous definition
#define LITTLE_ENDIAN _LITTLE_ENDIAN

cc1: all warnings being treated as errors

I commented it out in the samd21j18a.h file, and (after fixing separate issues in samd-peripherals) it built fine. But I'm not sure if the right solution is just commenting it out everywhere here?

add support for samd21g17d

I am trying to port micropython to this Microchip device in the samd21 family.
I have manually added the needed device files to this asf4 library. I would like to contribute these changes to your project, but am not sure how to proceed. (I use git branches and pull requests at work with bitbucket so am familiar with the general pull request process)
If you are interested I I will create a fork of this repo and commit my changes there and then look at creating a pull request.

Since i did not use your atmel start tool flow I wasn't sure if you would want e edits?

ASF4 for SAMR34 for circuitpython and makecode

Hi @tannewt

we are trying to port the SAMR34 to circuitpython, but I could not find the corresponding ASF4 in Atmel START for SAMR34

Can you help me know where to find it?

I see the ATMEL SMART discontinued, SAMR34 is similar to SAML21, could I use that version?

or which way do you recommend me?

a bit of the work we have done with SAMR34, using SAML21

Port for UF2: microsoft/uf2-samdx1#83

Port for UF2 samd: microsoft/uf2#21

Arduino Core : https://github.com/ElectronicCats/Arduino_Boards_Index/tree/gh-pages/electroniccats/samd_advanced/variants/bastwan

c.c: @wero1414

Atmel Start update script still working?

I'm a beginner attemping to port MicroPython to SAME54 (Xplained Pro board).
So I turns out I have to load the required ASF4 stuff for SAME54 to be able to compile.

Is tools/update_from_atmel_start.py still working for everyone else?
I'm getting 502 Bad gateway even for the first target (SAMD21).
In Atmel Studio 7 I am able to create a new START project so the server is probably OK.
I tried changing the URL prefix in the script from http:// to https:// (since in web browser the page start.atmel.com seems to use that), to no avail.

How do I create json file for SAME54?
Now I just copied samd51.json and manually replaced every SAMD51 -> SAME54 and every SAMD51G19A-MF -> SAME54P20A-MF, but is there anoter method to create it? If yes, where is it documented?

What is format_json.py supposed to do? It looks like it just performs some cleanup on json file, is this right?

libwebsockets + asf for atmel SAM4E - mbedtls issue when i try to use minimal lws client

Hi all.
I have just generated Atmel sam4e's libwebsockets.a from libwebsockets project.
I have arrived to test my libwebsockets.a lib. i have some issue to test it as ws-client.
You can see this link for more about adding (mbedtls to lws and add lws to asf ): warmcat/libwebsockets#2025

I have tried to use ws-client when i compile it i got an mbedTLS error:
./lws/include/libwebsockets.h:262:29: fatal error: mbedtls/lws_config.h: No such file or directory
262 | #define MBEDTLS_CONFIG_FILE <mbedtls/lws_config.h>

I need help to compile just a simple ws-client for atmel (sam4e), do you have an idea about the reason for this error ?

All the best

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.