if version.is_devmode: # For devs only: allow code in this directory to overide compiled-in stuff. Dangerous! # - using relative paths here so works better on simulator # - you must boot w/ non-production-signed firmware to get here sys.path.insert(0, 'flash/lib') # Give external devs a way to start stuff early try: import boot2 except: pass # Setup membrane numpad (mark 2+) from mempad import MembraneNumpad numpad = MembraneNumpad() glob.numpad = numpad # Serial Flash memory from sflash import SF # NV settings from nvstore import settings async def more_setup(): # Boot up code; splash screen is being shown # MAYBE: check if we're a brick and die again? Or show msg? try:
import ckcc import uasyncio.core as asyncio loop = asyncio.get_event_loop() print("---\nColdcard Wallet from Coinkite Inc. (c) 2018.\n") # Setup OLED and get something onto it. from display import Display dis = Display() dis.splash() # Setup membrane numpad (mark 2+) from mempad import MembraneNumpad numpad = MembraneNumpad(loop) # Serial Flash memory from sflash import SPIFlash sf = SPIFlash() # NV settings from nvstore import SettingsObject settings = SettingsObject(loop) # global ptr to HSM policy, if any (supported on Mk3 only) hsm_active = None async def done_splash2(): # Boot up code; after splash screen is done.
import ckcc import uasyncio.core as asyncio loop = asyncio.get_event_loop() print("---\nColdcard Wallet from Coinkite Inc. (c) 2018.\n") # Setup OLED and get something onto it. from display import Display dis = Display() dis.splash() if version.has_membrane: # Setup membrane numpad (mark 2+) from mempad import MembraneNumpad numpad = MembraneNumpad(loop) else: # Setup touch numpad (mark 1 hardware) from touchpad import TouchNumpad numpad = TouchNumpad(loop) # Serial Flash memory from sflash import SPIFlash sf = SPIFlash() # NV settings from nvstore import SettingsObject settings = SettingsObject(loop) # important default/restore preference numpad.sensitivity = settings.get('sens', numpad.sensitivity)