You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
importboardimportdisplayioimportsupervisorimporttimedisplay=board.DISPLAY# Create a Groupmygroup=displayio.Group()
print()
print()
print()
print("REPL control test: Taking control of REPL group")
time.sleep(3)
# clear the display to the REPL display.show(None)
splash=board.DISPLAY.root_group# this gets the current root_group, the REPL# Note: You must "display.show" your own group before adding the splash to your own group.# Reason: When displaying the normal REPL (for example with display.show(None), the splash# group is already in a group that is displayed. To remove the splash from the displayed group,# you first have to display.show some other group, doing that will remove the splash from its group# and allow you to append it to your own group. display.show(mygroup)
# resize the supervisor.splash group pixel dimensions, make it half the display height.supervisor.reset_terminal(display.width//2, display.height//2)
# relocate the supervisor.splash group on the display, moving it half-way down the displaysplash.x=display.width//2splash.y=display.height//2print("Resize and move the splash screen")
# append the supervisor.splash group to the displayed group.mygroup.append(splash)
time.sleep(2)
# demonstrate how print statements scroll on the REPL/console displayprint("Add some prints to show terminal scrolling:")
time.sleep(0.3)
foriinrange(6):
print("Line: {}".format(i))
time.sleep(0.3)
time.sleep(1.5)
print("Ending code.py")
### If there is no serial connection, just the Blinka remains after the code is done.### Have to reset the display to show(None) to see the "Code done running." text.# display.show(None)
Behavior
When using the split-screen REPL that was repaired in #6077, there is some unexpected behavior when code.py ends.
Three scenarios and the output observed:
No serial connection is available (This one is disconcerting! Only a Blinka is shown.)
Serial connection is available
No serial connection but adddisplay.show(None) at the end of code.py (see my code above, uncomment the last line)
Description
Only happens when code.py ends while having the REPL group resized using the new capabilities in the code above.
Additional information
Perhaps the terminal should be reset before adding the "Code done running." is printed.
The text was updated successfully, but these errors were encountered:
CircuitPython version
Code/REPL
Behavior
When using the split-screen REPL that was repaired in #6077, there is some unexpected behavior when
code.py
ends.Three scenarios and the output observed:
No serial connection is available (This one is disconcerting! Only a Blinka is shown.)

Serial connection is available

No serial connection but add

display.show(None)
at the end ofcode.py
(see my code above, uncomment the last line)Description
Only happens when
code.py
ends while having the REPL group resized using the new capabilities in the code above.Additional information
Perhaps the terminal should be reset before adding the "Code done running." is printed.
The text was updated successfully, but these errors were encountered: