user85471
  • Member for 3 years, 6 months
  • Last seen more than a month ago
Greyed out port for Raspberry pico in Arduino IDE - Ubuntu 20.04
5 votes

I've come across this and this is how I worked around it (on Windows, but I suspect the problem and solution is the same). A brand new Pico or one not programmed by the Arduino IDE does not have a ...

View answer
output not declaired.anyone please help me to fix this problem
4 votes

To be used in the pinMode function (note capital M), it needs to be all capitals, ie OUTPUT. From a quick scan, you might also need the following changes: output ==> OUTPUT input ==> INPUT pinmode ...

View answer
Why does SoftwareSerial::read() return int?
Accepted answer
3 votes

You'll see in the code just above your third link that the function can return a value of -1 if there is no data present. Thus a 16-bit value is used to cover the range of 8-bit uint8_ts, plus one ...

View answer
If I try to pause my loop function my output screen starts printing trash
3 votes

ESP8266 based boards do not like being tied up for too long without being able to service any WiFi based tasks. Having a while(1){} effectively ties up the processor indefinitely. This causes a ...

View answer
Arduino pow() making 9's
3 votes

I put this code into the IDE, and for n>=2, I got 99, 999, 9999 etc. The catch is that Arduino uses floating point arithmetic to implement the pow() function, and some of your values are being ...

View answer
What does this lines mean in RFID UID Card Reader Code?
3 votes

