exit status 1 error

Hey yall i am having a bit of trouble woth my code, it keeps saying exit status 1 an i cant quite figure out why. Please help ASAP. Here is the code
// Arduino code to control and RGB LED strip
// Uses a toggle switch to switch between color-fade mode
// and individual RGB control mode
// adapted from Arduino Code | RGB LED Strips | Adafruit Learning System
const int RED = 9; // define digital output pins for individual red,
const int GREEN = 10; //green and blue channels
const int BLUE = 11;
const int POT1 = 0; // define analog input pins for three potentiometers
const int POT2 = 1;
const int POT3 = 2;
const int POT4 = 3;
const int BUTTON = 2; // define digital input pin for the switch
int val = 0; // stores the state of the switch input pin
int FADESPEED = 0; // initiate fade speed set by potentiometer
int r = 0; // initialize the red, green and blue values
int g = 0;
int b = 0;
void setup(){
pinMode(RED, OUTPUT); // define digital pins as outputs and inputs as needed
pinMode(GREEN, OUTPUT);
pinMode(BLUE, OUTPUT);
pinMode(BUTTON, INPUT);
}
void loop(){
val = digitalRead(BUTTON); // read the input value from the toggle switch
if (val == HIGH){ // code for RGB color fade
FADESPEED = analogRead(POT4)/10;
// set the fade speed by reading analog input from 4th potentiometer
// analogRead will output a number between 0 and 1023, and "delay"
// is in milliseconds, so the biggest delay you'll get here is about
// 1/10 of a second. Divide by a different number to change the max
// fade time.
// fade from blue to violet
for (r = 0; r < 256; r++) {
analogWrite(RED, r);
FADESPEED = analogRead(POT4)/10;
// check the fade speed continuously, otherwise
// it won't update until it's gone through a complete cycle.
// Probably not the most efficient way to do this...
delay(FADESPEED);
}
// fade from violet to red
for (b = 255; b > 0; b--) {
analogWrite(BLUE, b);
FADESPEED = analogRead(POT4)/10;
}
// fade from red to yellow
for (g = 0; g < 256; g++) {
analogWrite(GREEN, g);
FADESPEED = analogRead(POT4)/10;
delay(FADESPEED);
}
// fade from yellow to green
for (r = 255; r > 0; r--) {
analogWrite(RED, r);
FADESPEED = analogRead(POT4)/10;
delay(FADESPEED);
}
// fade from green to teal
for (b = 0; b < 256; b++) {
analogWrite(BLUE, b);
FADESPEED = analogRead(POT4)/10;
delay(FADESPEED);
}
// fade from teal to blue
for (g = 255; g > 0; g--) {
analogWrite(GREEN, g);
FADESPEED = analogRead(POT4)/10;
delay(FADESPEED);
}
}
else { // code for individual RGB control with potentiometers
r = analogRead(POT3)/4;
// read values from the 3 potentiometers and divide by 4 to set brightness
g = analogRead(POT2)/4; // note that analog read is 10-bit (0-1023), analog write is an 8-bit PWM
b = analogRead(POT1)/4; // signal so you need to divide this value by 4.
analogWrite(RED, r); // write analog values to red, green and blue output pins
analogWrite(GREEN, g);
analogWrite(BLUE, b);
}
}

TOPIC SPLIT
DO NOT HIJACK !

Could you take a few moments to READ THIS.
It will help you get the best out of the forum.

Bob.

it keeps saying exit status 1

What else do it say?
Please share.

/home/builder/opt/arduino-builder/arduino-builder -compile -core-api-version 10611 -hardware /home/builder/opt/arduino-builder/hardware -hardware /home/builder/.arduino15/packages -tools /home/builder/opt/arduino-builder/tools -tools /home/builder/.arduino15/packages -built-in-libraries /home/builder/opt/libraries/latest -logger humantags -fqbn arduino:avr:uno -build-cache /tmp -build-path /tmp/200395917/build -verbose -prefs runtime.tools.openocd.path=/home/builder/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -prefs runtime.tools.CMSIS.path=/home/builder/.arduino15/packages/arduino/tools/CMSIS/4.5.0 -prefs runtime.tools.arm-none-eabi-gcc.path=/home/builder/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs runtime.tools.avr-gcc.path=/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2 -prefs runtime.tools.x86-linux-gcc.path=/home/builder/.arduino15/packages/arduino/tools/x86-linux-gcc/7.2.0 -prefs runtime.tools.xtensa-lx106-elf-gcc.path=/home/builder/.arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-3-20ed2b9 -prefs runtime.tools.arduino101load.path=/home/builder/.arduino15/packages/Intel/tools/arduino101load/2.0.1 -prefs runtime.tools.core2-32-poky-linux.path=/home/builder/.arduino15/packages/Intel/tools/core2-32-poky-linux/1.6.2+1.0 -prefs runtime.tools.arm-linux-gcc.path=/home/builder/.arduino15/packages/arduino/tools/arm-linux-gcc/4.9.3 -prefs runtime.tools.bossac.path=/home/builder/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs runtime.tools.sketchUploader.path=/home/builder/.arduino15/packages/Intel/tools/sketchUploader/1.6.2+1.0 -prefs runtime.tools.linuxuploader.path=/home/builder/.arduino15/packages/arduino/tools/linuxuploader/1.5.1 -prefs runtime.tools.dfu-util.path=/home/builder/.arduino15/packages/arduino/tools/dfu-util/0.9.0-arduino1 -prefs runtime.tools.CMSIS-Atmel.path=/home/builder/.arduino15/packages/arduino/tools/CMSIS-Atmel/1.2.0 -prefs runtime.tools.arduinoOTA.path=/home/builder/.arduino15/packages/arduino/tools/arduinoOTA/1.2.1 -prefs runtime.tools.i586-poky-linux-uclibc.path=/home/builder/.arduino15/packages/Intel/tools/i586-poky-linux-uclibc/1.6.2+1.0 -prefs runtime.tools.arc-elf32.path=/home/builder/.arduino15/packages/Intel/tools/arc-elf32/1.6.9+1.0.1 -prefs runtime.tools.avrdude.path=/home/builder/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino14 -prefs runtime.tools.nrf5x-cl-tools.path=/home/builder/.arduino15/packages/arduino/tools/nrf5x-cl-tools/9.3.1 -prefs runtime.tools.esptool.path=/home/builder/.arduino15/packages/esp8266/tools/esptool/2.5.0-3-20ed2b9 -prefs runtime.tools.mkspiffs.path=/home/builder/.arduino15/packages/esp8266/tools/mkspiffs/2.5.0-3-20ed2b9 -prefs runtime.tools.flashpack.path=/home/builder/.arduino15/packages/Intel/tools/flashpack/2.0.0 -libraries /tmp/200395917/custom -libraries /tmp/200395917/pinned /tmp/200395917/sketch_nov26a

