Software Design Considerations Team 15
Code Modules • Web Server • Interface and Operating Parameters • Chemical Level Detection • Calibration Routine • Adjusting Agent Calculation • Chemical Introduction Routine
Web Server • Use web server embedded in micro to view data and change parameters • Will be able to view database of Ph, Cl, and temp levels • Also can view if any tanks are empty • Can change Pool Volume, desired Ph and Cl levels, and desired temperature.
Interface and operating parameters • Performs functions much like Web Server, however changes can be made from the unit. • Unit will display latest Ph, Cl, and temp levels on an LCD • Same parameter changes can be made from the Unit as can be made on Web Server.
Chemical Level Detection • Using the ATD channel get a voltage reading that corresponds to a Ph, Cl, or temp level • Water will be pumped into a chamber where the measurements take place Calibration Routine • Using two buffer solutions, create a linear function for the Ph Sensor.
Adjusting agent calculation • We will use a formula found online that will calculate how much Ph and Cl adjuster will be needed to introduce. Chemical Introduction Routine • Chemicals will be pumped into pool and measured as they are introduced.
Hierarchical Block Diagram Main Calibration Routine Adjusting Agent Calculation Chemical Introduction Routine Ethernet RTI SPI ATD Web Server Push Buttons LCD Chemical Level Detection
Start Main State Machine Web Server (view data and set parameters) Push Buttons Time for calibration? No Time to measure chemical levels? No Scroll through menus and Adjust values Yes Yes LCD Output Variable Parameters MeaureCl and Ph Introduce buffer solution 1 Variable Parameters: Desired CL Desired Ph Desired Temperature Pool Volume Variable Parameters Calculate amounts to introduce Save recorded voltage Introduce chemicals Introduce buffer solution 2 Saved Data: Archive of Ph and Cl values Voltage reading for Ph meter Save recorded voltage