-
-
Notifications
You must be signed in to change notification settings - Fork 39.6k
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
Adds AT90USB162 support #11570
Adds AT90USB162 support #11570
Conversation
Also I forgot to ask, in common_features there's a comment saying ATmegaxxU2 doesn't have a hardware MUL instruction. When checking the avr instruction set they're listed as AVRe+ cores that should have the instruction with the only missing instructions being "ELPM, EIJMP, EICALL". It wouldn't be the first time the datasheets were wrong about something. I've added the AT90USB162 as a precaution considering the ATmega16u2 should be a replacement and I guess the only downside being performance. |
Co-authored-by: Ryan <fauxpark@gmail.com>
Resolved merge conflicts with uart.c and keyboard.jsonschema. |
* at90usb162 support * fix missing bracket * Apply suggestions from code review Co-authored-by: Ryan <fauxpark@gmail.com> Co-authored-by: Ryan <fauxpark@gmail.com>
Description
Adds support for the AT90USB162.
After my previous PR failure I hope this one is smoother. I've ran
make all:default
and there are failures with some boards but they appear to happen on develop as well. I've compiled and flashed AT90USB162, ATmega32u4 and STM32F401 boards using this branch.I've added preliminary support into spi_master, uart and serial but I've not tested these features but the registers, bits and pins line up with the datasheet. I've been able to test the changes to backlight_avr on a couple of accessible pins with hardware pwm. I'm a little unsure about the edit I've made to the max eeprom address in dynamic_keymap.c as it doesn't make an exception for the 16u2?
The MCU has no ADCs or support for I2C. I found a datasheet while creating a the first pull request stating the ATmega16u2 is functional equivalent to the AT90USB162 which lines up with the edits I've made.
I'm expecting to have missed something but hopefully not too much.
Edit:
For context this is to port existing hardware to QMK, I appreciate there's not likely going to be much call for this MCU. Any who thanks for your help and time.
Types of Changes
Issues Fixed or Closed by This PR
Checklist