Using board 'uno' from platform in folder: /home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23

Using core 'arduino' from platform in folder: /home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23

Detecting libraries used...

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10611 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -I/home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino -I/home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard /tmp/200395917/build/sketch/sketch_nov26a.ino.cpp -o /dev/null

Generating function prototypes...

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10611 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -I/home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino -I/home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard /tmp/200395917/build/sketch/sketch_nov26a.ino.cpp -o /tmp/200395917/build/preproc/ctags_target_for_gcc_minus_e.cpp

/home/builder/opt/arduino-builder/tools/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/200395917/build/preproc/ctags_target_for_gcc_minus_e.cpp

Compiling sketch...

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10611 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -I/home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23/cores/arduino -I/home/builder/.arduino15/packages/arduino/hardware/avr/1.6.23/variants/standard /tmp/200395917/build/sketch/sketch_nov26a.ino.cpp -o /tmp/200395917/build/sketch/sketch_nov26a.ino.cpp.o

Compiling libraries...

Compiling core...

Using precompiled core: /tmp/core/core_arduino_avr_uno_f73f8035d4928006c181f54a2aa5f0b0.a

Linking everything together...

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-gcc -w -Os -g -flto -fuse-linker-plugin -Wl,--gc-sections -mmcu=atmega328p -o /tmp/200395917/build/sketch_nov26a.ino.elf /tmp/200395917/build/sketch/sketch_nov26a.ino.cpp.o /tmp/200395917/build/../../core/core_arduino_avr_uno_f73f8035d4928006c181f54a2aa5f0b0.a -L/tmp/200395917/build -lm

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/200395917/build/sketch_nov26a.ino.elf /tmp/200395917/build/sketch_nov26a.ino.eep

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-objcopy -O ihex -R .eeprom /tmp/200395917/build/sketch_nov26a.ino.elf /tmp/200395917/build/sketch_nov26a.ino.hex

/home/builder/.arduino15/packages/arduino/tools/avr-gcc/5.4.0-atmel3.6.1-arduino2/bin/avr-size -A /tmp/200395917/build/sketch_nov26a.ino.elf

Sketch uses 1958 bytes (6%) of program storage space. Maximum is 32256 bytes.

Global variables use 15 bytes (0%) of dynamic memory, leaving 2033 bytes for local variables. Maximum is 2048 bytes.

Programming with: Serial

Flashing with command:/Users/Sebastian/.arduino-create/arduino/avrdude/6.3.0-arduino14/bin/avrdude -C/Users/Sebastian/.arduino-create/arduino/avrdude/6.3.0-arduino14/etc/avrdude.conf -v -patmega328p -carduino -P/dev/cu.usbmodem1421 -b115200 -D -Uflash:w:/var/folders/t3/38hhk2ms78338cfpg9gjvcpw0000gp/T/arduino-create-agent335055637/sketch_nov26a.hex:i

avrdude: Version 6.3-20171130

Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

Copyright (c) 2007-2014 Joerg Wunsch

System wide configuration file is "/Users/Sebastian/.arduino-create/arduino/avrdude/6.3.0-arduino14/etc/avrdude.conf"

User configuration file is "/Users/Sebastian/.avrduderc"

User configuration file does not exist or is not a regular file, skipping

Using Port : /dev/cu.usbmodem1421

Using Programmer : arduino

Overriding Baud Rate : 115200

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x00

avrdude: stk500_recv(): programmer is not responding

avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x00

thats what it says, then it says execute exit status 1, but i dont know why, it seems that my code is fine. Please respond quick i need to finish this today in like an hour
:o :o :frowning:

The people in this forum are just other Arduino users like yourself.
Asking for a quick response may be like watching paint dry.
In some cases it puts people off helping.
Remember almost all of us do not work for Arduino.

Bob.

yeah im sorry guys take your time, im just kinda worried i dont mean to sound rude, im just new to this.

FWIW, it compiles for me for an Uno using IDE 1.8.5 and Windows 10.

Compiles here too (CREATE EDITOR LINK)

Remove any other connections you have or re-check your wiring and avoid pins 0 & 1

Bob.

thanks guys this might help
:slight_smile: