Peter_K : Einfach mal nach "lid TOF sensor" suchen, z.B. auf AliExpress.com wird man dann fündig.
@all: Ohne jetzt die rege Diskussion über "End of Life" Python2- vs. Python3-Interpreter hier weiter anheizen zu möchten. Python ist nicht meine "favourite programming language". Der meiste Code beim PiMowBot ist in Rebol programmiert. Python, genauer Python2, kommt nur an der Stelle zum Einsatz, wo es keine direkte API bei Rebol gibt. Daher wird zum Auslesen der Messwerte einiger Sensoren (Kompass/MPU, BME280, ToF) und der Ansteuerung des Motortreibers ein kleines Python-Helferlein-Skript verwendet, welche ich zum Teil auch schon bei älteren Projekten verwendet hatte.
Beachtet ebenso die folgenden Zeilen:
pi@dust:~ $ which python
/usr/bin/python
pi@dust:~ $ ls -lart /usr/bin/python
lrwxrwxrwx 1 root root 7 Mar 4 2019 /usr/bin/python -> python2
pi@dust:~ $ ls -lart /usr/bin/python2
lrwxrwxrwx 1 root root 9 Mar 4 2019 /usr/bin/python2 -> python2.7
pi@dust:~ $ ls -lart /usr/bin/python2.7
-rwxr-xr-x 1 root root 2984816 Apr 6 2019 /usr/bin/python2.7
pi@dust:~ $ which python3
/usr/bin/python3
pi@dust:~ $ ls -lart /usr/bin/python3
lrwxrwxrwx 1 root root 9 Mar 26 2019 /usr/bin/python3 -> python3.7
pi@dust:~ $ ls -lart /usr/bin/python3.7
-rwxr-xr-x 2 root root 4275580 Apr 3 2019 /usr/bin/python3.7
Alles anzeigen
Vielleicht erkennt man auch daran, wieso der Einsatz von Python2 bei Verwendung mit dem Raspberry Pi Zero und den Rebol3-Skripten zum PiMowBot besser geeignet ist.
LG
TGD