Software
Overview → PCB → Components → Sensor → Enclosure → Software → Valve → Installation
Sunfy328 provides the following functionalities that can be managed using a three buttons interface:
- Real-time clock with optional, automatic daylight saving management. Geolocalization of the unit to know the local sunrise and sunset and consequent day length. Fractional timezone management. Leap years management. Clock calibration.
- Two independent alarms. They can be set to open the valve at a specific time or to open the valve following sunrise and sunset throughout the year. The valve can be opened for a duration between 1 minute and 3 hours. Optionally, the duration can be automatically adjusted accordingly to the season* and give more water during summer, and less water during winter. Waterings can be every day or can follow a specific period of days. Optionally, Sunfy328 can automatically adjust this period, from watering every 3 days during winter to watering every day during summer. The alarm can skip watering when the humidity level provided by the moisture sensor overcomes a certain percentage.
- Immediate watering with timer, to manually open the valve whenever you want.
- Skip Ice functionality, to protect the plants and the valve from frost.
- Extra watering after heatwaves.
- Temperature can be measured in Celsius or Fahrenheit.
- Recording of the minimum and maximum temperature of the day.
- Date-time recording of the last watering of each alarm.
User's Manual
A PDF of the user’s manual is available from here.
Download Sunfy328 Software
The default version of the software works with a 128x64 SPI display SSD1306/SSD1309.Sunfy328-main.zip
Open Source Code
If you want to use a different display (for ex. a 1.3" I2C display with a SH1106 controller), or modify other system settings, you need to apply the changes to the source code and compile it to a new .hex file.
The code is well commented and you will find the system settings at top of it.
The code has been developed and compiled using the Arduino IDE.
Source code: https://github.com/Ipposnif/Sunfy328
Upload To The Control Unit (Using Windows)
ALWAYS DISCONNECT THE POWER CABLE FROM THE POWER GRID WHEN OPERATING ON THE PCB.With a USBTinyISP programmer you can use the files in the zip without any change. This cheap small programmer works very well for the scope.
If you have a different AVR programmer, you need to configure the file upload.bat accordingly with it.
You need also a USB to Micro-USB data cable to connect your PC to the programmer, and a JTAG ISP 3x2 pins 2.54 cable to connect the programmer to the control unit (port P5).
Be sure to plug the JTAG cable with the correct orientation, using as reference the red band on the cable and the white dot printed close to the port on the PCB and on the programmer.
This programmer comes without an enclosure; to prevent accidental short circuits, it is adviced to wrap it with a heat shrinking sleeve or some electrical tape.
To let your PC to speak with USBTinyISP, install the driver and restart the PC.
You can download the same driver from this different link.
Unzip the content of the zip to a new folder and run upload.bat with a double-click.
If everything goes well you will see a CMD screen confirming a successful upload.