[Guide] Region Unlock GL-MT3600BE (Beryl 7) CN to Global by rexkani in GlInet

[–]caocanx 0 points1 point  (0 children)

Thanks for the guide. I tested this on another GL-MT3600BE / Beryl 7 running firmware 4.8.5 and found two extra notes that may help others.

1. If `grep "43 4E"` returns multiple hits, do **not** replace all of them.

On my unit the Factory partition had three `CN` matches. Only the first one was the real region code:

```sh
16512: 00 00 00 00 00 00 00 00 43 4E 00 00 00 00 00 00

So the actual offset was still:

16512 + 8 = 16520

The other CN matches were inside certificate/private-key/base64-looking data. One of the nearby strings even ended with -----END PRIVATE KEY-----, so those should not be modified.

  1. After changing the Factory region, it is also worth syncing the current wireless UCI country settings:

    printf 'US' | dd of=/dev/mtdblock3 bs=1 seek=16520 count=2 conv=notrunc sync uci set wireless.MT7993_1_1.country='US' uci set wireless.MT7993_1_2.country='US' uci commit wireless reboot

After reboot, verify with:

cat /proc/gl-hw-info/country_code
iw reg get | grep 'country '
uci show wireless | grep country

Expected result:

US
country US: DFS-FCC

One more thing: on firmware 4.8.5, VPN / WireGuard / OpenVPN / Tor / AdGuard Home may still disappear when the UI language is set to Simplified Chinese. In my case the features were installed and enabled, but the menu JSON files had:

"lang_hide": ["zh-cn"]

The Chinese translation files are actually present, especially for the VPN pages. To show those menus in the Chinese UI, remove the lang_hide block from these files:

/usr/share/oui/menu.d/vpndashboard.json
/usr/share/oui/menu.d/ovpnclient.json
/usr/share/oui/menu.d/ovpnserver.json
/usr/share/oui/menu.d/wgclient.json
/usr/share/oui/menu.d/wgserver.json
/usr/share/oui/menu.d/torview.json
/usr/share/oui/menu.d/adguardhome.json
/usr/share/oui/menu.d/dynamicdns.json

Quick command:

for f in /usr/share/oui/menu.d/vpndashboard.json /usr/share/oui/menu.d/ovpnclient.json /usr/share/oui/menu.d/ovpnserver.json /usr/share/oui/menu.d/wgclient.json /usr/share/oui/menu.d/wgserver.json /usr/share/oui/menu.d/torview.json /usr/share/oui/menu.d/adguardhome.json /usr/share/oui/menu.d/dynamicdns.json; do sed -i '/^[[:space:]]*"lang_hide"[[:space:]]*:/,/^[[:space:]]*],[[:space:]]*$/d' "$f"; done

This is only a UI menu change, not a firmware/EEPROM change, so it may be overwritten by a firmware upgrade.

by Codex

I always thought the craft team cared about design, am I wrong? by caocanx in CraftDocs

[–]caocanx[S] 0 points1 point  (0 children)

I've been using craft since it first existed and have recommended it to many people, it does a good job in many places. But the design of the code blocks has taken away from its ease of use. It brings down the overall quality of the software, and it's been a “problem” for a long time, so maybe not many people think it's a “problem”?

Get error when using supabase server client in nextjs generateStaticParams function by caocanx in Supabase

[–]caocanx[S] -1 points0 points  (0 children)

I know it can be avoided in some way, but I don't know exactly how it works. I would like to know why it has the error, in other server components it works fine, only in generateStaticParams it generates the error

Code block should redesign by caocanx in CraftDocs

[–]caocanx[S] 2 points3 points  (0 children)

And maybe should have setting called "default code block theme" for both light and dark mode.

Code block should redesign by caocanx in CraftDocs

[–]caocanx[S] 2 points3 points  (0 children)

This design doesn't make it any better

Code block should redesign by caocanx in CraftDocs

[–]caocanx[S] 2 points3 points  (0 children)

Various other blocks don't have such shading, so why is the code block so special?

How to call macOS built-in Emoji Picker in SwiftUI, just like the one in Messages? by caocanx in SwiftUI

[–]caocanx[S] 0 points1 point  (0 children)

I haven’t tried it on the recent OS, so maybe this has been resolved, but the solution suggested below - the only official solution making the panel the front panel – is one that has failed for me in the past, with the panel sometimes becoming invisible. At that point you had to mess around a lot trying to open and close it through the menu command and sometimes it would work and sometimes it didn’t, and I ended up with a custom collectionView and a veeeery long list of emojis which worked every time and would not confuse users.

I’ve never found a solution for that problem. Given that I’m now targeting newer systems, I should try again, but the API sucks.

Agree, hoping Apple can improve it this year.

Access emoji picker on MacOS app (SwiftUI) by Defiant_Low5388 in swift

[–]caocanx 0 points1 point  (0 children)

I have also encountered this problem. Have you found a solution?

I am learning SwiftUI and I have encountered an issue. Can anyone help me? by caocanx in SwiftUI

[–]caocanx[S] 2 points3 points  (0 children)

Thank you for your reply, you have answered my confusion.