“When”, a new Neptune Systems Apex Command

Marcin SmokBy Marcin Smok 2 years ago
Home  /  Equipment  /  “When”, a new Neptune Systems Apex Command

Neptune System Apex It’s not often that we see Apex programming language expanded with new commands, so I was pleased to see that with the recent update, version 4.52 firmware update for Apex Classic/Gold, Apex Lite and Apex Jr models, a new “When” statement has been added to the list. Its introduction correlates with the release of Neptune Systems latest offering, the ATK Auto Top Off Kit, which has just been released (full review coming soon!). As a control freak who uses Apex programming to operate all my reef equipment, I was curious to see how the new “When” command can be used to enhance the Apex experience and help prevent tank disasters. The Apex firmware update version 4.52 is already out and can be downloaded HERE. It’s a mandatory update for Apex to be able to communicate with the new ATK and follows the same update process as all previous Neptune Systems firmware updates. If you’ve never attempted to update your Apex, please refer to the instructions included in the zip file under name readme.txt. After the update has been successfully installed, “When” command is immediately available and will appear as a statement in Apex Fusion code editor. Neptune System Apex “When” command has been designed to work almost exclusively with timed devices, such as an auto top off pump. This type of pump, when operating properly, should be on for a short amount of time and then shut itself off when triggered by a water level sensor, but the number one cause of ATO failure is a stuck sensor that does not command the pump to stop dumping water into the tank. “When” offers the software equivalent of a backup sensor and can be programmed into any outlet controlled by Apex. Let me explain with a real-life example- I currently use PMUP, Neptune Systems small pump, to pump water from the ATO container to the sump. PMUP is connected to WAV 1LINK module and has an outlet named simply ATO. Here’s how the code looked like before “When” command was available: Fallback ON Set ON If FeedB 000 Then OFF If Lback CLOSED Then OFF If Ltank CLOSED Then OFF If Lovfl CLOSED Then OFF If Overfl CLOSED Then OFF If Lato CLOSED Then OFF If SumpL OPEN Then ON If SumpH OPEN Then OFF Where {Lback, Ltank, Lovfl, Lato} are leak detection probes located in various spots around the aquarium, {Overfl} is an optical sensor positioned high in the overflow box that prevents the main display tank’s water level from reaching a dangerous point, {SumpL} turns the ATO pump ON when water level gets low in the sump and {SumpH}  is an optical sensor that triggers the ATO pump to turn off when replenishing evaporated water is done. Neptune System Apex When introduced to the line of code, the “When” command gives an additional level of security against any of the ATO system components failure. The complete program looks like this: Fallback ON Set ON If FeedB 000 Then OFF If Lback CLOSED Then OFF If Ltank CLOSED Then OFF If Lovfl CLOSED Then OFF If Overfl CLOSED Then OFF If Lato CLOSED Then OFF If SumpL OPEN Then ON If SumpH OPEN Then OFF When On > 000:45 Then OFF The last line of code with “When” command will shut the ATO pump down if it is ON for more than 45 seconds. I had observed that every time my ATO is turned on, it refills the sump in less than 30 seconds, so it being on for more than that would be highly suspicious, and therefore I decided 45 seconds is the maximum time it should be operational at each refill. “When” can be programmed into any outlet that needs to be monitored for its ON timeframe, for example water change pumps, ATOs, dosing pumps, etc. In addition to “When”, Neptune Systems extended the functionality of yet another statement, “If Error”. That command has been available since WAV pumps came out and it used to be functional only in conjunction with WAV outlets. With the 4.52 firmware update, Apex now allows that command in to be used in any outlet programming. Its usefulness is mostly visible when used in the EMAIL outlet as a follow up action to the “When” command being initiated. Here’s an example code to add to EMAIL outlet, based on the previously-discussed ATO outlet: If Error ATO Then ON The “When” command alone takes action to cut power to a given outlet, but it doesn’t inform the user of this happening. That’s when “If Error” comes into play- that command, followed by the name of the outlet (in our case ATO) will send a text message/email to the user if “When” command is being executed. In summary, the new “When” command gives yet another layer of automation and security to Apex; it’s a welcome addition to Apex programming language and an easy way to safeguard your aquarium against equipment failure.

  Equipment, Industry, Technology
Marcin Smok

 Marcin Smok

  (246 articles)

Marcin Smok is a reefer, photographer, traveler, SCUBA diver and avid DIY-er. He has been keeping freshwater fish tanks since he was 9 years old and saltwater tanks for the past 7 years. Check his photography site at www.travelibn.com and follow his Facebook profile https://www.facebook.com/photoreef/

this post was shared 0 times