//****************************************************** // M //****************************************************** void getInfo() { //HERE WE WILL GET THE INFO LIKE TEMP etc } void checkMenu() { lcd.setCursor(0,0); lcd.print("press * for info "); lcd.setCursor(0,1); lcd.print("1 air-assist 2 vent"); lcd.setCursor(0,2); lcd.print("3 watercool 4 laser"); lcd.setCursor(0,3); lcd.print("0 off 9 on"); char key = kpd.getKey(); } void menuKeypadEvent(KeypadEvent eKey) { switch (kpd.getState()){ case PRESSED: switch (eKey){ case '*': getInfo(); break; case '#': password.reset(); break; case '0': digitalWrite(airAssistPin, LOW); digitalWrite(ventilationPin, LOW); digitalWrite(waterCoolerPin, LOW); digitalWrite(laserEnablePin, LOW); digitalWrite(lichtPin, HIGH); // sets the licht pin (inverted) on digitalWrite(testEnablePin, LOW); // sets the test enable pin () digitalWrite(potMeterEnable, LOW); // sets the watercooler fans on break; case '9': digitalWrite(airAssistPin, HIGH); digitalWrite(ventilationPin, HIGH); digitalWrite(waterCoolerPin, HIGH); digitalWrite(laserEnablePin, HIGH); digitalWrite(lichtPin, LOW); // sets the licht pin (inverted) on // digitalWrite(testEnablePin, LOW); // sets the test enable pin () // digitalWrite(potMeterEnable, LOW); // sets the watercooler fans on break; case '1': digitalWrite(airAssistPin, !digitalRead(airAssistPin)); break; case '2': digitalWrite(ventilationPin, !digitalRead(ventilationPin)); break; case '3': digitalWrite(waterCoolerPin, !digitalRead(waterCoolerPin)); break; case '4': digitalWrite(laserEnablePin, !digitalRead(laserEnablePin)); break; case '5': digitalWrite(lichtPin, !digitalRead(lichtPin)); break; case '6': digitalWrite(testEnablePin, !digitalRead(testEnablePin)); break; case '7': digitalWrite(potMeterEnable, !digitalRead(potMeterEnable)); break; default: password.append(eKey); } } }