New answers tagged arduino-uno
0
votes
I am attempting to control two stepper motors by using serial input. My code works, however I have to press the new directional command multiple times
The problem is, that you are reading from the Serial buffer without using the data. There are three places in your code, where you use Serial.read();:
You use in in the block with your serial code ...
- 15.2k
0
votes
Correctly connecting a four-pin tilt sensor to a breadboard before going live
So I've asked this question on the Arduino.cc forum (just to get a safe answer quickly to hustle up on the project). If you look at the pins on the four-pin tilt switch with the notch facing down (as ...
0
votes
The gateway is not working in Arduino EthernetENC
From outside your local network (i.e the internet) you can only ping the external IP address of your router, local IPs such as your 192.168.11.242 are not routable on the internet. Additionally many ...
- 948
3
votes
Accepted
Checking a thing about interrupts
See How do interrupts work on the Arduino Uno and similar boards?
Yes, most interrupts will be remembered and the ISR will be executed when interrupts are enabled again, plus one more instruction has ...
- 36k
0
votes
Accepted
Curious Collision between OneWire and RadioHead
Finally had time to get back to this. I connected the data-out line from the sender to the data-in line of the receiver, and discovered it always works. So it's not any sort of collision between ...
- 125
2
votes
Where does this sketch have Undefined Behavior?
With some USB to TTL Serial chips it is a problem to start the upload if there is too much input from the MCU on the Serial side. In this case it is the Holtek UART Bridge which is not common for ...
- 17.1k
2
votes
Accepted
Where does this sketch have Undefined Behavior?
Your sketch does not have undefined behaviour. It works:
I already have code that works.
Your problem apparently is that after loading this sketch you have trouble uploading a new sketch:
this code ...
- 36k
1
vote
HC-05 Bluetooth module; two serial ports, COM4 and COM5
I found this answer in Microsoft Technet helpful:
when connecting your terminal program to the first you are actually instructing Windows to attempt to establish the Bluetooth connection to the ...
- 139
0
votes
Using Assembly to setup a interrupt on Rx, pin 0 allowing the program to jump to the handler when data is loaded. Compiles but Interrupt never happens
The solution I found to work was to put a .global URXC_INT_HANDLER, now the interrupt works
- 7
0
votes
ESP8266 + PIR with Laptop connection vs other power source
Turns out its loose wiring that caused the PIR to go wild.
- 19
0
votes
I2C_Anything ++
Slave_I2C_Anything_PCF8574_4DO_uneStructure_bigOctes.ino
/*
* DESCRIPTION :
* un Arduino Uno en liaison avec un module i2c PCF8574 avec 4 Relais
* il recoi aussi d'un autre Arduino des ...
- 1
0
votes
I2C_Anything ++
A return on the module of Electrical measurements.
with an i2C bus.
(it can be useful for other people)
No more errors, no more blocking, it purrs like a kitten.
For the structure I copied the work of ...
- 1
0
votes
Calibration of pH sensor
You probably need to do that in software. That is supported by step 7 in the chapter Software on your linked site.
In step 4 we see the proposed demo code, which contains the calculation of pH based ...
- 15.2k
1
vote
My issue is, 51:28: error: expected primary-expression before ')' token can someone give me advice or steer me to correcting my issue? Makes no sense
That line doesn't make any sense at all. Just count opening and closing brackets and so on
if ((flexPin)) value<910;))&& (value>767));
{digitalWrite(ledoth,LOW); digitalWrite(ledPin,HIGH)...
- 4,272
0
votes
Accepted
ATTiny88 missing pulses - maybe
OK, I have an answer. The MCU is still missing a lot of pulses, but I am fairly certain this is a hardware issue, or at least mostly so. I found some code by Ralph S. Bacon and Marko Pinteric. The ...
-1
votes
strange behaviour with a single 7seg display
It looks like setChars is expecting a string, not a single character.
So I would be doing something like:
while (int i = 0; i < len; i++)
{
char buf [2];
buf [0] = str[i];
buf [1] = ...
- 36k
-1
votes
why the p-mos is acting as a constant switch when the source is connect to any port in the circuit iam not able find the solution ?i
The Arduino when the output is High is ~5V referencing. The MOSFET gate sees it as -7V referencing the source. It is always best to use the source as the reference point for a MOSFET. Look at the data ...
- 1,589
1
vote
How to use arduino to run .exe file in a windows computer
As mentioned in comments, one way to do this would be to bind a windows shortcut key to do the action you desire and then have the arduino send that as a keystroke. This would only be possible on ...
- 119
-1
votes
why the p-mos is acting as a constant switch when the source is connect to any port in the circuit iam not able find the solution ?i
You have to be careful with such a circuit because you risk applying 12 volts to an arduino pin. To switch that P channel mosfet off, 12 volts has to be applied to the gate. Search for "mosfet ...
- 644
5
votes
Accepted
How does the compiler/assembler work wrt bootloader?
On the Uno and similar AVR-based boards, the compiler and assembler are
not aware of the bootloader. The compiled program starts at address
zero. There you have the interrupt vector table, starting ...
- 39.6k
1
vote
Using internal voltage reference for sensor
The problem is that my sensor (mini solar panel) reads max value under little light and does not go beyond that level no matter how much light falls onto it in the later stage.
Open voltage is not a ...
- 1,515
0
votes
Why a Arduino UNO R3 board can use in Windows 10 but can't be used in My Macbook Air(M1)?
No driver necessary on MacOS which is essentially derived from UNIX/Linux. It should be plug & play.
It looks like the Air is not recognizing the Uno.
Try opening a Terminal console and type ls /...
- 1
1
vote
Accepted
Reading constant battery voltage and using the obtained value in sensor formula
If you set the Vref with the internal reference of 1.1v, then the voltage presented at analog pin A1 is simply as:
const float Vref = 1.1; // according to datasheet there is a +/-10% variance, need ...
- 1,149
Top 50 recent answers are included
Related Tags
arduino-uno × 7970serial × 653
programming × 562
sensors × 488
esp8266 × 451
arduino-ide × 372
led × 324
c++ × 277
motor × 277
arduino-mega × 269
power × 233
servo × 222
lcd × 211
i2c × 207
bluetooth × 199
softwareserial × 188
gsm × 171
arduino-nano × 170
wifi × 167
pwm × 166
shields × 166
interrupt × 160
atmega328 × 154
c × 153
pins × 146