Electronic Brick - Rotary Potentiometer Brick

Electronic Brick - Rotary Potentiometer Brick

Electronic Brick - Rotary Potentiometer Brick

Electronic brick of rotary potentiometer can be connected to analog I/O port, and the analog value will vary accordingly when rotated to different positions.

71 items in stock

Price:

1,80 €

Add to cart

Tinklapyje visos kainos nurodytos su 21% PVM.

No reward points for this product.

More info

Electronic brick of rotary potentiometer can be connected to analog I/O port, and the analog value will vary accordingly when rotated to different positions.

Data sheet

  • Width - 24 mm
  • Depth - 36 mm
  • Supply voltage - 3.3 / 5V DC
  • Connectors - 2.54 mm 3 pin / Grove
  • The method of transmission - Analog

Source codes

Connect S port of electronic brick of rotary potentiometer to A0 port of Arduino board, and we will use the following program to read its analog value and set the brightness of LED lamp according to the value.

int brightness = 0;    // šviesos diodo šviesumas
int led = 13;          // šviesos diodo jungtis
void setup()  {
 
  pinMode(led, OUTPUT); //nustatoma LED prievadas kaip išėjimas
}
void loop()  {
    brightness = analogRead(A0); //Nuskaitoma analoginė reikšmė
    brightness = map(brightness, 0, 1023, 0, 255);
    analogWrite(led, brightness); // Nustatomas led šviesumas 
}

25 other products in the same category:

Customers who bought this product also bought: