Пример #1
0
def set_gpu_memory(mem_in_mb=16):
    """Sets the number of megabytes allocated for the GPU.

    Should probably be in powers of 2: 16, 32, 64, 128.

    """
    print " ~> GPU Memory:", mem_in_mb, "MB"
    update_rpi_config(gpu_mem=int(mem_in_mb))
Пример #2
0
def overclock(mode='modest'):
    """Programmatically set the overclocking modes.

    Available choices: none, modest, medium, high, turbo
    Defaults to none.

    """
    mode = str(mode).lower()
    parameters = OVERCLOCKING_MODES[mode]
    print " ~> Overclock:", mode
    for key, value in parameters.items():
        print "   ", key, "=", repr(value)
    update_rpi_config(**parameters)