Hi my name is Cody, have had an Arduino Uno for a couple years, but still an amateur building on my skills every other month or so.
Ik most the basics and am trying to make a more interactive program besides just blinking lights, etc. I have a handful of sensors, particularly a joystick. I got it all setup and can view the X/Y on the monitors and even have IF statements to tell me what quadrant the joystick is in like a TIC TAC TOE board I.e. (upper l, upper middle, upper right, etc.).
My project idea is to use 9 LEDS and have them turn on/off as I move the joystick around just as a practice programming joystick movement. I haven’t wired the LEDs yet, but initial thought was to hard wire each LED to a PIN and IF the joystick is in that quadrant to turn the LED to HIGH… overall not to complicated, except for the fact that I don’t think I have enough pins w/ the joystick or if I do none will be left for any other functionality I.e. another sensor, LCD, etc.
Is there a smarter way to tell an individual pin to turn on/off without using 1 pin per LED?
I was thinking of trying to give each row & column a number 1-3 (total of 6 pins: 3x + 3y) and say it’s in the upper right square send a signal through all 3 right hand squares, but only send the signal through the top row of squares i.e. where the 2 signals intersect would be the only square getting full power (don’t mean changing the power output per say, though maybe that is an option… just mean if that square gets 2 YES indicators to turn on)
So if you made it a 4x4 grid instead of needing 16 pins you’d only need 8?
Ik this is a very roundabout question for a very simple project, but feel I have seen people get more functionality out of an UNO than just a joystick and 9 LEDs, but unsure how I could wire it without the number of pins I’m using going through the roof or needing multiple boards.
Any advice or suggestions appreciated!
Edit: searching on YT I have seen things for “chasers” and Cubes, but think the difference between these and what I want to do is individual control… I.e. a chaser, all the LEDs are getting the same input, but delayed… think I similar thing is done with the cubes so even though it’s an 8x8x8… not every LED is getting it’s own signal… still investigating


