Skip to content

Commit 9895057

Browse files
committed
adding some icons and metadata for fruitjam os, request display size in some metro rp2350/fruitjam apps
1 parent 37afebb commit 9895057

File tree

18 files changed

+82
-81
lines changed

18 files changed

+82
-81
lines changed
2.16 KB
Binary file not shown.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"title": "Breakout",
3+
"icon": "icon.bmp"
4+
}
4.43 KB
Binary file not shown.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"title": "Chip'sChall",
3+
"icon": "icon.bmp"
4+
}

Metro/Metro_RP2350_CircuitPython_Matrix/code.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,10 @@
1414
import supervisor
1515
from displayio import Group, TileGrid
1616
from tilepalettemapper import TilePaletteMapper
17+
from adafruit_fruitjam.peripherals import request_display_config
1718
import adafruit_imageload
1819

19-
# use the built-in HSTX display
20+
request_display_config(320,240)
2021
display = supervisor.runtime.display
2122

2223
# screen size in tiles, tiles are 16x16
4.72 KB
Binary file not shown.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"title": "Matrix",
3+
"icon": "icon.bmp"
4+
}

Metro/Metro_RP2350_FlappyNyanCat/code.py

Lines changed: 6 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,10 @@
1717
import supervisor
1818
import bitmaptools
1919
from adafruit_display_text.bitmap_label import Label
20-
import picodvi
21-
import framebufferio
22-
import board
2320
from micropython import const
2421
import adafruit_imageload
22+
from adafruit_fruitjam.peripherals import request_display_config
23+
from adafruit_pathlib import Path
2524

2625
# how strong the gravity is
2726
FALL_SPEED = 1
@@ -42,23 +41,8 @@
4241
# current score
4342
score = 0
4443

45-
# initialize display
46-
release_displays()
47-
48-
fb = picodvi.Framebuffer(
49-
320,
50-
240,
51-
clk_dp=board.CKP,
52-
clk_dn=board.CKN,
53-
red_dp=board.D0P,
54-
red_dn=board.D0N,
55-
green_dp=board.D1P,
56-
green_dn=board.D1N,
57-
blue_dp=board.D2P,
58-
blue_dn=board.D2N,
59-
color_depth=16,
60-
)
61-
display = framebufferio.FramebufferDisplay(fb)
44+
request_display_config(320,240)
45+
display = supervisor.runtime.display
6246

6347
# initialize groups to hold visual elements
6448
main_group = Group()
@@ -607,10 +591,10 @@ def shift_post(post):
607591

608592
# if player pressed p
609593
if "p" in cur_btn_val:
610-
supervisor.set_next_code_file(__file__)
594+
supervisor.set_next_code_file(__file__, working_directory=Path(__file__).parent.absolute())
611595
supervisor.reload()
612596

613597
# if player pressed q
614598
elif "q" in cur_btn_val:
615599
print("exiting")
616-
break
600+
supervisor.reload()
12.1 KB
Binary file not shown.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"title": "FlapyNyan🐱",
3+
"icon": "icon.bmp"
4+
}

0 commit comments

Comments
 (0)