Skip to content

Instantly share code, notes, and snippets.

monkeymademe / 0_reuse_code.js
Created July 2, 2014 14:39
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
import os
import time
import shutil
import subprocess
import signal
import sys
import argparse
#If the applescript stops working or you don't want the function, set enableapplescript to False
enableapplescript = True
import os
import time
import shutil
import argparse
# Create the argument parser
parser = argparse.ArgumentParser(description='Pico Firmware Flasher')
parser.add_argument('uf2_file_path', metavar='UF2_FILE', type=str, help='Path to the UF2 file')
parser.add_argument('-d', '--drive_letter', type=str, default='D:', help='Drive letter of the Pico (default: D:)')
from machine import I2C
from time import sleep, ticks_ms, ticks_diff
from servo import Servo, CONTINUOUS
from time import ticks_ms, ticks_diff
from breakout_vl53l5cx import VL53L5CX, RESOLUTION_8X8
import random
# The VL53L5CX requires a firmware blob to start up.
# Make sure you upload "vl53l5cx_firmware.bin" via Thonny to the root of your filesystem