A minimal table to compare the Espressif's MCU families.
ESP8266 | ESP32 | ESP32-S2 | ESP32-S3 | ESP32-C3 | ESP32-C6 | |
---|---|---|---|---|---|---|
Announcement Date | 2014, August | 2016, September | 2019, September | 2020, December |
# stepper.py | |
# A micropython driver for 4-phase, unipolar stepper motors such as | |
# the 28BYJ-48 | |
# Relesed to the Public Domain by Nicko van Someren, 2020 | |
# The constructor for the Stepper class takes as arguments the four | |
# pins for driving the motor phases, in phase order, and optionally a | |
# timer. The pins can be passed as pin numbers or machine.Pin objects |
def _remap_dict(d, fromto_mapping, method='delete'): | |
""" | |
Remap dictionary keys from a certain set of keys to a new set of keys | |
:param d: the dictionary that needs to be remapped | |
:param fromto_mapping: a dictionary mapping of keys in the original dictionary to the output dictionary | |
:param method: what do do with keys that aren't found in the mapping | |
'delete' means that they will be removed from the output dictionary | |
'remain' means that they will have their original names in the output dictionary | |
:return: the output dictionary with keys remapped, will return None if method is not recognized | |
""" |
Given a subscribed calendar with a url like
https://example.com/example.ics
To force Google Calendar to refresh and reload the contents right now, unsubscribe from the calendar and subscribe to a new calendar with a URL like
https://example.com/example.ics#1
Adding the anchor tag will force Google Calendar to think of it as a new calendar
import logging | |
import discord | |
from discord import app_commands | |
from discord.ext import commands | |
LOGGER: logging.Logger = logging.getLogger(__name__) | |
# Redis Cheatsheet | |
# All the commands you need to know | |
redis-server /path/redis.conf # start redis with the related configuration file | |
redis-cli # opens a redis prompt | |
# Strings. |
If a project has to have multiple git repos (e.g. Bitbucket and Github) then it's better that they remain in sync.
Usually this would involve pushing each branch to each repo in turn, but actually Git allows pushing to multiple repos in one go.
If in doubt about what git is doing when you run these commands, just
The use of __main__.py
to create executables
myprojectfolder/
|_ __main__.py
|_ __init__.py
Being __main__.py
:
print("Hello")
Reference: RFC 2616 - HTTP Status Code Definitions