10-key macropad keyboard with LED indicators

I would like to use a small Arduino board as the basis of a 10-key HID with LEDs for each key. I guess the LEDs would be able to stay on or flash or pulse depending.

I would like the LED state to be modifiable by keypresses but also the state of the computer. Thus I could press a key to induce a certain state which will be reflected by the LED but the state could be changed by another route (say with the mouse) and then this should be communicated to the Arduino to turn off the LED.

I've seen a lot of macropads/keyboards being made with Arduinos but I can't find anyone doing them with indicator lights. I'm just intent on using single-colour LEDs.

How many keys and LEDs can I attach to one of those miniature Arduino versions? Can I economise on the pins by setting up the keys in a funky way?

Do you mean one LED with each key? Then you can use shift registers or port extenders for so many buttons and LEDs.

Thanks for your response. I do want a separate LED for each key. It looks like there are 20 GPIO pins on the Arduino Pro Mini, right? So that would be enough for 10 LEDs and 10 buttons, right?

You may have to spend some pins for other purposes, e.g. for the communication of the keyboard state. Also during programming the circuit attached to RX/TX must be disconnected.

seanspotatobusiness:
How many keys and LEDs can I attach to one of those miniature Arduino versions? Can I economise on the pins by setting up the keys in a funky way?

You can use a keypad library to reduce to seven the pins needed for input.

If only one LED will be on at a time a similar technique can be used for output. Otherwise, you can dedicate one output for each LED.

The key is "multiplex" for a reduction of the number of pins. 10 switches or LED can be addressed by 5+2=7 pins, in 5 rows of 2
columns. Or with 3+4 pins for a 3*4 matrix, for up to 12 items. Additional hardware is required for addressing rows and columns of the matrix.