-
Notifications
You must be signed in to change notification settings - Fork 1
Main manager #23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Main manager #23
Conversation
… modif de la classe camera donc en l'etat possible probleme avec les fonctions liées
… et on regle des soucis de ip
…rer les état actuel de la voiture
…rveur_mq qui marche
Danura30082
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
J'ai l'impression que tu n'as pas compris ce que tu fait sur certain truc.
Il y a une multiplication enorme de fichier dans scripts et src/HL. Il faudrais faire le menage et simplifer la structure du truc. N'hesite pas aussi a faire un scheme pour montre comment les fichier interagise entre eux
Remarque global:
utilise logging, il ne devrait pas avoir de print qui traine sauf exeption
utilise des fonction main et des block if name == "main":
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pourquoi preciser une partie et pas tout? Pas sure qu'on precis ici car il faudrais le tenir a jour en plus du pyproject.tml
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
je voulais préciser car se sont des dépendance qu'il faut installer pas sur uv. le reste est dans le uv sync --rpi
To
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
C'est quoi ce fichier
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
aucune idée (il disparait)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
C'est quoi la logique derriere avoir celui la dans sont propre dossier?
| def envoie_donnee(Voiture): #si utilisation de la voiture directement | ||
| print("lancement de l'i2c") | ||
| import smbus | ||
| import struct |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moyen fan des import ici mais ca ce defend
| data = struct.pack('<ff', float(vitesse), float(direction)) | ||
| bus.write_i2c_block_data(SLAVE_ADDRESS, 0, list(data)) | ||
| def envoie_donnee(Voiture): #si utilisation de la voiture directement | ||
| print("lancement de l'i2c") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use logging
| """Initialize the car's components.""" | ||
| self.vitesse_milimetres_s = 0 # Speed in millimeters per second | ||
| self.angle_degre = 0 # Steering angle in degrees | ||
| self.vitesse_d = 0 # Speed in millimeters per second |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pourquoi vitesse_d?
| @@ -73,9 +71,9 @@ def _initialize_tof(): | |||
| _initialize_ai() | |||
|
|
|||
| # Initialize Lidar | |||
| _initialize_lidar() | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why no more init lidar and camera?
src/HL/Car.py
Outdated
|
|
||
|
|
||
| class Ai_Programme(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a quoi sert cette class?
| @@ -180,7 +195,9 @@ def main(self): | |||
| bp2 = Button("GPIO6") | |||
| try: | |||
| Schumacher = Driver(128, 128) | |||
| GR86 = Car(Schumacher) | |||
| GR86 = Car(Schumacher,None,None) | |||
| GR86._initialize_camera() | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pourquoi les initialiser ici et pas dans _init?
| global State | ||
| print("Tune Prop PWM") | ||
| State=0 | ||
| def tune_dir_pwm(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comme la direction n'est pas asservie pourvoire tune les pwm de propolustion reste pertiant
…er les capteur de façons à debug facilement, avec changement pour que le tout marche avec la nouvelle structure
…ier avec creation de dossier et déplacement des fichiers pour plus de lisibilité du code.
…lque super init qui manqué)
Danura30082
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Harmonize code base to english
Rajout d'un system de main ultra puissant qui lance tout les autres programmes qui ont était transformé en classe (tous ou a peu prés) et qui gere l'affichage de l'écran et rajout d'un system de streaming de la camera sur une adresse http://192.168.1.10:8000/stream.mjpg lorsque elle est lancé ainsi que une classe programme dont hérité toute les autres classe : ainsi que rajout d'un remote control depuis le lan et aussi un moyen d'éteindre la pi depuis les boutons.