-
-
Notifications
You must be signed in to change notification settings - Fork 725
the pin mode is changed to INPUT mode #28
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
Comments
Indeed, the pull-up should be set only on a digitalWrite(pin, HIGH) when pin is in INPUT mode. |
It is not correct, I mean, Pin mode should not be set at initialization. the Fun void init( void ) void digitalWrite( uint32_t ulPin, uint32_t ulVal ) the Fun void digitalWrite( uint32_t ulPin, uint32_t ulVal ) |
1 similar comment
It is not correct, I mean, Pin mode should not be set at initialization. the Fun void init( void ) void digitalWrite( uint32_t ulPin, uint32_t ulVal ) the Fun void digitalWrite( uint32_t ulPin, uint32_t ulVal ) |
@Makeblock-official, can you put comments in the pull request itself on the lines which disturb you, please? |
…call void init( void ). Setup all pins (digital and analog) in INPUT mode (default is nothing) such as :LiquidCrystal examples
Having all pins start out as inputs is compatible with the AVR Arduinos... |
Closing as setting all pins to INPUT is desired, to maintain compatibility AVR based boards as mentioned by @WestfW above. #94 is open the track @Makeblock-official's concern from #28 (comment).
|
on file wiring.c line 87(Fun init()) Setup all pins (digital and analog) in INPUT mode (default is nothing)
Pin mode should not be set.This line should comment.
on file wiring_digital.c line 81 (Fun digitalWrite()) Enable pull-up resistor.
This line should comment.
The pin mode will be initialized when construct the object.
For example:
Since the pin mode is changed to INPUT,led.high() is set to input pull-up and led.low() is set to input pull-down.So the led will be very dark.
The text was updated successfully, but these errors were encountered: