Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [c]

C is a procedural programming language which is widely used in embedded systems. PLEASE NOTE: Arduino is typically programmed in C++, not C.

2
votes
4answers
137 views

How to compare a string

How to compare a string coming from serial monitor with some predefined text stored as a local variable? If I say: int led = 2; String a = " abcds"; void setup(){ Serial.begin(9600); } void loop(...
0
votes
2answers
99 views

What is the opposite of this data operation?

If I store in an array a double-value in this format, in which format I should be able to read the same double out? double myDouble = 12.123456; byte myArray[] = {0x00, 0x00, 0x00, 0x00}; myArray[0] ...
8
votes
2answers
3k views

Arduino interruption (on pin change)

I use the interrupt function to fill an array with values received from digitalRead(). void setup() { Serial.begin(115200); attachInterrupt(0, test_func, CHANGE); } void ...
11
votes
5answers
6k views

Arduino: How to get the board type in code

I want to write a sketch that can be compiled on different Arduino boards. I want to display on the PC which board is currently connected. This means that the user connects the PC via USB cable to ...
9
votes
3answers
13k views

SAM3X8E (Arduino Due) Pin IO registers

How do the IO registers of Arduino Due work? On Arduino Uno just set DDRx, then PINx to read, PORTx to write, I'd like to do the same thing with an Arduino Due, but it has many more registers, such as ...
2
votes
1answer
116 views

Using PBC library on Arduino

I want to know if there is a way to install/use the PBC library on Arduino UNO. I want to implement some cryptographic primitives using PBC library. Thank you.
1
vote
2answers
3k views

Obstacle avoidance algorithm

TARGET The task I have taken as a challenge is to make a GPS-guided robot incorporated with features like Arduino for programming, ultrasonic sensors for obstacle avoidance and a GPS module to ...
-1
votes
2answers
4k views

Peer to peer communication

Hello guys , I want to perform a mesh network between 3-4 modules using ESP8266 . Any one have idea how to do it?
1
vote
3answers
486 views

Why to store a function parameter value in a class private variable?

I'm just curious, I'm going through a C++ library for the mcu2.4 TFT display. And this method I notice when I run through C++ libraries. Which is when a parameter is passed through a function, it's ...
1
vote
1answer
95 views

Arduino Yun doesn't link any library

I'm writing code for a project with Arduino Yun. My project is quite simple: it takes a picture with a webcam and saves it in a PNG or JPEG file format. I've already installed the uvc driver for ...
1
vote
2answers
326 views

Inconsistent response AT command

I'm building a vehicle tracker with Arduino shield with Waveshare SIM 808. I am communicating with the Arduino via AT commands, and came across the following problem: The method "leserial ()" returns ...
1
vote
1answer
1k views

ESP8266 not able to communicate over serial connection with arduino UNO

This is the code I uploaded in Arduino UNO: #include<SoftwareSerial.h> SoftwareSerial ESP(2,3); // RX, TX //ESP RX-->3(UNO) TX-->2(UNO) void setup() { // Open serial communications and ...
0
votes
1answer
743 views

HMC5883L not working in continuous mode!

I'm just starting with the HMC5883L, I'm writing my code with C and also my own I2C library. I noticed that the values on the Arduino IDE's serial monitor are constant. Then I developed a function ...
0
votes
2answers
51 views

Stop multiple presses in vex bumper (Unexpected bumper output) [closed]

According to Official documentation of the Vex Bumper, it states that the bumpers will cause: the robot sometimes [counts] a press twice. This issue is also caused by the robot counting too fast ...
0
votes
1answer
230 views

GPS autonomous robot

I am working on a GPS autonomous robot using Arduino, HMC5883 compass, Adafruit GPS module and I have managed to sort of complete the coding for it and I tried compiling / verifying it and I get an ...