Hello,
Today I wanted to upload some edits to my program that is running on my arduino board but the compiler gives me a error i cannot resolve:
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:-1: error: expected ',' or '...' before numeric constant
SchrijfRobot:0: error: expected ',' or '...' before numeric constant
SchrijfRobot:1: error: expected ',' or '...' before numeric constant
SchrijfRobot:2: error: expected ',' or '...' before numeric constant
SchrijfRobot:3: error: expected ',' or '...' before numeric constant
SchrijfRobot:4: error: expected ',' or '...' before numeric constant
SchrijfRobot:5: error: expected ',' or '...' before numeric constant
SchrijfRobot:6: error: expected ',' or '...' before numeric constant
SchrijfRobot:7: error: expected ',' or '...' before numeric constant
SchrijfRobot:8: error: expected ',' or '...' before numeric constant
LetterFunctions:8: error: expected ',' or '...' before numeric constant
LetterFunctions:14: error: expected ',' or '...' before numeric constant
LetterFunctions:31: error: expected ',' or '...' before numeric constant
LetterFunctions:58: error: expected ',' or '...' before numeric constant
LetterFunctions:83: error: expected ',' or '...' before numeric constant
LetterFunctions:101: error: expected ',' or '...' before numeric constant
LetterFunctions:122: error: expected ',' or '...' before numeric constant
LetterFunctions:139: error: expected ',' or '...' before numeric constant
LetterFunctions:176: error: expected ',' or '...' before numeric constant
LetterFunctions:189: error: expected ',' or '...' before numeric constant
LetterFunctions:207: error: expected ',' or '...' before numeric constant
LetterFunctions:228: error: expected ',' or '...' before numeric constant
LetterFunctions:244: error: expected ',' or '...' before numeric constant
LetterFunctions:256: error: expected ',' or '...' before numeric constant
LetterFunctions:269: error: expected ',' or '...' before numeric constant
LetterFunctions:281: error: expected ',' or '...' before numeric constant
LetterFunctions:304: error: expected ',' or '...' before numeric constant
LetterFunctions:324: error: expected ',' or '...' before numeric constant
LetterFunctions:353: error: expected ',' or '...' before numeric constant
LetterFunctions:373: error: expected ',' or '...' before numeric constant
LetterFunctions:415: error: expected ',' or '...' before numeric constant
LetterFunctions:428: error: expected ',' or '...' before numeric constant
LetterFunctions:453: error: expected ',' or '...' before numeric constant
LetterFunctions:466: error: expected ',' or '...' before numeric constant
LetterFunctions:483: error: expected ',' or '...' before numeric constant
LetterFunctions:496: error: expected ',' or '...' before numeric constant
LetterFunctions:511: error: expected ',' or '...' before numeric constant
I have the script stored on dropbox so I inmidiately restored it to the last script I knew I uploaded but I get exactly the same problem.
here is a snippet of my code:
#include <EEPROM.h> // Needed to write to EEPROM memory
#define STANDARD_STEP_DELAY 800 // The delay for each step (in microseconds) determence the speed of the motors
#define START_OFFSET 30 // How many steps the robot makes forward before it starts writing
#define STANDARD_LETTER_OFFSET 30 // Standard offset make some space between 2 letters.
#define BUTTON 8
#define Scale 10 // Standard scale for each letter, Letters who are to big or to small get a custom scale
boolean FirstLetter=true;
char EEPROMWordArray[50]; // The word can contain max 50 characters
void setup() {
for(int i=2;i<=5;i++){
pinMode(i, OUTPUT); // set pin 2 till 5 to output
}
pinMode(BUTTON,INPUT); // set button pin to input
Serial.begin(9600); // begin serial communication
Serial.println("Type a word to write, all lowercase letters");
Serial.print("The current word is: ");
for(int i=0;i<50;i++){ // loop trought te max 50 characters of the word that needs to be written
EEPROMWordArray[i]=EEPROM.read(i); // read stored char array
Serial.write(EEPROMWordArray[i]); // write currently stored word to serial monitor
}
Serial.println(); // new line
}
void loop()
{
checkSerialInput(); // Checks if the user wants to put in a new word.
if(digitalRead(BUTTON)){ // If the butten is pressed the program will start writing the currently stored word
delay(1000);
Write(); // Function that loops the WordArray in a switch wich calls the correct letterFunctions
delay(5000);
}
}
For what its worth, I tried moving around with the #define variables and I clicked on Fix encoding & Reload for a couple of times with no result...
EDIT: I counted the line numbers of the errors in my LetterFunctions file and the line numbers are on each new void i make.