mirror of
https://github.com/dekuNukem/USB4VC.git
synced 2025-10-31 11:26:46 -07:00
updated setup instructions, dont compile xpadneo on RPi5
This commit is contained in:
12
user_program/notes_2025.txt
Normal file
12
user_program/notes_2025.txt
Normal file
@@ -0,0 +1,12 @@
|
||||
USB4VC 2025 notes
|
||||
Raspberry Pi 5
|
||||
|
||||
changelog
|
||||
|
||||
whats new
|
||||
|
||||
rpi5 support (no bt, 64bit kernel etc)
|
||||
newest system version
|
||||
web based dashboard
|
||||
|
||||
todo:
|
||||
@@ -17,13 +17,20 @@ set up ssh:
|
||||
ssh-keygen
|
||||
copy PC pub key to rpi ~/.ssh/authorized_keys
|
||||
|
||||
------------
|
||||
|
||||
IMPORTANT !!!!!!!!!!!!!!!!!!
|
||||
|
||||
sudo apt update
|
||||
sudo apt upgrade
|
||||
|
||||
-------------
|
||||
# use sudo -E to preserve environmental variables for python3
|
||||
sudo apt-get update
|
||||
|
||||
sudo apt-get install i2c-tools
|
||||
sudo apt install stm32flash
|
||||
|
||||
/usr/local/bin/stm32flash -r hhh -a 0x3b /dev/i2c-1
|
||||
stm32flash -r PBFW_IBMPC_PBID1_V0_2_0.dfu -a 0x3b /dev/i2c-1
|
||||
|
||||
sudo apt install dfu-util
|
||||
@@ -31,13 +38,19 @@ sudo dfu-util --device ,0483:df11 -a 0 -D ~/usb4vc/firmware/PBFW_ADB_PBID2_V0_1_
|
||||
|
||||
-----
|
||||
sudo apt install evtest
|
||||
pip3 install evdev
|
||||
|
||||
|
||||
sudo apt install python3-pip
|
||||
|
||||
raspberry pi 5 uses a different GPIO chip, this is a compatibility package
|
||||
|
||||
// no need
|
||||
sudo apt remove python3-rpi.gpio
|
||||
// no need?
|
||||
sudo pip3 install --break-system-packages rpi-lgpio
|
||||
|
||||
cd ~
|
||||
git clone https://github.com/atar-axis/xpadneo.git
|
||||
cd ~;git clone https://github.com/atar-axis/xpadneo.git
|
||||
sudo apt-get install dkms raspberrypi-kernel-headers
|
||||
|
||||
https://github.com/atar-axis/xpadneo
|
||||
@@ -50,7 +63,7 @@ Luma OLED driver
|
||||
|
||||
https://luma-oled.readthedocs.io/en/latest/software.html
|
||||
sudo apt-get update
|
||||
sudo apt-get install python3 python3-pip python3-pil libjpeg-dev zlib1g-dev libfreetype6-dev liblcms2-dev libopenjp2-7 libtiff5 -y
|
||||
sudo apt-get install python3 python3-pip python3-pil libjpeg-dev zlib1g-dev libfreetype6-dev liblcms2-dev libopenjp2-7 -y
|
||||
sudo -H pip3 install luma.oled
|
||||
|
||||
-------------------
|
||||
@@ -69,7 +82,6 @@ https://raspberrypi-guide.github.io/programming/run-script-on-boot
|
||||
|
||||
sudo su
|
||||
|
||||
pip3 install evdev
|
||||
|
||||
sudo nano /etc/rc.local
|
||||
|
||||
|
||||
@@ -40,7 +40,13 @@ def check_rpi_model():
|
||||
stored_model = get_stored_rpi_model()
|
||||
print('current_model', current_model)
|
||||
print('stored_model', stored_model)
|
||||
if current_model != stored_model:
|
||||
|
||||
if "Raspberry Pi 5".lower() in current_model.lower():
|
||||
usb4vc_ui.oled_print_model_changed()
|
||||
os.system("cd /home/pi/xpadneo/; sudo ./uninstall.sh")
|
||||
save_rpi_model(current_model)
|
||||
return
|
||||
elif current_model != stored_model:
|
||||
usb4vc_ui.oled_print_model_changed()
|
||||
for x in range(20):
|
||||
print("!!!!!!!!!! DO NOT UNPLUG UNTIL I REBOOT !!!!!!!!!!")
|
||||
@@ -63,7 +69,12 @@ try:
|
||||
boot_config = os.popen(f'cat {cmdline_path}').read()
|
||||
if "usbhid.mousepoll".lower() not in boot_config.lower():
|
||||
print(f"@@@@@@@@@@@@ writing usbhid.mousepoll to {cmdline_path} @@@@@@@@@@@@")
|
||||
new_config = boot_config.replace('\r', '').replace('\n', '').strip() + ' usbhid.mousepoll=0\n'
|
||||
new_config = boot_config.replace('\r', '').replace('\n', '').strip() + ' usbhid.mousepoll=4\n'
|
||||
with open(cmdline_path, 'w') as ffff:
|
||||
ffff.write(new_config)
|
||||
elif "usbhid.mousepoll=0" in boot_config:
|
||||
print(f"@@@@@@@@@@@@ writing usbhid.mousepoll to {cmdline_path} @@@@@@@@@@@@")
|
||||
new_config = boot_config.replace('\r', '').replace('\n', '').strip().replace("usbhid.mousepoll=0", "usbhid.mousepoll=4")
|
||||
with open(cmdline_path, 'w') as ffff:
|
||||
ffff.write(new_config)
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user