You are browsing as a guest. Sign up (or log in) to start making projects!

Open comments for this post

1h 12m 47s logged

I wrote a class for my cars. This way I can write functions such as driving or later on reading data from the tracks and make car objects for each of the cars to control them more easily. (Without having to make multiple functions for each car). There were some problems with using the asyncio class with a normal class and running it, but I got it to work since I was missing an await statement and had to put everything into a async function. I tested the class, and wrote functions for connecting, disconnection, enabling (within connecting), forward with speed and accel control (with default values), and stop (both seperate and build into disconnect). (Note, the bleak class has connect and disconnect functions, but I made my own to add some extra functions into each of them.) I tested it and worked. Next I will add more functions such as turning on lights, changing lanes, and a few more things.

0
1

Comments 0

No comments yet. Be the first!