Arduino Project Code and Build Error, Essays (high school) of Mathematics

An arduino project code with the inclusion of external libraries and global variable definitions. The code sets up the input and output pins and initializes the serial communication. The loop function reads the values from the potentiometer and humidity sensor, and based on the potentiometer value, it turns on the led, release, and buzzer. The document also includes a shell script for building the project using makefile, but the build process encounters an error due to the missing xcrun command in the developer path.

Typology: Essays (high school)

2019/2020

Uploaded on 02/21/2020

ChufoP
ChufoP 🇺🇸

2 documents

1 / 2

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
/*** Included libraries ***/
#include <BitbloqSoftwareSerial.h>
/*** Global variables and function definition ***/
const int potenciometro = A0;
bqSoftwareSerial puerto_serie( 0, 1, 9600);
const int led = 7;
const int Rele = 11;
const int higrometro = A4;
/*** Setup ***/void setup(){
pinMode(potenciometro, INPUT);
puerto_serie.begin(9600);
pinMode(led, OUTPUT);
pinMode(Rele, OUTPUT);
pinMode(higrometro, INPUT);
pinMode(11, OUTPUT);
}
/*** Loop ***/
void loop(){delay(500);
puerto_serie.print(String(String(analogRead(potenciometro)))+String(" - "));
puerto_serie.println(analogRead(higrometro));
if(analogRead(potenciometro) > 500){digitalWrite(led,HIGH);
digitalWrite(Rele,HIGH);
digitalWrite(11,HIGH);
}
else {digitalWrite(led,LOW);
digitalWrite(11,LOW);
}
}
/bin/sh -c '/usr/bin/make -j4 -e -f "Alui1.mk" MakeIntermediateDirs &&
/usr/bin/make -j4 -e -f "Alui1.mk" ./Release/main.c.o'
----------Building project:[ Alui1 - Release ] (Single File Build)----------
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools),
missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
====0 errors, 0 warnings====
pf2

Partial preview of the text

Download Arduino Project Code and Build Error and more Essays (high school) Mathematics in PDF only on Docsity!

/*** Included libraries / #include <BitbloqSoftwareSerial.h> / Global variables and function definition / const int potenciometro = A0; bqSoftwareSerial puerto_serie( 0, 1, 9600); const int led = 7; const int Rele = 11; const int higrometro = A4; / Setup /void setup(){ pinMode(potenciometro, INPUT); puerto_serie.begin(9600); pinMode(led, OUTPUT); pinMode(Rele, OUTPUT); pinMode(higrometro, INPUT); pinMode(11, OUTPUT); } / Loop ***/ void loop(){delay(500); puerto_serie.print(String(String(analogRead(potenciometro)))+String(" - ")); puerto_serie.println(analogRead(higrometro)); if(analogRead(potenciometro) > 500){digitalWrite(led,HIGH); digitalWrite(Rele,HIGH); digitalWrite(11,HIGH); } else {digitalWrite(led,LOW); digitalWrite(11,LOW); } } /bin/sh -c '/usr/bin/make -j4 -e -f "Alui1.mk" MakeIntermediateDirs && /usr/bin/make -j4 -e -f "Alui1.mk" ./Release/main.c.o' ----------Building project:[ Alui1 - Release ] (Single File Build)---------- xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun ====0 errors, 0 warnings====