- 12月 01 週二 201507:25
[台灣50][KD記錄]2015/12/1筆記
- 11月 23 週一 201523:08
[台灣50][KD記錄]2015/11/23筆記
- 11月 18 週三 201500:45
[台灣50][KD記錄]2015/11/17筆記
- 11月 16 週一 201517:09
printf wrap examples
==========================================
#define zPrint(fmt, ...) do { printf("[bootcode][%s,%s,%d]" fmt, __FILE__, __FUNCTION__, __LINE__, ## __VA_ARGS__);}while(0)
==========================================
#define DBG_MSG_ERR "DBG_MSG_ERR"
#define DBG_MSG_WARN "DBG_MSG_WARN"
#define DBG_MSG_INFO "DBG_MSG_INFO"
#define DBG_MSG_TRACE "DBG_MSG_TRACE"
#if defined(Config_Log_Level_ERR)
#define DBG_MSG_ERR_PRINTF(fmt, ...) do {printf("[ERR][%s,%d fmt, __FUNCTION__, __LINE__, ## __VA_ARGS__); } while(0)
#define DBG_MSG_WARN_PRINTF(fmt, ...) do {} while(0)
#define DBG_MSG_INFO_PRINTF(fmt, ...) do {} while(0)
#define DBG_MSG_TRACE_PRINTF(fmt, ...) do {} while(0)
#elif defined(Config_Log_Level_WARN)
#define zPrint(fmt, ...) do { printf("[bootcode][%s,%s,%d]" fmt, __FILE__, __FUNCTION__, __LINE__, ## __VA_ARGS__);}while(0)
==========================================
#define DBG_MSG_ERR "DBG_MSG_ERR"
#define DBG_MSG_WARN "DBG_MSG_WARN"
#define DBG_MSG_INFO "DBG_MSG_INFO"
#define DBG_MSG_TRACE "DBG_MSG_TRACE"
#if defined(Config_Log_Level_ERR)
#define DBG_MSG_ERR_PRINTF(fmt, ...) do {printf("[ERR][%s,%d fmt, __FUNCTION__, __LINE__, ## __VA_ARGS__); } while(0)
#define DBG_MSG_WARN_PRINTF(fmt, ...) do {} while(0)
#define DBG_MSG_INFO_PRINTF(fmt, ...) do {} while(0)
#define DBG_MSG_TRACE_PRINTF(fmt, ...) do {} while(0)
#elif defined(Config_Log_Level_WARN)
- 11月 06 週五 201501:22
[台灣50][KD記錄]2015/11/5筆記
- 10月 28 週三 201522:32
[台灣50][KD記錄]2015/10/28筆記
- 10月 05 週一 201509:18
Setup NFS server
NFS 是一種等同於samba的功能
以下是在ubuntu 12.04 建立並加入一個匿名帳號的流程
Server端:
以下是在ubuntu 12.04 建立並加入一個匿名帳號的流程
Server端:
- 9月 25 週五 201516:37
Nand Flash的 bit flip
節錄於 http://www.eetimes.com/document.asp?doc_id=1203174
NAND Reliability Issues
One of the main considerations of working with a flash media is its reliability. This reliability is impacted by three major factors: bit-flipping, bad block handling, and Life span (number of erase cycles allowed). Let's see how these apply to NAND.
NAND Reliability Issues
One of the main considerations of working with a flash media is its reliability. This reliability is impacted by three major factors: bit-flipping, bad block handling, and Life span (number of erase cycles allowed). Let's see how these apply to NAND.
- 7月 23 週四 201515:51
bless hex editor 的layout 如何改成16 byte per row ?
default layout : /usr/share/bless/bless-default.layout
在default layout 增加紅色這行即可
<area type="hexadecimal">
<bpr>16</bpr>
<case>upper</case>
</area>
參考http://home.gna.org/bless/bless-manual/ch05s03.html
在default layout 增加紅色這行即可
<area type="hexadecimal">
<bpr>16</bpr>
<case>upper</case>
</area>
參考http://home.gna.org/bless/bless-manual/ch05s03.html
- 5月 13 週三 201509:18
ubuntu 安裝 ssh 卻無法從外部登入
望聞問切的結果如下:
1. 內外連網正常
2. apt-get install openssh-server都說最新版,
daemon有跑起來.
3. ssh -v過程看不出錯誤點, 最後只顯示
debug1: SSH2_MSG_KEXINIT sent
Read from socket failed: Connection reset by peer
4. /etc/ssh/ssh_config內容正常,
但/etc/ssh/sshd_config卻是empty file.
================================
救贖之道 就在其中
http://askubuntu.com/questions/218957/12-04-sshd-config-file-is-empty-but-my-ssh-config-is-not-empty
1. 內外連網正常
2. apt-get install openssh-server都說最新版,
daemon有跑起來.
3. ssh -v過程看不出錯誤點, 最後只顯示
debug1: SSH2_MSG_KEXINIT sent
Read from socket failed: Connection reset by peer
4. /etc/ssh/ssh_config內容正常,
但/etc/ssh/sshd_config卻是empty file.
================================
救贖之道 就在其中
http://askubuntu.com/questions/218957/12-04-sshd-config-file-is-empty-but-my-ssh-config-is-not-empty
