Go Down

Topic: RGB LED with pressure sensor. (Read 923 times) previous topic - next topic

03coupr

Hey, I want to control the colour with the pressure sensor but not to sure what code I should use?

The RGB I have is a Pirhana RGB, 4 pin.

If anyone has any idea of the code, that would be great 

Many thanks

PaulS

Quote
If anyone has any idea of the code, that would be great

analogRead() to read the pressure sensor and analogWrite() to set the RGB color values.

What color should 4 pounds be? How about 197?

PaulS

Quote
Im new with the arduino coding, not to sure what you mean by 4 pounds ?

You have a pressure sensor. When you apply 4 pounds of pressure, what color should the LED be?

There's a lot more to application development that just writing the code. Defining requirements, for one thing.

Go Up