Skip to content

Instantly share code, notes, and snippets.

@changtimwu
changtimwu / company_profile_remark.md
Last active August 29, 2015 14:09
Intrising company profile in remark syntax

class: center, middle

#Slide 1

Intrising technologies is a custom electronics design services company focusing on communication devices for mission critical scenarios. The main application includes L2/L3 ethernet switches used in mobile backhaul, factory automation, smart rail and power planets. With years of strong experience in protocol implementation and firmware engineering, Intrising provides the electronic design consulting services as well as full turnkey product from development to mass production.


#Slide 2 This is slide 2.

@changtimwu
changtimwu / fluxpurejs.js
Last active February 4, 2016 07:19
gasolin demonstrates flux concept in only 50 lines of javascript
/* original link http://blog.gasolin.idv.tw/2014/11/flux-javascript.html */
// Renderer.js
var ClickRenderer = {
init: function s_init(element, Store) {
this.element = element;
this.store = Store;
window.addEventListener('render_view1', this);
},
handleEvent: s_handleEvent(evt) {
@changtimwu
changtimwu / dhcp_notes.md
Last active August 29, 2015 14:08
dhcp notes

問題

測試人員為了方便, 常常都固定用單一 DHCP client 實體連接到不同 port 或不同 relay agent, 用來測試不同的 option82 policy rule, 由於單一 DHCP client 其 MAC address 是固定的, 常會觸發 DHCP 實作內的 cache 機制, 導致誤判測試結果, 使用這個方式測試請先了解DHCP 實作原理.

  • 因為 IP 有限, client 卻可能眾多, 大多數 DHCP client , DHCP server 的實作策略都傾向 "不浪費租約, 不輕易給新 IP", client 只要曾經成功在某個條 rule 要到 IP 過, server & client 兩者都會盡最大努力去續記 (cache 住)這份合約.
  • 大部份 DHCP server 實作, 即使因為更改設定而必須重啟, 先前發出去的租約不會清掉, 通通存在內部 database, 重啟時會再 load 出來用.
  • Windows 7 DHCP client 的實作是, 只要曾經要到過IP, 後面不管是經歷
    • 網路線插拔
  • 網卡 disable/enable
@changtimwu
changtimwu / emojitest.md
Last active August 29, 2015 14:07
github emoji test
@changtimwu
changtimwu / ptpst_format.md
Last active August 29, 2015 14:06
PTP status api json structure

API ptp::get_ptp_status

[
 {
   no: 6  # Arrival Port 
   clockId: "0040c7fffe1c6fce"  # Clock ID
   corrections:  [               # Corrections
 { 
@changtimwu
changtimwu / nodejs2go.md
Created August 14, 2014 03:16
Porting CLI from NodeJS to GO
@changtimwu
changtimwu / rpctodo.md
Last active August 29, 2015 14:05
rpc todo jobs
  • create a smith based net/rpc codec. simulate the following two apis
    • codec.MsgpackSpecRpc.ClientCodec -- done
    • codec.MsgpackSpecRpc.ServerCodec
  • pubsub in go-smith
    • net/rpc doesn't cover this. It's required to create a server to receive calls.
  • encoding/transportation conversion
    • encoding:
      • json/msgpack gateway.
    • transportation
  • smith/sockjs gateway.
@changtimwu
changtimwu / mpakcodec_study.md
Created July 26, 2014 22:56
msgpack codec study

import "github.com/vmihailenco/msgpack" 有很多限制

@changtimwu
changtimwu / mutstudy.md
Created July 26, 2014 02:20
git mutable type study

struct 真的是copy value , 要用 pointer 才能指到同一個 struct variable

package main

import "fmt"

type myst struct {
	age int
}