Skip to main content
2 votes
Accepted

Writing to partially reserved registers of sensors

You always write a whole byte when you set the register. You only need to "mask out" those bits if there's a danger that you may inadvertently set them to 1, for instance through some value ...
Majenko's user avatar
  • 105k
2 votes
Accepted

Is it possible for the Arduino's digital pin mode to flip from OUTPUT to INPUT unexpectedly?

The fact that it is possible to set them incorrectly is why, in some projects where I'm concerned about this, I'll add a small series resistance to an inbound signal. Should the pin become OUTPUT and ...
timemage's user avatar
  • 5,299
1 vote

How to read and Serial.print the contents (current values) of an 8-bit register?

Another option: #include <LibPrintf.h> printf("%.8b", ADMUX); //prints: 0110000 The LibPrintf.h library is standard included on ESP boards. %b stands for binary. .8 for 8 decimal ...
Gaai's user avatar
  • 55
1 vote

Is there a definitive reference for the Arduino DUE?

The full pinout is available on arduino.cc in Store and in the Getting started section. For instance, PWM/Digital Pin 2 maps to PB25 on the chip. PB25 is not a member of the PWM pins as per the chip ...
Juraj's user avatar
  • 18k
1 vote

Controlling Arduino through python

If you mean can you run a python script on a "PC" and send messages to an Arduino then yes but you would need to write code that ran on the Arduino to receive messages from the "PC"...
Code Gorilla's user avatar
  • 5,637

Only top scored, non community-wiki answers of a minimum length are eligible