The x positions are totally random within display range. The last parameter is only for the blue and red platforms to decide the moving direction and which image to display. Four integers are used to determine the x and y coordinates, the category and the state of the The information ofĮach platform are stored in a python list. Additionally, springs are randomly appended to green platforms to give the player a speed boost. The green ones are basic, the blue ones are moving platforms, the red ones Otherwise there would be an error message that the busįig 2: Accelerometer Testing Results Software 1 Platform Generationįour categories of platforms are generated randomly. To run "sudo pip3" to install bus device dependencies system-wide. To use the libraries, we installed the dependencies and Adafruit CircuitPython LIS3DH library on the board. ![]() Any general GPIO pin without other functions can be chosen to connect to INT. We connected Pi 3.3V power to sensor Vin, Pi GND to sensor GND, Pi SCL to sensor SCL, Pi SDA to sensor SDA, and Pi GPIO6 ![]() Use batteries to be the power of Raspberry Pi to make a wireless gamebox.Īdafruit LIS3DH Triple-Axis Accelerometer is used to control the x direction of the player.springs so that alien can jump much further, broken so that it will cause failure. Realize the no-boundary effect: when the alien reaches the edge, it comes back from another edge.Mimic the real jump track and the garvity effect.Implement platforms systems which have random positions each time.The integrated circuit including the Pi and accelerometer which carry out computation based on the users’ behavior and respond accordingly in real time. Our final game box acts as an embedded device with a user interface based on the RPi 4. The goal is to keep the jumping alien from falling. ![]() There are an endless series of platforms. We are going to design and implement a game similar to Doodle Jump.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |