Fix display sizing
This commit is contained in:
parent
fd6f26f202
commit
82aadf6034
@ -2,6 +2,7 @@
|
||||
become: True
|
||||
become_user: root
|
||||
tasks:
|
||||
- synchronize: src=../.. dest=/home/pi/sejf
|
||||
- copy: src=autostart dest=/home/pi/.config/lxsession/LXDE-pi/autostart
|
||||
- copy: src=sejf.desktop dest=/etc/xdg/autostart
|
||||
- apt: name=python-flask state=present
|
||||
|
@ -1,11 +1,17 @@
|
||||
#!/usr/bin/python
|
||||
import os
|
||||
os.chdir(os.path.dirname(os.path.realpath(__file__)))
|
||||
os.environ['SDL_VIDEO_CENTERED'] = '1'
|
||||
|
||||
import serial
|
||||
import webapp
|
||||
|
||||
webapp.init(serial.Serial('/dev/ttyUSB0', 115200))
|
||||
for c in ['/dev/ttyUSB0', '/dev/ttyACM0']:
|
||||
try:
|
||||
ser = serial.Serial(c, 115200)
|
||||
except:
|
||||
continue
|
||||
print('Using ', c)
|
||||
webapp.init(ser)
|
||||
|
||||
import random, math, pygame
|
||||
from pygame.locals import *
|
||||
@ -337,7 +343,7 @@ def main():
|
||||
growsnake = 0 # added to grow tail by two each time
|
||||
snakegrowunit = 2 # added to grow tail by two each time
|
||||
clock = pygame.time.Clock()
|
||||
screen = pygame.display.set_mode(WINSIZE)#FULLSCREEN)
|
||||
screen = pygame.display.set_mode(WINSIZE, pygame.NOFRAME)#FULLSCREEN)
|
||||
#screen = pygame.display.set_mode((0, 0), pygame.FULLSCREEN)
|
||||
pygame.display.set_caption('PozySejf')
|
||||
pygame.FULLSCREEN
|
||||
|
Loading…
x
Reference in New Issue
Block a user