Ayushman Tripathi
01/06/2023, 10:15 PMhtamas
01/07/2023, 11:43 PMmpremote to ~/.local/bin . Is that directory on your $PATH ?Ayushman Tripathi
01/07/2023, 11:55 PMhtamas
01/08/2023, 2:12 PMpython3 -c 'import site; print(site.getuserbase())'
2. python3 -c 'import mpremote'
3. find ~ -name mpremote -type f -executable ?Ayushman Tripathi
01/08/2023, 4:37 PMhtamas
01/09/2023, 11:42 AM--- a/firmware_vex/nucleo/Makefile
+++ b/firmware_vex/nucleo/Makefile
@@ -1,5 +1,5 @@
-export PATH=$PATH:/bin:/usr/local/bin/:../../venv/bin:/usr/bin/:.
+export PATH:=${PATH}:/bin:/usr/local/bin/:../../venv/bin:/usr/bin/:.
#DEV=/dev/cu.usbmodem3103
DEV=/dev/cu.usbmodem34203htamas
01/09/2023, 11:44 AM= with :=.)Ayushman Tripathi
01/09/2023, 7:24 PMhtamas
01/10/2023, 12:47 AMmpremote connect exec ... instead of mpremote connect /dev/whatever exec ... . You can list your devices with mpremote devs, try to find the correct one and then edit the Makefile to add a line DEV=/dev/whatever near the beginning.Ayushman Tripathi
01/10/2023, 6:10 AMhtamas
01/10/2023, 3:06 PMlsusb output when you unplug or replug the device? Do you see anything relevant in the kernel log (e.g. using dmesg)? Depending on your user & device permissions, you might need to check these as root.Ayushman Tripathi
01/10/2023, 11:52 PMhtamas
01/11/2023, 1:11 AMlsusb & dmesg as above; on a windows host run `devmgmt.msc`; on a mac os host use Apple menu > About this Mac > System Report...; etc.) Once the device is visible on the host you'll need to set up a filter in VirtualBox to pass it to the guest. You'll need to find out the details yourself, but it works the same way for any usb device so there should be plenty of tutorials on the internet.Ayushman Tripathi
01/12/2023, 2:00 AMhtamas
01/12/2023, 12:46 PMchmod every time you plug in the device, you can create an udev rule that automates it for you. The way I usually do it is I create a rule file in the udev rules directory, let's say /etc/udev/rules.d/51-usb-permissions.rules (the number just gives the ordering if there are several rule files and can be mostly ignored). For every one of my usb devices I put a line in this file that says SUBSYSTEM=="usb", ATTR{idVendor}=="XXXX", ATTR{idProduct}=="YYYY", MODE="0660", GROUP="plugdev" where XXXX:YYYY is your device vendor & product ID as it appears in the lsusb output. Once you modify the rules file, you'll need to run sudo udevadm control --reload for the changes to take effect (or just reboot the vm). This sets up a rule that every time you plug in a usb device with the particular ID, users in the plugdev group get read-write access to it. I think your user should be in the plugdev group by default, but if you type groups in the terminal and the result doesn't include plugdev, you'll also need to add your user to this group and then reboot (you don't actually need a reboot, but this way it's easier to explain).proppy
01/13/2023, 7:10 AMproppy
01/13/2023, 7:10 AMexport PATH line from the Makefile allowed me to workaround the issue.