Help me Complete a Project for Valentine's Day for my GF.

Hello, recently I came across this project called Valentineduino which uses an arduino pro micro + an rtc + serial segment display to project the days that you and your GF have been together.

Project Page: Valentineduino – Vegard Paulsen

Github Page: https://github.com/subsoniq/valentineduino

I decided to build this projevt for valentine's day for my GF, but I depserately need your help...

I''m using and arduino Leonard, an rtc ds3231 and a 7-segment serial display.

The code has a bunch of extra stuff that I do not need, but anyways whenever I try to compile the project I get that a bunch of variables have not been declared in this scope. I'm trying to figure out the problem but I simply cannot. Can anyone take a look at the code and suggest a solution? I can upload my schematics if you need it. Thank you in advance!

(deleted)

Ntdark:
Can anyone take a look at the code

What code? You didn't post any code. Or a schematic...

Hey sorry, I get a bunch of errors about different variables not declared in this scope (void setup) I tried moving some functions before the void setup and I eliminated some of the errors but for example:

void loop() 
{   
  time_t t = now();
  days = ((now() - theDateWeGotTogether) / 86400);

In this part I cannot dismiss the error " 'now' was not declared in this scope" and " 'days' was not declared in this scope"

Why are you refusing to help us?

Have you installed all libraries necessary?

larryd:
Why are you refusing to help us?

Have you installed all libraries necessary?

Yes I have. I am not refusing to help you, I cannot post any more than one reply every 5 minutes apparently...

Don’t see your full code or your schematic.

No patience left.

The code is in the github link. I said it 3 times. Here it is: (Valentineduino file)

If you need the schematic just ask me to upload one. You never asked me to upload a schematic…

Valentineduino.txt (10.3 KB)

(deleted)

First of all, I do not disrespect any of you and I feel obliged ofr helping me out.

Second, I uploaded a txt of the code cause when I try to upload an in file I get an error saying .ini are not supported filetypes.

I will upload the first part of the code where I receive the first error:

#include <DallasTemperature.h>
#include <Time.h>
#include <RtcDS3231.h>
#include <SPI.h>


const int  cs=8; //chip select for the rtc
const int rfPowerPin = 2; 
const int ledPin = 13;
const int openEventPin = 12; 
#include <NewSoftSerial.h>
NewSoftSerial nss(4,5); 

//Arduino compiler version 0023 was used on this project, alot of new versions are coming these days and not every library works the same way as before. If you run into problems, revert to v. 0023
//Regards Vegard Paulsen    www.vegardpaulsen.wordpress.com

char clientId[] = "clientId=03&"; //12 char
char tempSensorId[] = "sensorId=03&" ; //12 char
char lightSensorId[] = "sensorId=40&" ; //12 char
char dataTypeFloat[] = "dataType=float&data=" ; //20 char
char dataTypeInt[] = "dataType=int&data=" ; //18 char
char dataTypeChar[] = "dataType=char&data=" ; //19 char
char checkData[] = "&check" ; 
int counter = 0 ; 
unsigned long previousMillis = 0;        // will store last millis event time 
unsigned long sensorpreviousMillis = 0;        // will store last millis event time 
unsigned long fiveMinuteInterval = 300000;           // interval at which to use event time (milliseconds)
unsigned long postDaysInterval = 7200000 ; //seconds in a day 86400000
float temperature = 0 ; 
int openEvent = 1; 
int lightValue = 0; 
int TimeDate[7]; 


DallasTemperature tempSensor; // You may instantiate as many copies as you require.

unsigned long theDateWeGotTogether = 1194242400   ;  //in unixtime
unsigned long days ; 
int weeks ; 

const int MAX_CMDLEN = 70;
char cmdBuffer[MAX_CMDLEN+1];
int cmdLen;
int openState = 0; 
unsigned long unixTime; 


void setup() {                
  Serial.begin(9600); 
  nss.begin(9600); 
  tempSensor.begin(7); // Data wire is plugged into port 10 on the Arduino
  ClearLcd();
  RTC_init();
  SetTimeLibraryFromRTC();
  pinMode(ledPin, OUTPUT); 
  pinMode(rfPowerPin, OUTPUT); 
  pinMode(openEventPin, INPUT); 
  digitalWrite(rfPowerPin, HIGH); 
  CheckTemperature(); 
  delay(3000); 
  LoveYouLcd() ;
  delay(100); 
  sendEverything(); 

  // adjustTime(1297641590); //used to try the code without knowing the right time. just paste in the unixtime you know 

}

void loop() 
{   
  days = ((now() - theDateWeGotTogether) / 86400); //magic nubmer 86400 is the number of seconds in a day 
  unsigned long currentMillis = millis();   
  ShowDaysReading();     
  time_t t = now();
 
  
  if ( 5 == day(t)  &&  11 == month(t)  ) 
  {
    delay(5000); 
    LoveYouLcd() ;
    AnniversaryLcd() ; 


  }   

  if(currentMillis - sensorpreviousMillis > fiveMinuteInterval) 
  {
    // save the last time you performed event
    sensorpreviousMillis = currentMillis;   
    sendEverything(); 
    SetTimeLibraryFromRTC();




  }

}

Whenever I compile it I get the below message:

exit status 1
'RTC_init' was not declared in this scope

I have tried both the time.h library and the rtcds3231. Thank you again in advance. Forgive me if I sounded disrespectfull, it wasn’t my intention at all.

Change this line:

#include <Time.h>

to:

#include <TimeLib.h>