Skip to content

Instantly share code, notes, and snippets.

View tongclement's full-sized avatar
💭
Working on multiple projects: Safely Overcome, Safely Cat, Total Sky Imager.....

Clement Tong (Yuk Chun) tongclement

💭
Working on multiple projects: Safely Overcome, Safely Cat, Total Sky Imager.....
View GitHub Profile
@scottopell
scottopell / fix_exfat_drive.md
Last active April 30, 2024 22:46
Fix corrupted exFAT disk macOS/OSX

exFAT support on macOS seems to have some bugs because my external drives with exFAT formatting will randomly get corrupted.

Disk Utility is unable to repair this at first, but the fix is this:

  1. Use diskutil list to find the right drive id.
  2. You want the id under the IDENTIFIER column, it should look like disk1s1
  3. Run sudo fsck_exfat -d <id from above>. eg sudo fsck_exfat -d disk1s3
  4. -d is debug so you'll see all your files output as they're processed.
  5. Answer YES if it gives you the prompt Main boot region needs to be updated. Yes/No?
@cuibonobo
cuibonobo / bluetooth_kivy.py
Last active October 10, 2023 12:19 — forked from tito/bluetooth.py
Bluetooth example with Kivy. A more fleshed-out example here: https://github.com/tito/android-demo. A more modern way of doing it: https://github.com/kivy/plyer. And this guy used Kivy to connect to an Arduino: https://github.com/brean/arduino-kivy-bluetooth. Native Kivy code (?): https://groups.google.com/d/msg/kivy-users/n_cMbFzf_1A/5edKgQgycx0J
# Same as before, with a kivy-based UI
'''
Bluetooth/Pyjnius example
=========================
This was used to send some bytes to an arduino via bluetooth.
The app must have BLUETOOTH and BLUETOOTH_ADMIN permissions (well, i didn't
tested without BLUETOOTH_ADMIN, maybe it works.)