Hi all,
I’m mounting a system which, upon the pressure of a button, senses and stores the temperature, takes 2 different pictures (with 2 different cameras), and stores everything on a SD card.
Everything works fine, but… Something very weird is happening with the temperature sensor, which is a DS18B20. The message “No more adresses” pops up on all even clicks! So I click once for the first measurement, everything runs fine. Then, for the second measurement, everything runs fine except the temperature sensor which give me the “No more adresses” error. The 3rd time, it will work again, but the 4th no, etc.
As an example, this is the terminal output for 4 consecutive clicks (and it consistently follows that pattern):
-------------------------------------------------------------------
Measurement started for following cell:
Set: 2 Cell: 2
CSV File created.
Sky capture Done! Image saved in: /261016/Sky0202.jpg
Pyranometer capture Done! Image saved in: /261016/Pyr0202.jpg
Logging to: /261016/02021531.CSV
ROM = 28 FF 23 55 80 16 4 E2
Chip = DS18B20
Data = 1 80 1 4B 46 7F FF C 10 67 CRC=67
Temperature = 24.00 Celsius, 75.20 Fahrenheit
Temperature,date,time,picture_sky,picture_pyranometer
24.00, 26/10/2016, 15:31:31, /261016/Sky0202.jpg, /261016/Pyr0202.jpg
-------------------------------------------------------------------
Measurement started for following cell:
Set: 2 Cell: 3
CSV File created.
Sky capture Done! Image saved in: /261016/Sky0302.jpg
Pyranometer capture Done! Image saved in: /261016/Pyr0302.jpg
Logging to: /261016/03021531.CSV
Temperature,date,time,picture_sky,picture_pyranometer
No more addresses.
-------------------------------------------------------------------
Measurement started for following cell:
Set: 2 Cell: 4
CSV File created.
Sky capture Done! Image saved in: /261016/Sky0402.jpg
Pyranometer capture Done! Image saved in: /261016/Pyr0402.jpg
Logging to: /261016/04021531.CSV
ROM = 28 FF 23 55 80 16 4 E2
Chip = DS18B20
Data = 1 7C 1 4B 46 7F FF C 10 7F CRC=7F
Temperature = 23.75 Celsius, 74.75 Fahrenheit
Temperature,date,time,picture_sky,picture_pyranometer
23.75, 26/10/2016, 15:31:51, /261016/Sky0402.jpg, /261016/Pyr0402.jpg
-------------------------------------------------------------------
Measurement started for following cell:
Set: 2 Cell: 5
CSV File created.
Sky capture Done! Image saved in: /261016/Sky0502.jpg
Pyranometer capture Done! Image saved in: /261016/Pyr0502.jpg
Logging to: /261016/05021532.CSV
Temperature,date,time,picture_sky,picture_pyranometer
No more addresses.
Isn’t this weird?
I would like to paste my code here but it is quite long. If I should, please mention it. For now, I will attach it to this post.
Thanks a lot for any hints!
sketch_sep30a_pressbuttons_LCD_SD_RTC_CAM_DS18B20.ino (20.5 KB)