CH552-USB-Knob
CH552-USB-Knob copied to clipboard
Help with CH552G and CH552E projects
Hello. I recently have built your macro pad mini, knob, and macro pad plus. So on the mini it accepts the firmware but nothing works but when the 3rd key is pushed it goes into boot loader mode. On the knob the firmware flashes and it appears to be working but in windows it keeps saying device is not recognized and disappears and reappears multiple times. Lastly, on the macro pad plus it is stuck in a boot loop, rebooting every second. Please reply because i want to get these to start working. Thank you a lot, Samuel
Puh, that's hard to tell from a distance with this less information. Let's take the volume knob as an example. How did you compile/upload the firmware? Did it work? If not, what was the error message. What Windows version do you use? What is shown in the device manager?
Do you have discord? Can we chat on there so I can debug easier?
I would like to call with my audrino ide on so you can help me debug easier
I apologize, but I don't have Discord, nor do I have sufficient free time for online debugging. Thank you for understanding.
With the smart knob I wired a usbc plug and it cycles the led correct but none of the microcontrollers are recognized in windows
Sorry if im not giving enough information. On all of the projects i am getting this error https://cdn.windowsreport.com/wp-content/uploads/2021/12/USB-device-not-recognized-Windows-10-886x590.jpg
Mmmmh, there is a DLY_ms(500) prior to HID_init(). Try to increse the time to DLY_ms(1000) OR remove WDT_start(); AND WDT_reset();
I just tried both of those and what the boards are doing is they are still having the same issues. They also play the connected and disconnected sounds over and over again until unplugged.
Strange, have you tried it on another computer?
Yes. It still does the same thing.
Any more ideas?
I found a PC with Windows 10 Pro, 64-bit, version 22H2 (I'm only using Linux) and re-tested it. It worked without any problems. However, I can not rule out some compatibility issues of the firmware on Windows PCs. Since you don't have problems uploading the firmware I think that this isn't a hardware issue. Unfortunately, since I cannot reproduce the error at the moment, I am currently unable to identify the cause.
When plugged in it gives me a error message saying that it malfunctions. Are there any modifications in the code that I can make?
I modified your design @wagiminator and ripped the gnd vcc datap and datan and replaced it with a usb c plug. That's the only mod I did to it. I'm not sure if that modification changed anything
Could it have anything to do with the device descriptor?
Also, when I turn the knob it stops changing colors and I think it freezes up. I can't get it to work on an Ubuntu machine either
It shouldn't really be the USB connector. You don't seem to have any issues with uploading the firmware, which also utilizes the USB connection to the microcontroller. If it doesn't even work under Ubuntu, then something's definitely off - but I currently have no idea what. How did you compile the firmware? Have you tried uploading the precompiled .bin file?
I'm not sure on how to do that. I just used audrino ide
Ah, maybe the Arduino IDE is the problem. Did you make the correct USB-settings in the board options?
Please download WCH's official programming tool: https://www.wch.cn/downloads/WCHISPTool_Setup_exe.html Try to upload the precompiled binary (.bin file in the software folder) with this tool.
The .bin worked but not arduino. How do I customize the code inside of the bin file?
new problem. It sometimes disconnects and reconnects, causing the volume to rapidly increase or decrease by two marks
That can sometimes be due to different versions of the Arduino IDE and Board Package. Unfortunately, I don't remember which version I used for testing back then. Generally, I work without an IDE, so I use the makefile. However, I don't know how to do that on Windows either.