The code formats UUID as a string of 4 hex bytes (each bytes a pair of hex digits) separated by colons. String ID = "" Blank the string for (byte i = 0; i < 4; i ++){ Iterate over the four ...

View answer
How arduino boards eliminate the need to press buttons to flash?
Accepted answer
3 votes

I'm not familiar with this board, but according to this schematic: https://wiki.wemos.cc/_media/products:lolin32:sch_lolin32_v1.0.0.pdf U4 (one of the small 6-leg components) connects to IO0 (pin 25) ...

View answer
Using usb port to communicate with standalone atmega328p circuit
Accepted answer
2 votes

The ATmega328 does not have any native USB capability, so there is nowhere appropriate to connect D+/D- to the ATmega328. Assuming you are emulating an Arduino Uno, then something like this: https://...

View answer
ATmega328P - Problem using timer 2 for tone generation
Accepted answer
2 votes

I tried the code on an Uno and as you say, it does sound odd. By my calculations, the frequency is 40kHz (16MHz/(200 x 2)), which is above the threshold of hearing. The sound we are actually hearing ...

View answer
Cycling through switch states
2 votes

In your lines: if (state==1) { leds[i].red = 100;Serial.println("Red"); } if (state==2) { leds[i].blue = 100;Serial.println("Blue"); } if (state==3) { ...

View answer
Arduino HID keyboard does not work
2 votes

Keyboard.press() expects a character, but you are passing a character array. Also Keyboard.press() only presses but does not release the key. Keyboard.releaseAll() can be used to release all keys. I ...

View answer
Are there any Wi-Fi modules for the Arduino Uno that may connect to an external Wi-Fi Antenna?
Accepted answer
2 votes

There are variants of ESP8266-based modules which include a connection for an external antenna. The ESP-02, ESP-05 and ESP-07 modules all feature a U.FL socket. Effectively, they are an ESP8266 ...

View answer
FSR wiring using internal pullup resistors?
2 votes

There is probably no practical difference concerning high side vs low side (except the Arduino Uno only has a pullup, and no pulldown). The issue would be the accuracy of the pullup (graphs in the ...

View answer
Controlling motors and servo with L298N
Accepted answer
2 votes

The comment you have found which is also on the Servo library page https://www.arduino.cc/en/Reference/servo and is the core of your problem. On an Uno, you will have to change the PWM pins to 3,5,6 ...

View answer
Compiling code via terminal
1 votes

There is an Arduino CLI (command line interface): https://github.com/arduino/arduino-cli You use commands such as to access Arduino IDE functions: arduino-cli compile --fqbn arduino:avr:leonardo ...

View answer
generate two phase-shifted PWM pulses triggered by frequency-divided external signal with Arduino uno?
Accepted answer
1 votes

I think your first example is very close. What about: int cnt = 0; void setup() { pinMode(3, OUTPUT); pinMode(4, OUTPUT); pinMode(2, INPUT); attachInterrupt(digitalPinToInterrupt(2), ...

View answer
Using Servo on Timer3 on a Leonardo
1 votes

You could try manually sending the servo pulses with something like: digitalWrite(SERVOPIN,HIGH); delayMicroseconds(pulseWidth); digitalWrite(SERVOPIN,LOW); As long as the duration of the pulses is ...

View answer
Changing PWM on Arduino Mega, pins 9 & 10 to 20 to 25 KHz
1 votes

Fortunately, the timer for PWM on both pins 9 and 10 on the Arduino Mega (but not necessarily other boards) is timer 2, so changing the PWM frequency of one will change the PWM frequency of the other. ...

View answer
exit status 1 'Time' does not name a type
1 votes

You don't mention which library you are using (which library does #include <DS3231.h> refer to?) The DS3231 library here https://github.com/NorthernWidget/DS3231 defines a DateTime object which ...

View answer
Tiny RTC module doesn't work properly when connected to an Arduino Uno together with 16x2 LCD
1 votes

An I2C scanner sketch can help to identify the actual addresses in use. I would use a sketch like on this page https://playground.arduino.cc/Main/I2cScanner or on this page http://gammon.com.au/forum/?...

View answer
Why is my DHT22 sensor reading 1.00% humidity?
1 votes

When I have rigged up these sensors to test, I breathe on them. Both the temperature and humidity should rise as breath is warm and humid. From memory, I have seen the humidity rise from ~40% to ~70%,...

View answer
Problem stacking ADS1292r ECG shield and Wifi shield on Arduino Uno
1 votes

As a generic answer to these sorts of problems (same pin needed by different libraries), I have had success with slightly bending the pin of the top shield to the side to that it doesn't make direct ...

View answer
Flashing NodeMCU with .ino file?
Accepted answer
1 votes

Last question first: The ESP8266 is the main IC on the NodeMCU board. This is similar to the idea that an ATMega328 is the IC on Arduino Uno. A normal 'clean' Arduino IDE install can work with an ...

View answer
Use chars in quotes in const char* as name of function
0 votes

Being a const char, you can set it at compile time with a define and then use it. #define fstring(x) #x const char* ssid = fstring(SSID_NAME) ; void setup() { Serial.println("Start"); ...

View answer
Recognize peak in specific frequency area
0 votes

An alternative to the FFT is the Goertzel algorithm. It is intended to only detect a single frequency, so may not suit your purpose of working with a range. But it may be more practical and require ...

View answer
My Arduino code is showing unidentified reference for 3 of my variables, I don't know how to fix it
0 votes

When I tried to compile it, I got (after editing **Error**): In function `loop': /sketch_jan15b.ino:55: undefined reference to `begin_game()' /sketch_jan15b.ino:60: undefined reference to `...

View answer
16Hertz Uno R3 Board vs Arduino Uno R3 Board
0 votes

Just a theory for 2: The text that shows up in the Tools > Port list after the COMx eg Tools -> Port -> COM3(Arduino Mega or Mega 2560) is simply what the IDE thinks the board is based on the ...

View answer
How to monitor state of 50 Digital Inputs
0 votes

The Mega 2560 appears to have 24 pin change interrupts (I haven't checked if they're all broken out on the Mega Arduino board). A combination of as many pin change interrupts and 'manual' scanning ...

View answer
LCDs larger than 20x04 and 5" diagonal
0 votes

There are ST7920 based displays which may come close to what you are looking for. They have a similar parallel (4 or 8 bit) interface to the HD44780 based displays (as you have been using), but also ...

View answer
Weird issue with software serial?
0 votes

This may not be the answer you need if you are using it for something else, but if you are using a Micro, I would use the hardware serial Serial1 instead of SoftwareSerial. I've done many projects ...

View answer