Skip to content
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

Support for Atmega2560 #3

Open
stephanbrunner opened this issue Feb 2, 2018 · 10 comments
Open

Support for Atmega2560 #3

stephanbrunner opened this issue Feb 2, 2018 · 10 comments

Comments

@stephanbrunner
Copy link

Hi all,

Is there a technical reason for not supporting the Arduino Mega? I'm thinking of writing the extra code, but I'm not sure if I will bump into some technical limitations...

Thanks,
Stephan

@DavidEGrayson
Copy link
Member

You should be able to add support for ports A through G on the ATmega2560 without any technical limitations. To support the other ports, I believe you would need to make major changes to the assembly code.

@stephanbrunner
Copy link
Author

I see. I'll try, but probably go with a hacky version then. If I get something worth pushing I'll let you know. Thanks! And a beauty of a library by the way.

@ryanaltair
Copy link

ryanaltair commented Apr 2, 2018

@StormTrooper
Copy link

Has anyone had any luck hacking this to work on the 2560 yet?

@stephanbrunner
Copy link
Author

I have a hacky version I can share with you, but not generalized enough to be worth publishing. That would be a cool job to do though. Unfortunattely, because I didn't plan to publish the code, I made some codestyle addaption. Sorry for that. The technical changes may only be in the #define sections to define the chips pinout. But I don't really remember.

Hope that helps anyway:
FastGPIO_MEGA.h.txt

@StormTrooper
Copy link

Thanks very much. I think its done the job.

@stuart1975
Copy link

I installed the latest version and still no official support of ATMega 2560. Please make it official.

@stephanbrunner
Copy link
Author

Find a hacky version attached to my comment 1 month ago. That shound serve for some use cases, not all gpios are supported though. At some point someone probably will write an update supporting all gpios.

@jkwphysics
Copy link

I have a hacky version I can share with you, but not generalized enough to be worth publishing. That would be a cool job to do though. Unfortunattely, because I didn't plan to publish the code, I made some codestyle addaption. Sorry for that. The technical changes may only be in the #define sections to define the chips pinout. But I don't really remember.

Hope that helps anyway:
FastGPIO_MEGA.h.txt

Was really hoping to try this, but I'm getting some errors that are beyond my c/c++ abilities...

FastGPIO_MEGA.h:424:71: error: impossible constraint in asm
_FG_SBI(pinStructs[pin].portAddr, pinStructs[pin].bit);

Any update on officially supported 2560?

@stephanbrunner
Copy link
Author

Some code might help. : )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants