1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
import time
from selenium import webdriver
import telegram

def updateStatus():
browser.find_element_by_xpath('//*[@id="paramInvcNo"]').send_keys(num)
browser.find_element_by_xpath('//*[@id="btnSubmit"]').click()
status = browser.find_element_by_xpath('//*[@id="statusDetail"]')
return status.text

options = webdriver.ChromeOptions()
options.add_argument('headless')
options.add_argument('window-size=1920x1080')
options.add_argument("disable-gpu")
browser = webdriver.Chrome("Location of Chrome Driver", options = options)
browser.implicitly_wait(5)
url = 'https://www.cjlogistics.com/ko/tool/parcel/tracking'
browser.get(url)
myToken = 'TelegramToken'
bot = telegram.Bot(token = myToken)
chat_id = ID#bot.getUpdates()[-1].message.chat.id #가장 최근에 온 메세지의 chat id를 가져옵니다
num = 운송장 번호
statusArr = ["", ""]

i = 0
while True:
status = updateStatus()
statusArr[i%2] = str(status)
if statusArr[0] != statusArr[1]:
bot.sendMessage(chat_id=chat_id, text=statusArr[i%2])
print('Different')
browser.refresh()
time.sleep(1)
i = i+1

Read more »

MATLAB Coder

MATLAB Coder를 통해 C 또는 C++ 코드를 생성할 수 있다.

  • Export types
    • 소스 코드
    • 정적 라이브러리
    • 동적 라이브러리
  • Prerequisites for Deep Learning
    • Intel CPUs
      • Intel Math Kernel Library for Deep Neural Networks (Intel MKL-DNN)
    • ARM CPUs
      • ARM Compute Library

MatLAB Coder

Read more »

Source in Github

HRV(Heart Rate Variability)

Detecting R-R Interval

rrInterval.mat
1
2
3
4
5
6
7
8
9
function [qrspeaks, locs, y] = rrInterval(time, ecg)
t = time;
wt = modwt(ecg, 5);
wtrec = zeros(size(wt));
wtrec(4:5, :) = wt(4:5, :);
y = imodwt(wtrec, 'sym4');
y = abs(y).^2;
[qrspeaks, locs] = findpeaks(y, t, 'MinPeakHeight', 0.1, 'MinPeakDistance', 0.450); %time과 y에 대한 그래프를 해석 후 파라미터 결정
end

ECG

ECG
1
2
>> load mit200
>> plot(tm, ecgsig)
Read more »

Raspberry Pi 초기 설정

1
2
3
4
5
6
7
8
9
10
11
pi@raspberrypi:~ $ sudo apt-get update
pi@raspberrypi:~ $ sudo apt-get install python3-pip -y
pi@raspberrypi:~ $ sudo apt-get update -y
pi@raspberrypi:~ $ sudo apt-get install python3-venv
pi@raspberrypi:~ $ python3 -m venv zerohertz
pi@raspberrypi:~ $ source ~/zerohertz/bin/activate
(zerohertz) pi@raspberrypi:~ $ pip install --upgrade pip
(zerohertz) pi@raspberrypi:~ $ pip install jupyter notebook
(zerohertz) pi@raspberrypi:~ $ pip install ipykernel
(zerohertz) pi@raspberrypi:~ $ python -m ipykernel install --user --name=zerohertz
(zerohertz) pi@raspberrypi:~ $ jupyter notebook --generate-config
Read more »

Introduction

유연생산시스템(FMS)

생산성과 유연성의 양립을 목적으로 한 시스템으로서, 가공, 반송, 자재의 착탈, 제어의 기능을 유기적으로 결합한 자동화된 생산시스템

  • FMS(Flexible Manufacturing System) : 기계와 외부적인 연결
    • 다양한 순서의 자동 재료흐름
    • AGV(Automatic Guidied Vehicle), 산업용 Robot, Tooling, Pallet, Fixture
    • 공장무인화
  • FMC(Flexible Manufacturing Cell) : 독자적으로 작동
    • Machining center : 공작기계 내에서의 Pallet를 이용한 자동생산, 자동공구교환
    • 기계간 Pallet는 도움 필요
    • 40 ~ 800 부품
  • FTL(Flexible Transfer Line) : 기계와 내부적인 연결
    • 자동재료 이송시스템, NC 공작기계, 자동헤드 교환장치
    • 직접적인 재료흐름, 공작물의 순환운동
    • 1,500 ~ 15,000
특성\종류 Transfer Line(FTL) FMS Standard-alone NC machines(FMC)
생산량
제품종류/유연성
Read more »

Politics and Political Science

인간 생활의 본질

  • Aristotle : 인간은 정치적 동물
    • 정치는 인간사회에 반드시 필요하고 인간사회에서만 가능한 현상
    • 정치적 동물인 인간의 사회에는 반드시 권력 발생
  • B. Russell : 인간의 생활현상은 3가지 투쟁의 연속
    • 인간과 자연의 투쟁 -> 자연과학, 물질문명 발달
    • 인간과 인간 자신과의 내부 투쟁 -> 정신문화 발달
    • 인간과 다른 인간과의 투쟁 -> 정치현상 발생
Read more »

Introduction

Hexo에서 urlredirection해주는 플러그인

Install

Read more »

Introduction

Hexo에서 urlredirection해주는 플러그인

Install

Read more »

CMD를 통한 Serial 통신

Read more »

Arduino Nano 33 BLE

센서 / 모듈 이름 Info
nRF52840 32Bbit, 64MHz MCU
NINA-B306 Bluetooth
LSM9DS1 9축 IMU센서
  • RESET 버튼을 2번 눌러 Upload mode로 전환
  • begin() 메서드 필수

Aruino Nano 33 BLE

Read more »