Pull code from network

Hi, newbie here

I have a project where I want my arduino UNO to steer a machine that pours certain amounts of liquids into a container, according to certain recepies. I realized that the memory of the UNO is a bit tight for several recepies, so I wondered if it is possible to code the UNO to request the code for a certain recepie over wifi and execute the code, triggered by the push of a button? like if I set up all definitions for motors and such on the board locally, and with an IF statement pull the recepie form somewhere else.

I’m attaching the code I got so far, which serves a shot of vodka in a glass. it would be nice if the code in some way could get code under the IF statement for the desired recepie. I have not yet added the code for the wifi connection but I got a good idea of how to get it connected to my LAN.

sketch_stepper_drinkmachine.ino (2.27 KB)

so I wondered if it is possible to code the UNO to request the code for a certain recepie over wifi and execute the code, triggered by the push of a button?

No, it is not.

Your “recipes” aren’t code, anyway.

You could have a recipe for “Vodka shot”:
Position 720
Dispense 2000
Position -720

Getting this data from outside the Arduino is not hard.
Parsing the data is not hard. Calling an appropriately named function is not hard.

What isn’t obvious is how you would dispense other liquids, such as rum, whiskey, bourbon, wine, etc., or ice, or mixers (rum and coke, for instance or, having just gotten back from Hawaii, a Mai Tai), or how you’d operate a blender to make a daiquiri.