Pages: [1]   Go Down
Author Topic: Bug in Twitter Client example  (Read 588 times)
0 Members and 1 Guest are viewing this topic.
Sweden
Offline Offline
Newbie
*
Karma: 0
Posts: 1
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The twitter Client example are working once and don´t reconnect to download new tweet every minute.

This code need to be changed:
Code:
const int requestInterval = 60000;  // delay between requests

To this:
Code:
const unsigned int requestInterval = 60000;  // delay between requests

because a standard int can´t have a higher number then 32,767
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 547
Posts: 45982
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The variable really should be an unsigned long. Making the int unsigned only doubles its capacity, so 60000 is near the limit. Waiting 2 minutes then will overflow.
Logged

Pages: [1]   Go Up
Jump to: