pip install uflash pyserial- Connect your MicroBit, make sure you have a microUSB data-capable cable.
uflash- Flashes the MicroPython firmware to the MicroBit.
- Run
miniterm.py - Select the port that your microbit is connected to.
| license: gpl-3.0 | |
| height: 960 |
| # Fish shell abbreviations | |
| abbr tso 'tmux -2 source' | |
| abbr denv 'env | grep DOCKER_' | |
| abbr xsel 'xsel -ib' | |
| abbr ga 'git add' | |
| abbr gaa 'git add -A .' | |
| abbr gco 'git checkout' | |
| abbr gl 'git pull' | |
| abbr gp 'git push' | |
| abbr gd 'git diff' |
| # This is free and unencumbered software released into the public domain. | |
| # | |
| # Anyone is free to copy, modify, publish, use, compile, sell, or | |
| # distribute this software, either in source code form or as a compiled | |
| # binary, for any purpose, commercial or non-commercial, and by any | |
| # means. | |
| # | |
| # In jurisdictions that recognize copyright laws, the author or authors | |
| # of this software dedicate any and all copyright interest in the | |
| # software to the public domain. We make this dedication for the benefit |
| # Automatically update a gist from a local file | |
| # | |
| # Usage: make FILENAME.gist | |
| %.gist: % | |
| gist $(shell test -e $@ && echo -n '-u ' && cat $@) -p $< | tee $@ |
| # /etc/sysctl.d/60-joar-custom.conf | |
| # - Increase max process ID number, this is the maximum possible number on 64-bit linux(?) | |
| kernel.pid_max = 4194303 | |
| # - A value between 0..100 where 0 means avoid swapping as much as possible | |
| # and 100 means swap as much as possible. | |
| # - To set temoporarily: sudo sysctl vm.swappiness=10 | |
| # https://help.ubuntu.com/community/SwapFaq#What_is_swappiness_and_how_do_I_change_it.3F | |
| vm.swappiness = 10 |
| import inspect | |
| import logging | |
| _log = logging.getLogger(__name__) | |
| def parse_default_arguments(func, args, kwargs, arg_name, default=None, | |
| default_func=None): | |
| """ | |
| Parse a function call and replace omitted arguments with a dynamic |
| KIOSK_SETTINGS=bolist.settings.kiosk.local_joar | |
| SHOP_SETTINGS=bolist.settings.shop.local_joar | |
| RENTAL_SETTINGS=bolist.settings.rental.local_joar | |
| DOCKER_RUN=docker run --rm -it --restart=no | |
| .PHONY: run-rabbitmq | |
| run-rabbitmq: | |
| $(DOCKER_RUN) \ | |
| -p 5672:5672 \ | |
| rabbitmq:3-management |
Flash the Betaflight firmware