• Just got espruino running on a stm32f4discovery I ordered and received today... I'm a backer on kickstarter, but am beyond the "impatient developer" level...LOL!

    Anyway, here's a cool little demo you can run on the the f4discovery board:

    var i = 1000, run = true;
    function flashLights() {
    	LED4.write(false);
    	LED1.write(true);
    	setTimeout(function () {
    		LED1.write(false);
    		LED2.write(true);
    		setTimeout(function () {
    			LED2.write(false);
    			LED3.write(true);
    			setTimeout(function () {
    				LED3.write(false);
    				LED4.write(true);
    				setTimeout(function () {
    					if (run) {
    						flashLights();
    					}
    				}, i);
    			}, i);
    		}, i);
    	}, i);
    }
    flashLights();
    

    After executing it runs each of the leds in a circle with the given wait time between each flash. In the console you can modify the i variable to alter the flash rate while it's running. Then to stop it just put run=false. Once you get below i=70 you can't even really tell which direction they're flashing in they're going so fast!

    Cheers,
    Austin

About

Avatar for Austin @Austin started