-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introduce Atmel XMEGA CPU #15703
Comments
This sounds very reasonable to me. IMO it would be the easiest to just PR the change to get feedback for it.
Can you provide a link for this board? Alternatively (and IMO preferably), would you consider adding the XMEGA-A3BU Xplained as first board for the ATxmega256A3BU MCU? The official evaluation boards are usually as long commercially available as the MCU is not flagged obsolete and are often easy to use for development and debugging due to an integrated programmer/debugger or (as in this case) at least standard debug connectors. As this board is (at least for Atmel/Microchip hardware) not relatively affordable, I could obtain one of these in order to help with testing and reviews. |
Thanks for the feedback @maribu !
Understood! I need read docs to make sure I'll follow procedures when open PR.
This board was developed by me and there is no public link. Attached a PDF for reference.
Sure, no big deal! BTW, I added a missing commit couple minutes ago at introduce_avr8_xmega. It reworks a little bit the context switch and thread stack init. With that, I hope, all AVR-8 will work without looking any device itself. |
Hi @maribu, I noted that exists XMEGA-A1U Xplained Pro board. With this, you have access to a CDC COM port and a debugger. I believe it will be easier to test XMEGA with A1 instead A3BU. Do you think it will be better introduce XMEGA-A1U Xplained Pro board first? |
That board would be indeed better. Note however that this is a different MCU - but without having read either datasheet I would guess the difference is mostly the available memory. If that is true, this would indeed be easier to work with :-) |
Yep, it is true! The differences in a practical term: only A1(U) variant have RAMPD, RAMPDX and RAMPDY registers to address more than 64k data. I think it'll not be an issue since I already have both A1/A3 variants working with RIOT-OS. |
Folks! I just sent an update at introduce_avr8_xmega with XMEGA-A1 Xplained Pro working. The board arrived at this morning and I already validated. for sure XMEGA-A1 Xplained Pro will be the easiest board to develop and test. |
More good news! The xmega_ebi branch allow to test:
I tested with Tutorials/task-06:
|
Hello Folks, I've been working in the USB driver for XMEGA. It still have some small issues but I already have a working version, see below: tests/usbus_cdc_acm_stdio:
CDC-ACM working:
The problems I've been facing are related with some instability. Eventually, there are problems to enumerate and hangs at CDC-ACM, for instance. I believe there is something basic that is missing. Did you know something that allows me to test the firmware FSM from Linux host?
|
@bergzand might have an idea. I'm not really familiar with the USB stack :-( |
Is there any chance RIOT have a sample like this: I believe it uses only a bulk loopback EP. With that, it is possible run the |
One thing that I realize is that below block can be shared between ATxmega and ATmega. There are defines between all models. This change require that ATmega drivers should implement pm_block/unblock when appropriated. The constants SLEEP_SMODE_xxx_gc should be switched to SLEEP_MODE_xxx. With this, PM can be fully enabled for ATmega's too. Lines 50 to 80 in cf194d1
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If you want me to ignore this issue, please mark it with the "State: don't stale" label. Thank you for your contributions. |
Xmega is working on the main tree and the main objective was done! |
Description
I noted that current RIOT-OS doesn't have support for XMEGA CPUs. After some research I found a 2018 version from @Josar, which seams as a good start point.
I adjusted the code and made some rework on atmega_. With that, I could share the fundamental code for both CPUs. These means, ATmega and ATxmega will follow different paths for drivers and configurations but can have the same core, which I named avr8_.
I opened this Feature Request to centralize and collect all missing parts to introduce Xmega support on RIOT-OS.
Useful links
The #15712 is a proposal to split atmega_ into atmega_ and avr8_ to pave the path to introduce atxmega_ and/or attiny_.
The following branch introduce_avr8_xmega add XMEGA-A1 Xplained Pro as a prove of concept using ATxmega128A1U MCU. The work is based on @Josar 's XMEGA branch.
How to evaluate
The first thing is add xplainedpro_pdi programmer at
/etc/avrdude.conf
The port was tested using Tutorials/task-01 executing below command:
I hope this could be good for the project. I had boards with xmega and rf2xx 2.4 and sub-giga radios and would like introduce that boards soon.
CC: @benpicco
The text was updated successfully, but these errors were encountered: