Skip to content
This repository was archived by the owner on Jun 7, 2019. It is now read-only.

MOTION_PIN conflicts with SELECT_PIN #1

Open
bobdoah opened this issue Oct 29, 2018 · 0 comments
Open

MOTION_PIN conflicts with SELECT_PIN #1

bobdoah opened this issue Oct 29, 2018 · 0 comments

Comments

@bobdoah
Copy link

bobdoah commented Oct 29, 2018

I uncommented the MOTION_PIN and the compile failed with:

Arduino: 1.8.1 (Mac OS X), Board: "Pro Trinket 5V/16MHz (USB)"

/Users/bob/Downloads/Kinetic_POV-master/bikewheel/bikewheel.ino: In function 'void sleep()':
bikewheel:344: error: redeclaration of 'volatile uint8_t* p'
   volatile uint8_t *p = portInputRegister(digitalPinToPort(SELECT_PIN));
                     ^
/Users/bob/Downloads/Kinetic_POV-master/bikewheel/bikewheel.ino:325:21: note: 'volatile uint8_t* p' previously declared here
   volatile uint8_t *p = portInputRegister(digitalPinToPort(MOTION_PIN));
                     ^
exit status 1
redeclaration of 'volatile uint8_t* p'

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Perhaps it's not possible to use the MOTION_PIN and SELECT_PIN at the same time, but it seems like this could be fixed by declaring the variable with a different name.. but maybe it's not that straightforward?

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

No branches or pull requests

1 participant