First, ensure the following tools are available on the local system and reasonably up to date:
- Git
- Git-flow
- RVM
- Bash
- SSH
| def do_connect(): | |
| import network | |
| wlan = network.WLAN(network.STA_IF) | |
| wlan.active(True) | |
| if not wlan.isconnected(): | |
| print('connecting to network...') | |
| wlan.connect('smartspacekk', 'smartspace09') | |
| while not wlan.isconnected(): | |
| pass | |
| print('network config:', wlan.ifconfig()) |
| # Beyond The Moon - Python Codes | |
| # Workshop Session 1 (Python) | |
| # By Kinabalu Coders | |
| import turtle | |
| # tukar penjuru untuk poligon baru | |
| penjuru = 8 |
| from datetime import timedelta, datetime | |
| import airflow | |
| from airflow import DAG | |
| from airflow.models import Variable | |
| from airflow.contrib.operators.ssh_operator import SSHOperator | |
| from airflow.contrib.hooks.ssh_hook import SSHHook | |
| from airflow.operators.postgres_operator import PostgresOperator | |
| default_args = { | |
| 'owner': 'airflow', |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <Mediainfo | |
| version="0.1" | |
| ref="sources/234p_0.ts"> | |
| <File> | |
| <track type="General"> | |
| <Count>324</Count> | |
| <Count_of_stream_of_this_kind>1</Count_of_stream_of_this_kind> | |
| <Kind_of_stream>General</Kind_of_stream> | |
| <Kind_of_stream>General</Kind_of_stream> |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <Mediainfo | |
| version="0.1" | |
| ref="sources/234p_0.ts"> | |
| <File> | |
| <track type="General"> | |
| <Count>324</Count> | |
| <Count_of_stream_of_this_kind>1</Count_of_stream_of_this_kind> | |
| <Kind_of_stream>General</Kind_of_stream> | |
| <Kind_of_stream>General</Kind_of_stream> |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <Mediainfo | |
| version="0.1" | |
| ref="../Videos/WCKKDEMO.mp4"> | |
| <File> | |
| <track type="General"> | |
| <Count>325</Count> | |
| <Count_of_stream_of_this_kind>1</Count_of_stream_of_this_kind> | |
| <Kind_of_stream>General</Kind_of_stream> | |
| <Kind_of_stream>General</Kind_of_stream> |
| #include <ArduinoRobot.h> | |
| #include <SPI.h> | |
| #include "Wire.h" | |
| /* | |
| * Arduino Robot + SR04 example | |
| */ | |
| // sensor1 | |
| #define echoPin1 TKD1 |
| #include <ArduinoRobot.h> | |
| #include <SPI.h> | |
| #include "Wire.h" | |
| /* | |
| * Arduino Robot + SR04 example | |
| */ | |
| #define echoPin TKD3 | |
| #define trigPin TKD4 |
| # Run in idle (Windows 7, python 2.7) everything ok until table definition | |
| >>> from sqlalchemy import create_engine, MetaData | |
| >>> from sqlalchemy.orm import scoped_session, sessionmaker | |
| # user/password/database I put it wrongly since this is public | |
| >>> engine = create_engine('mssql+pyodbc://plast@user:password@database', convert_unicode=True, implicit_returning=False) | |
| >>> metadata = MetaData(bind=engine) |