# Reduced accuracy of millis with 0.5.0-rc.1 (ELECTRON)

**URL:** <https://community.particle.io/t/reduced-accuracy-of-millis-with-0-5-0-rc-1-electron/22005>\
**Category:** Firmware\
**Created:** [April 11, 2016, 5:24pm UTC](https://community.particle.io/t/reduced-accuracy-of-millis-with-0-5-0-rc-1-electron/22005 "2016-04-11T17:24:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![developer\_bt](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/developer_bt/32/1311_2.png) [@developer\_bt](https://community.particle.io/u/developer_bt)\
**Post date:** [April 11, 2016, 5:24pm UTC](https://community.particle.io/t/reduced-accuracy-of-millis-with-0-5-0-rc-1-electron/22005/1 "2016-04-11T17:24:37Z")

</div>

I noticed Reduced accuracy of millis.  
I do not know if the problem is up to the new firmware, but zablezhav that after each cycle 1 to 2 minutes get an extra second.  
The program sends data to the server via HTTP every minute.  
This is a block of a program, the program is a bit more complicated than just this but this section is of interest.

```
long previousMillis = 0;      
long interval = 60000; 

void loop(){
 unsigned long currentMillis = millis();

  if(currentMillis - previousMillis > interval) {
    
    previousMillis = currentMillis;

           SEND_TO_SERVER();

       }

   }

```

For example, if the data is sent in 1:00:15 next be sent to  
1:01:16, 1:00:16, 1:00:17 and the like.  
With the older firmware I have not noticed this problem.  
Now I switched to using software timers and works great.  
But better and another to make testing with simplest use of millis.
