Bilibili video link: https://www.bilibili.com/video/BV13B4y1n72a
I made this pendant because I saw the video of the director of the workshop. It's interesting, so I made one too. But I have never heard of the main control used by the director of the workshop, and I haven't learned Arduino yet. I just downloaded Arduino IDE the day before yesterday and now I don't understand anything. The open source link of the director of the workshop: https://oshwhub.com/shukkkk/ws2812-diao-zhui. So I made one from start to finish, but it was a scaled-down version. I haven't used 2812 yet, so I used a single-color lamp bead. I'll dig a hole first, and I must make a standard version.
There are two versions of the pendant, the difference is the io connected to the button. "Monochrome" is connected to P55; "Monochrome_Power-off Mode" is connected to P32. The first version was a mistake, and it didn't receive an interrupt, so the program was difficult to write; the second version had no problem, but the program had not been modified specifically for it. There are a few single patterns, which are very simple to write, and I can't write complex ones. The next step is to integrate the individual patterns together and use interrupt switching. There is a power-off wake-up test program in the attachment. The power-off current is only 0.45 microamperes. A 2032 has 220 milliamperes, and the theoretical standby time is 550,000 hours, which is completely sufficient. V3.0 will probably remove the mechanical switch.
The working current of the pendant:
2032 3V power supply, red, full light, 100 brightness, 13 milliamperes;
2032 3V power supply, green, full light, 100 brightness, 6 milliamperes;
2032 3V power supply, blue, full light, 100 brightness, 5 milliamperes;
The chip used is STC8G1K08. The io of this chip is high impedance by default. The io mode must be set before programming. The dot matrix screen I made during the summer vacation was here. I debugged the program for two or three days, but the result was that the io was not set! ! !
There is a key switch program in the attachment. The hardware adaptation is the first version. It is also easy to change to the second version. There are no various macro definitions in the program. They are all defined by a single pin. Just change the key definition. There is a bug in the program. When a pattern is not completed, the button is invalid, so I treat the button as a long press.
If someone is making a board, it is recommended to make the second version. Be sure to pay attention to the thickness, which is 1.0. If it is too thick, the lamp beads cannot be soldered. I made the first version with a thickness of 1.2, which can be soldered but not easy to solder. If you want it to be stronger, you can use 1.2. The narrowest part of the board is only 5 mm. If it is too thin, there is a risk of breaking. The lamp beads are attached to the side, so that the front and back look the same, and there is no front and back.
Regarding welding, I use solder paste with a heating table for normal SMDs. For special welding methods such as LEDs, you can only solder them by hand. The soldering iron first tins the pad on one side, then the board stands up and fixes it, and clamps the lamp beads with tweezers. Solder one side to fix it first, and then solder the other side. It's been a lot of trouble. It took me several hours to make these three RGBs, working from day to night.
There is a watermark for testing on the PCB, and you must be careful to remove it when making the board.

Regarding this version number, my own rule is: if the circuit is changed, the program is not universal, the number in front is increased, 1.0 to 2.0; if the layout, size, etc. are changed but do not affect the circuit, the program is universal, the number at the end is increased, 2.0 to 2.1. How do you define this version number?
The attachment is a compressed package of five programs.