Most Popular
1500 questions
8
votes
2 answers
What are the implications of running an ATmega328P at 8 MHz and 3.3 V with the Arduino system?
I'm working on a custom arduino that will run at 3.3 V with no regulators or USB chips (for power consumption). I've heard that overclocking the chip at 16 MHz/3.3 V is generally fine, but I'd like to stay within spec anyway.
First: to run at 8…
Vulcan
- 245
- 2
- 6
8
votes
6 answers
Two Arduinos Send data via Analog Pin?
What I want to do is allow Arduino A to send some constant value to Arduino B.
I sense something inherently wrong with my approach, but I cant figure out what it is.
So in the diagram below you will see Arduino A setting its Analog Pin 0 as OUTPUT…
lucidgold
- 233
- 1
- 3
- 9
8
votes
1 answer
RTClib library dependency on Wire library
I downloaded the RTClib library from https://github.com/adafruit/RTClib. In every provided example, #include is written immediately above #include "RTClib.h" at the top of the sketch.
Why is this necessary? I know the RTClib library…
Zilliput
- 183
- 1
- 5
8
votes
1 answer
Increasing payload size above 32 bytes using nRF24L01+
I tried to modify the example in the following page, by replacing the given string with a 56 bytes one after making all the suitable changes to read(), write() and max_payload_size(increased to 64 bytes), payload_size() parameters/methods in the…
Naveen
- 193
- 1
- 1
- 5
8
votes
3 answers
Arduino screws up trivial program involving enum
Behold this insanity:
enum WhatArduinoIs {
Easy, But, Insane, Obsolete, And, Far, Worse, Than, mBed
};
void TellMe(WhatArduinoIs pls) { }
void setup() { }
void loop() { }
I'm pretty good at C++, so I'm fairly sure that should compile. However I…
Timmmm
- 183
- 2
- 5
8
votes
1 answer
Can I program a 3.3v chip on a 5v board?
I bought a Gertboard a while ago, and one of the features it has on-board is an ATMega328 (DIP). However, since the Gertboard is designed for use with the Raspberry Pi, it only operates at 3.3v, so the clock speed is limited to ~12MHz.
Programming…
Peter Bloomfield
- 10,932
- 9
- 47
- 87
8
votes
1 answer
Confuse about PROGMEM and R"====()===="
I saw the following code from https://circuits4you.com/2018/03/10/esp8266-jquery-and-ajax-web-server/ but I could not understand it thoroughly...
I looked at the documentation of PROGMEM from this…
Mark Estrada
- 223
- 2
- 6
8
votes
4 answers
What are the traditional ways to optimize program memory usage?
While doing big projects using Arduino boards (Uno, Atmega328P MCU). I used to get warnings like this
Sketch uses 13764 bytes (44%) of program storage space. Maximum is 30720 bytes.
Global variables use 1681 bytes (82%) of dynamic memory, leaving…
Mayoogh Girish
- 205
- 2
- 7
8
votes
1 answer
Is there a way to detect if Arduino, Stino or another IDE/toolchain is in use?
I've noticed some irritating differences between the Arduino IDE and Stino (mainly around including certain header files). These are likely bugs that need following up with one or both of the parties, but in the meantime, I would like my code to…
Cybergibbons
- 5,350
- 7
- 33
- 51
8
votes
1 answer
Digital RGB LED animation
I've been trying to get colours fade into each other for a project I'm working on.
I have achieved this with the rainbow effect that some from Adafruit's example code, however I want to be able to choose the colours (eg. dark blue into light…
Rhys Edwards
- 183
- 1
- 4
8
votes
3 answers
Using more than one Ping Ultrasonic Range Finder
I have done various applications with the Ultrasonic example project but it is always using one pinger. I'd like to make a scanner resting on a servo sweep but to reduce sweep time use more than one censor.
the documentation is rather basic ping…
alexmac
8
votes
2 answers
Audio Frequency White Noise generation using Arduino Mini Pro
For DIY, how to program Arduino Mini Pro to act as an Audio Frequency White Noise generator?
Presumably,
a) using one Digital Output pin
b) feed to a simple passive RC low pass filter to reduce out of band signal
c) feed to a simple class-D IC…
EEd
- 904
- 1
- 13
- 21
8
votes
4 answers
Is SoftwareSerial left out for the ATTiny85/84?
I want to use SoftwareSerial with my ATTiny85 and when I google it several projects claim that they are using it... I downloaded the hardware from https://code.google.com/p/arduino-tiny/, but when I try to add SoftwareSerial and compile I get:
fatal…
Jason94
- 293
- 1
- 5
- 11
8
votes
2 answers
What is the default setting for a digital output pin
With digitalWrite(pin_number,value), we can set an output pin as HIGH or LOW. But if only coding pinMode (pin_number, OUTPUT), what is the default state for the pin pin_number, LOW or HIGH? It is noted that: Pins configured as OUTPUT with pinMode()…
jingweimo
- 201
- 1
- 2
- 5
8
votes
2 answers
Temperature sensors TMP36 and LM35 have temperature diff. (offset) in the same circuit
I am trying to use the two temperature sensors TMP36 (from Sparkfun Inventor's kit) and KEYES LM35.
In read TMP36 Sensor and I convert the result to Celsius using the following code:
// TMP36 input sensor -> degrees Celsius calculation
TM36reading =…
ggia
- 95
- 1
- 1
- 7