I am using an Arduino Uno, with a 4x4 matrix keypad, 16x2 LCD display. How do I give float data as an input to be stored into EEPROM?
How do I give float data as an input to be stored into EEPROM?
float pi = 3.14159;
int addr = 3;
EEPROM.put(addr, pi);
Getting a float from the keypad is a whole 'nother issue.
PaulS I want to able to give the float input using the keypad only. I have seen one of the keypad examples which demonstrates to create an entirely different keymap for using a single keypad with two different keymaps! Is that method feasible since I only want to have only a decimal point as an extra character from the keypad?
GautamD:
PaulS I want to able to give the float input using the keypad only. I have seen one of the keypad examples which demonstrates to create an entirely different keymap for using a single keypad with two different keymaps! Is that method feasible since I only want to have only a decimal point as an extra character from the keypad?
I used these :http://www.ebay.com/itm/Button-Keypad-module-4x4-One-analog-out-Simple-connection-to-Compatible-/162627101545?hash=item25dd54a369" on my oven project. You can put your own key IDs under the caps. There is code in the IDE examples to use the keypad. So, you can identify one key as a decimal point if you wish.
I added a translation table to the key coding sample logic to give me the code corresponding to the top of the keycap.
Paul
Okay I shall look into it. Thanks.