2 Replies Latest reply on Aug 6, 2015 4:01 PM by rve150

    Time date setting within Galileo g2

    rve150

      Dear Galileo Gen 2 enthusiasts,

        Am having a hard time in deciphering on making time/date stamp from the Galileo.

      Am new to Linux and Javascript.

       

      In the program, I run now, I manage to extract the time & date stamp along with the Temperature and Light Lux values from the corresponding sensors

      See code fragment below.

      //sensor readings to console 

          console.log("Date: "+date.getTime().toString()+", Temp: "+tempValue+".Celcius...Light: "+lightValue+"Lux:..."); 

       

      The console output is given below and also attached as screenshot.

       

      Date: 1438857622138, Temp: 34.Celcius...Light: 76Lux:...                                                                                                                                                                                                           

      Date: 1438857623229, Temp: 34.Celcius...Light: 76Lux:...                                                                                                                                                                                                           

      Date: 1438857624270, Temp: 34.Celcius...Light: 76Lux:...                                                                                                                                                                                                           

      Date: 1438857625315, Temp: 34.Celcius...Light: 76Lux:...                                                                                                                                                                                                           

      Date: 1438857626362, Temp: 34.Celcius...Light: 76Lux:...                                                                                                                                                                                                           

      Date: 1438857627413, Temp: 34.Celcius...Light: 76Lux:...                                                                                                                                                                                                           

                                                              

       

      Would like to have some tips in either adapting my Javascript code to make it more sensible in terms of reading out the Date and Time Stamps correctly.

       

      Alternatively, I realised that the Time Zone is not right within Galileo

      Was looking at the following thread but am lost.I am unable to access the TZ variable or install the ntp package.

      https://communities.intel.com/message/227862

      Am in the CET time zone.

       

      Any advise is highly appreciated.

       

      Regards

      Rama