prot. 01 - Lighting

Aggiornato il: 11 giu 2019

Aim: fading light effect


Materials:

- LED , All LED 16mm Dia. 1 Watt IP44 LED Marker Light

https://www.bltdirect.com/all-led-16mm-dia-1-watt-ip44-led-marker-light-warm-white-white-finish


- Led driver

https://www.robotshop.com/uk/femtobuck-led-driver.html


- Mean Well APV-12-12, Constant Voltage LED Driver 12W 12V 1A

https://uk.rs-online.com/web/p/led-drivers/7381577/



FemtoBuck LED Driver


FemtoBuck LED Driver Connections



Led to test


Video of fading Led



After the concept has been tested with success I had tested the LED that will be used for the actual prototype:






Code:


*/

int ledPin = 9;    // LED connected to digital pin 9

void setup() {

  // nothing happens in setup

}

void loop() {

  // fade in from min to max in increments of 5 points:

  for (int fadeValue = 0 ; fadeValue <= 255; fadeValue += 5) {

    // sets the value (range from 0 to 255):

    analogWrite(ledPin, fadeValue);

    // wait for 30 milliseconds to see the dimming effect

    delay(30);

  }

  // fade out from max to min in increments of 5 points:

  for (int fadeValue = 255 ; fadeValue >= 0; fadeValue -= 5) {

    // sets the value (range from 0 to 255):

    analogWrite(ledPin, fadeValue);

    // wait for 30 milliseconds to see the dimming effect

    delay(30);

  }

}

Experimenting with the actual prototype



Fading Led inside pipe programmed by Arduino




Links:


tutorial fading

https://www.arduino.cc/en/Tutorial/Fading



23 visualizzazioni
  • White Facebook Icon
  • White Twitter Icon
  • White Google+ Icon
  • White Instagram Icon