I thought it would be interesting to compare the speeds of various Arduino boards, from older designs to the newest microcontrollers. I looked at the following: Note that the Nano 33 IoT, the Nano RP2040, and the Uno R4 (WiFi version) all have an ESP32 as a coprocessor for the radio functionality. The Nano ESP32 …
Traditional Arduino boards, like the Uno R3 or Nano, are typically programmed using the Arduino Library functions. These conveniently present most of the microcontroller’s functionality to the hobbyist user. Books like my Far Inside The Arduino and the microcontroller’s documentation show how to access additional functionality not addressed by the Arduino Library. As more advanced …
The map function takes a long integer value, x, in the range in_min through in_max and maps it into the range out_min through out_max. It is very convenient for scaling measurements and the function is defined: It is important to realize some limitations of this function. Some Arduino models define a function mapResolution that does …
The Arduino Uno R4 Minima seemingly has a purpose of eventually replacing the Arduino Uno R3. It’s a 5 volt board with the same form factor as the earlier Uno that seemingly offers more performance (speed and memory capacity) at a 25% lower price point. People are finding flaws in that it has lower current …
The EEPROM library (https://docs.arduino.cc/learn/built-in-libraries/eeprom) has functions for reading and writing single bytes but no function for erasing. The EEPROM in the AVR microcontrollers are capable of erasing and writing single bytes and 100,000 erase/write cycles in a location is the design maximum before the EEPROM will wear out. To maintain compatibility, the EEPROM functions in …
Today I got the new Arduino Uno R4 boards in the mail. This includes the Minima and Wifi models, but this post will just concern itself with the Minima. The R4 Minima is much less expensive than the R3, but still a bit more than a good R3 clone like the Elegoo. You can see …
The DAC (analogWrite to A0 in Arduino Nano 33 IoT, MKR, and Zero boards) isn’t specified to work to the extreme limits. Basically it doesn’t go below 50mV or above 3.25 volts. While the Arduino documentation doesn’t mention this, the datasheet does in section 37.11.5. While the DAC is 10 bits, the analogWrite function reduces …
The Analog to Digital Converter in the SAMD21 is specified to run with a clock frequency from 30 to 2,100 kHz. The Arduino Library configures the ADC clock to be the 48 MHz system clock divided by 256, or 187.5 kHz, or a clock period of 5.33 µs. The conversion time is 7 clock periods, …
The SAMD21 based Arduino boards have a 10 bit DAC, so naturally I wanted to generate a sine wave! Some years ago when I was teaching microcontrollers I had students build a DAC using a resistor ladder. The microcontroller, a 68HCS12, used a timer interrupt to advance the value to the DAC by indexing a …
Next month Amazon is raising their printing costs for printed books by Kindle Direct Publishing. The increase is very small for all of my books except the old 68HCS12 title. I decided to absorb the cost increase, although Amazon has made it easy to apply price increases. This could mean that other KDP books might …