Additional sleep methods with array of pins as parameters ?
-
@yveaux said in Additional sleep methods with array of pins as parameters ?:
Yes, they have to set it to input. There's no pin configuration in the (AVR) sleep code: https://github.com/mysensors/MySensors/blob/development/hal/architecture/AVR/MyHwAVR.cpp#L153
But atmega pins default as inputs so it's not really mandatory with the default IC.
@nca78 said in Additional sleep methods with array of pins as parameters ?:
@yveaux said in Additional sleep methods with array of pins as parameters ?:
Yes, they have to set it to input. There's no pin configuration in the (AVR) sleep code: https://github.com/mysensors/MySensors/blob/development/hal/architecture/AVR/MyHwAVR.cpp#L153
But atmega pins default as inputs so it's not really mandatory with the default IC.
I like to make things explicit, especially if you decide to port to another architecture later on
-
@nca78 said in Additional sleep methods with array of pins as parameters ?:
@yveaux said in Additional sleep methods with array of pins as parameters ?:
Yes, they have to set it to input. There's no pin configuration in the (AVR) sleep code: https://github.com/mysensors/MySensors/blob/development/hal/architecture/AVR/MyHwAVR.cpp#L153
But atmega pins default as inputs so it's not really mandatory with the default IC.
I like to make things explicit, especially if you decide to port to another architecture later on
@yveaux said in Additional sleep methods with array of pins as parameters ?:
I like to make things explicit, especially if you decide to port to another architecture layer on
I completely agree with you. Just stating that @mfalkvidd is not wrong when saying at the moment it's not necessary to declare pins as inputs
To go back to the main subject should I make a first version of this code (in post 9) to have a clearer basis for future discussions ? Or am I going a wrong way ?
-
Anything is always better than nothing.
-
@mfalkvidd said in Additional sleep methods with array of pins as parameters ?:
I don’t think sketch developer should need to worry about setting the pin to input,
Yes, they have to set it to input. There's no pin configuration in the (AVR) sleep code: https://github.com/mysensors/MySensors/blob/development/hal/architecture/AVR/MyHwAVR.cpp#L153
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login