This is a simple project consist of the Micro Limit Switch as a triggers to toggle the visuals of the LED Module. The switch will be placed inside at the bottom of the pen stand case to allow pen to press on it and triggers the LED Module Matrix. The visuals are coded with Arduino IDE and then uploaded to the Arduino.
First of all, two LED module (MAX7219 LED ) and female jumper wires are required in order to connect the Led module with the Arduino.
Later on, after you have done connecting the Led modules together with the Arduino ( refer to schematic diagram) , it is now time to use your MicroSwitch to act as a button. When the switch is triggered, visuals are toggled on.
The diagarm 2 above shows the schematic for the microswitch. To allow the microswitch to act as a button. Kindly connect the C (Common) to the PIN 12 of your Arduino , NO (Normally Closed) to the 5V PIN in your Arduino and NC (Normally Open) to the GRND PIN in your Arduino. A breadboard is recommended as the LED Module and the microswitch both requires voltage. Therefore, extending the 5V PIN is the best option to provide both components with voltage.
Next, it is now time for the case to keep everything organised.
The case in diagram 4 is a self-made case. You can come up with any kinds of shape as long as it keeps everything organised.
Furthermore, make a another self-made pen case and place your microswitch below the case. The purpose of the case is to provide a spot to place the microswitch and ensure that the pen is able to apply pressure onto the switch to toggled the LED Module.
Due to the fact that the LED Module have PINS that are designed for jumper wires to connect them which microswitch doesn't have. You are required to get the borderless wires to connect the microswitch to Arduino.
Finally, upload the code to your Arduino board and be sure to download the library from GitHub and include it in your Arduino IDE. Links are provided at the code section.
Comments