Most microcontrollers (Espruino included) can only measure analog voltage... So if you want to measure something you'll have to convert it into either a voltage, or interface digitally to a device that will read what you want.
For current, the easy solution is to connect the GND wire of what you're measuring via a resistor (1 ohm? it depends on the amount of current). Then you can measure the voltage on the other side of the resistor and work out current based on that.
For more serious applications, you can get these really neat hall effect current sensors like the ACS712 that convert current into a voltage and isolate as well.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
That's a bit of a broad question :)
Most microcontrollers (Espruino included) can only measure analog voltage... So if you want to measure something you'll have to convert it into either a voltage, or interface digitally to a device that will read what you want.
For current, the easy solution is to connect the GND wire of what you're measuring via a resistor (1 ohm? it depends on the amount of current). Then you can measure the voltage on the other side of the resistor and work out current based on that.
For more serious applications, you can get these really neat hall effect current sensors like the ACS712 that convert current into a voltage and isolate as well.