This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
class School: | |
def __init__(self, name): | |
self.name = name | |
self.students = [] | |
def to_dict(self): | |
return { | |
'name': self.name, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import serial | |
import time | |
def lsb(value): | |
return value & 0xff | |
def msb(value): | |
return value >> 8 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# your ip address | |
ip_address="192.168.15.142" | |
function change_dns() { | |
route add default gw 192.168.14.200 | |
echo "nameserver 80.191.216.2" > /etc/resolv.conf | |
echo "nameserver 8.8.8.8" >> /etc/resolv.conf | |
echo "nameserver 4.2.2.4" >> /etc/resolv.conf |
OlderNewer