Pages: 1 [2]   Go Down
Author Topic: DS1307 misbehavior  (Read 2096 times)
0 Members and 1 Guest are viewing this topic.
Switzerland
Offline Offline
Faraday Member
**
Karma: 108
Posts: 5144
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Try attaching it directly (max a few inches of wire) to the Arduino and nothing else (the DS1307 solely). If it doesn't work in this situation I'd also assume it's broken.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 42
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Strange things happen sometimes !
I have replace the entire setup with a new Arduino and a different shield for DS1307 this time a Duemilanove. Same thing: when the metal halide lamp came on in a matter of a few minutes the time went briefly to 00:00 and the light turned off. The next second the time was displayed correctly.

Next, I disconnected the metal halide SSR from the MCP23017 and fed it directly with a digital pin from Arduino. Same thing: when the metal halide lamp came on in a matter of a few minutes the time went briefly to 00:00 and the light turned off. The next second the time was displayed correctly.

The last thing that I can do is to replace the SSR with a mechanical relay. Let's hope this will work because I run out of hardware ideas  smiley-cry

Another way will be to control the metal halide ballast in a different way in software. Some thing like check for start time and if the answer is true start a timer in a countdown fashion. Is there any library that can do this ?

cheers,
MaLi
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 42
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Total failure so far ! Everything I tried did not work. I went ahead and removed the MCP23017 from the relay boxes and wired everything directly to Mega digital pins (reduce I2C  need). Still when the metal halide ballast comes on the time values read from DS1307 becomes unstable. Without, everything works perfect.
I went ahead and bought a DS3231 which is suppose to be less sensitive to EMI since the oscillator is incorporated. We will see.

Meanwhile, does anyone know how to reduce the noise coming from this ballast and make Arduino less sensitive ?

cheers,
MaLi
Logged

Switzerland
Offline Offline
Faraday Member
**
Karma: 108
Posts: 5144
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You could try to reduce the I2C speed (http://www.gammon.com.au/forum/?id=10896, look for "Timing"). Also I would try if shielding the connection between the Arduino and the RTC does help.
Logged

Norfolk UK
Offline Offline
Faraday Member
**
Karma: 69
Posts: 2555
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ferrite beads on the cables from the ballast or to the RTC or maybe RF chokes?
Logged


Pages: 1 [2]   Go Up
Jump to: