WFU

[ 精選文章 ]

自行車 入門 Escape 3 , Snap 21 , Revel

最近周末想運動 , 平日想通勤 , 想買台自行車 , 把自己找的資料跟大家分享 , 如果你是玩家級的 就不用看了 這是給跟我一樣的新新新手 參考的 騎車半年後的補充: 如果你有把握你是真的有時間有興趣會一直騎,建議還是存點錢買好一點的彎把公路車, 或是可以考慮買2手的自...

2015年9月15日 星期二

網頁加密

http://www.vincentcheung.ca/jsencryption/instructions.html

js file


Instructions

To put encrypted text in your own site:
  1. Add the decryption JavaScript code (see below)
  2. Encrypt your text on the encryption page
    1. Type the password for the encrypted text in the Key box (be sure to remember the key!)
    2. Enter whatever you want to encrypt in the Plain Text box
    3. Click Encrypt
  3. Copy and paste the code in the HTML Code box into your website or blog

The JavaScript decryption code

Between the <head> and </head> tags in the html code of your webpage, add the following:
<script type="text/javascript" src="http://www.vincentcheung.ca/jsencryption/jsencryption.js"></script>

Encrypted text and decryption link

This is the basic code to use in the body of the html code of your webpage to do the decryption:
<div id="uniqueID" title="encrypted text">
    <a href="javascript:decryptText('uniqueID')">Show encrypted text</a>
</div>
encrypted text is the encrypted text generated from the encryption/decryption page.
uniqueID is a unique name for the element, which is automatically generated by the encryption/decryption page in the sample code. This can be anything that you want, but do not put your key here because it is visible to everyone.
The decryptText JavaScript function gets the encrypted text from the title of the element with the id uniqueID. Once decrypted, the contents of the element are replaced with the decrypted text.
The two uniqueID's must be exactly the same, otherwise the code will not work.
See the examples page to see this in action and for different uses.

Advanced options

The decryptText function can accept an array of element id's and it will decrypt each of them. The encrypted text in each of these element id's can be encrypted with the same or different keys.
You can change the message in the dialog box that asks for the key by providing the desired message as a second parameter, eg. decryptText('uniqueID', 'Enter the password:')
Instead of the fancy dialog box, you can use the standard JavaScript dialog box to request the key by doing this:
decryptText('uniqueID', null, true) or decryptText('uniqueID', 'Enter the key:', true)
One word of caution is that IE7 blocks the regular JavaScript dialog box and you have to click the pop-up message to allow the dialog to show.

Bookmarklets

Drag these to the bookmark toolbar:
Encrypt 
Decrypt
These bookmarklets provide a quick shortcut to the encryption/decryption page and automatically fills in the plain or encrypted text fields with the selected text on the page that you are currently on.

自製封裝Windows

http://izaka.tw/w7sp2/

20150915
Win10 do not support Windows Updates Downloader ,Use Win7 ok.

有設定子目錄的路徑會有 error message
使用整合版的 ISO 其 install.wim 有時會有問題
使用 dism /get-wiminfo /wimfile:c:\W7SP2\install.wim 確認版本可否使用
(自行整合封裝要花不少時間喔)

PS. Win7 ei.cfg 封印了版本選單
所以只要刪除這個檔案就可以解除版本封印
即可把任一版本的Windows 7安裝光碟變成 整合版光碟

亦可使用「ei.cfg Removal Utility」解除版封印 安裝過程會出現版本選擇畫面
家用入門版 家用進階版 專業版 旗艦版
雖然沒有企業版 不過 , 企業版的功能內容其實就和全功能的旗艦版完全一樣 ,
只有啟用方式不同 , 也就像是從官方下載的旗艦試用版.


2015年9月10日 星期四

New system RamDisk optimization, Chrome / Edge Cache


Share my setting with people who have the same idea as i do

1. Create Ram disk with apps (SoftPerfect RamDisk 3.4.8 and  imDisk are recommended
2. Setting TEMP/Cache and Build folder to the ramdisk

change C:\Users%username%\Downloads

mklink 這個指令讓其他磁碟的路徑 (比如 e:\DiskCLink\installer\) 取代 c:\windows\installer
用途為增加 C 槽空間 或是移轉儲存空間到別的空間去

1. Example
robocopy /copyall /move /e c:\windows\installer e:\DiskCLink\installer
mklink /d c:\windows\installer e:\DiskCLink\installer\

I also linked 2 other folders, I think it can reduce the size of driver C
mklink /d c:\users\%username%\Games e:\%Username%\Games
mklink /d c:\users\%username%\Downloads e:\%Username%\Downloads

2.Setting Google Cache 
a. md R:\ChromeCache (R : RAMDISK Driver)
Create the folder 

b. rd /s /q C:\Users\%USERNAME%\AppData\Local\Google\Chrome\User Data\Default\Cache
Must delete the cache folder first , Mklink can not create the LINK when the folder already exists


c. mklink /D "C:\Users\%USERNAME%\AppData\Local\Google\Chrome\User Data\Default\Cache" "R:\ChromeCache"
將Cache目錄映射到R:\ChromeCache

PS. Support UNC, mklink /d c:\webroot \\ShareHost\ShareFolder

Ex for Edge Cache
mklink /d "C:\Users\%USERNAME%\AppData\Local\Microsoft\Edge\User Data\Default\Cache\" "W:\EdgeCache"



3.My Document
https://www.diskpart.com/tw/article/move-documents-folder-to-another-drive-windows-10.html

2015年9月9日 星期三

Widnows 同時 連接有線網路 無線網路

Widnows 當有連接有線網路時 無線網路 不會自動連線的解決方式

Windows 的「本機群組原則編輯器」(gpedit.msc)

本機電腦原則 - 系統管理範本 - 網路 - Windows 連線管理員 - 最小化網際網路或 Windows 網域的同時連線數目

Default 是 尚未設定 (但是會被啟用)

設定成 已停用 即可

2015年9月8日 星期二

ASUS UX32VD install Win10


當初買 ASUS UX32VD 是搭配 Win7 Home , Win10 出了當然要換 Win10 囉
1.先備份還原 Run ASUS recovery AI to create recovery ISOs (4 files 13.8G)
Recommend,due to to clean all the partitions and install the OS in SSD is much better.

2.安裝 win10 時把所有的分割區都殺了 (含 SSD 24G)

3.I choose to install Win10 Pro to SSD (about 14G after install)
裝在 SSD24G 不推薦 , 空間太小 無法休眠

4.安裝完成後 去裝置管理員把顯示卡驅動更新一下

5.裝置管理員會有黃色驚嘆號,下載DPTF安裝後就好了
ACPI\INT3400
ACPI\INT3402
ACPI\INT3403
ACPI\INT3404
please get the "Intel® Dynamic Platform and Thermal Framework Drive" from Asus website (http://dlcdnet.asus.com/pub/ASUS/nb/Drivers/DPTF/DPTF_Intel_Win7_64_Z6011067.zip)

6.Fn 鍵的功能請安裝 ATK package
Then you will need the FN key support , try to get the "ATKPackage_Win7_64_Z100022" from from Asus website ( or download directly HERE ) (note: driver can be used in both 32/64)

7.24G 的 SSD 可別浪費 , 設定 CacheExpress + Intel Rapid Start
1.執行 CreateRSTDSK
2.安裝 Intel Rapid Start
3.安裝 ExpressCache 後 , 重開機後即可
檢查成功與否方式為使用 DOS 視窗執行 ECCMD -info (位於 program files\Diskeeper Corp oration\ExpressCache) 看到 Mounted = Yes 即可
ps 如果有先安裝了 CacheExpress 的話 IRST 會不能裝 , 請移除再重做一次

8.使用Primo Ramdisk 切 Ramdisk

9.將 TEMP 檔改到 Ramdisk

10.Enjoy it !

PS
Intel Rapid Start Technology not supported

2015年7月30日 星期四

AMD KB reset 發兩次 (AMI)

SBSECInit.asm

IF MKF_SB900_RESET_WORKAROUND
;; Warm reset work around ( Do cold reset) end
;SB900 CF9 Reset workaround
    cmp   BYTE PTR DS:[0Ffff0h], 0EAh ; Is it warm reset ?
    jne NotWarmReset

    mov dx,0cf9h
    mov ax,6   ;hw reset
    out dx,ax

    mov dx,80h
    out dx,al

    jmp $
NotWarmReset:


As I check the KBC reset in Godvari platform , I can see 2 reset in the wave form ,
after trace , it seems to be the workaround from old chipset ...
a warm reset will issue a cold reset  right after it ...

2015年7月1日 星期三

AMI Debug code

================================================
StatusCodeMap.c , StatusCodeMapPei.c
================================================
//**********************************************************************
// Checkpoints map
//**********************************************************************
//1        - 0xF : SEC execution
//0x10 - 0x2F: PEI CAR execution
//0x30 - 0x4F: PEI execution after memory detection
//0x50 - 0x5F: PEI errors
//0x60 - 0xCF: DXE execution
//0xD0 - 0xDF: DXE errors
//0xE0 - 0xE8: S3 Resume
//0xE9 - 0xEF: S3 Resume errors
//0xF0 - 0xF8: Recovery
//0xF9 - 0xFF: Recovery errors

================================================
PEI
================================================
STATUS_CODE_TO_BYTE_MAP ProgressCheckpointMap[] =
{

//Regular boot
    { PEI_CORE_STARTED, 0x10 },
    { PEI_CAR_CPU_INIT, 0x11 },
    // reserved for CPU 0x12 - 0x14
    { PEI_CAR_NB_INIT, 0x15 },
    // reserved for NB 0x16 - 0x18
    { PEI_CAR_SB_INIT, 0x19 },
    // reserved for SB 0x1A - 0x1C
    // reserved for OEM use: 0x1D - 0x2A
    { PEI_MEMORY_SPD_READ, 0x2B },
    { PEI_MEMORY_PRESENCE_DETECT, 0x2C },
    { PEI_MEMORY_TIMING, 0x2D},
    { PEI_MEMORY_CONFIGURING, 0x2E },
    { PEI_MEMORY_INIT, 0x2F },
    // reserved for AML use: 0x30
    { PEI_MEMORY_INSTALLED, 0x31 },
    { PEI_CPU_INIT,  0x32 },
    { PEI_CPU_CACHE_INIT, 0x33 },
    { PEI_CPU_AP_INIT, 0x34 },
    { PEI_CPU_BSP_SELECT, 0x35 },
    { PEI_CPU_SMM_INIT, 0x36 },
    { PEI_MEM_NB_INIT, 0x37 },
    // reserved for NB 0x38 - 0x3A
    { PEI_MEM_SB_INIT, 0x3B },
    // reserved for SB 0x3C - 0x3E
    // reserved for OEM use: 0x3F - 0x4E
    { PEI_DXE_IPL_STARTED, 0x4F },
    { DXE_CORE_STARTED, 0x60 },
//Recovery
    { PEI_RECOVERY_AUTO, 0xF0 },
    { PEI_RECOVERY_USER, 0xF1 },
    { PEI_RECOVERY_STARTED, 0xF2 },
    { PEI_RECOVERY_CAPSULE_FOUND, 0xF3 },
    { PEI_RECOVERY_CAPSULE_LOADED, 0xF4 },
//S3
    { PEI_S3_STARTED, 0xE0 },
    { PEI_S3_BOOT_SCRIPT, 0xE1 },
    { PEI_S3_VIDEO_REPOST, 0xE2 },
    { PEI_S3_OS_WAKE, 0xE3 },

    {0,0}
};

STATUS_CODE_TO_BYTE_MAP ErrorCheckpointMap[] =
{

//Errors
//Regular boot
    { PEI_MEMORY_INVALID_TYPE, 0x50 },
    { PEI_MEMORY_INVALID_SPEED, 0x50 },
    { PEI_MEMORY_SPD_FAIL, 0x51 },
    { PEI_MEMORY_INVALID_SIZE, 0x52 },
    { PEI_MEMORY_MISMATCH, 0x52 },
    { PEI_MEMORY_NOT_DETECTED, 0x53 },
    { PEI_MEMORY_NONE_USEFUL, 0x53 },
    { PEI_MEMORY_ERROR, 0x54 },
    { PEI_MEMORY_NOT_INSTALLED, 0x55 },
    { PEI_CPU_INVALID_TYPE, 0x56 },
    { PEI_CPU_INVALID_SPEED, 0x56 },
    { PEI_CPU_MISMATCH, 0x57 },
    { PEI_CPU_SELF_TEST_FAILED, 0x58 },
    { PEI_CPU_CACHE_ERROR, 0x58 },
    { PEI_CPU_MICROCODE_UPDATE_FAILED, 0x59 },
    { PEI_CPU_NO_MICROCODE, 0x59 },
    { PEI_CPU_INTERNAL_ERROR, 0x5A },
    { PEI_CPU_ERROR, 0x5A },
    { PEI_RESET_NOT_AVAILABLE,0x5B },
    //reserved for AMI use: 0x5C - 0x5F
//Recovery
    { PEI_RECOVERY_PPI_NOT_FOUND, 0xF8 },
    { PEI_RECOVERY_NO_CAPSULE, 0xF9 },
    { PEI_RECOVERY_INVALID_CAPSULE, 0xFA },
    //reserved for AMI use: 0xFB - 0xFF
//S3 Resume
    { PEI_MEMORY_S3_RESUME_FAILED, 0xE8 },
    { PEI_S3_RESUME_PPI_NOT_FOUND, 0xE9 },
    { PEI_S3_BOOT_SCRIPT_ERROR, 0xEA },
    { PEI_S3_OS_WAKE_ERROR, 0xEB },
    //reserved for AMI use: 0xEC - 0xEF

    {0,0}
};

//**********************************************************************
// Beep codes map
//**********************************************************************
STATUS_CODE_TO_BYTE_MAP ProgressBeepMap[] =
{

//Recovery
    { PEI_RECOVERY_STARTED, 2 },

    {0,0}
};

STATUS_CODE_TO_BYTE_MAP ErrorBeepMap[] =
{

//Errors
//Regular boot
    { PEI_MEMORY_NOT_INSTALLED, 1 },
    { PEI_MEMORY_INSTALLED_TWICE, 1 },
    { PEI_DXEIPL_NOT_FOUND, 3 },
    { PEI_DXE_CORE_NOT_FOUND, 3 },
    { PEI_RESET_NOT_AVAILABLE, 7 },
//Recovery
    { PEI_RECOVERY_FAILED, 4 },
//S3 Resume
    { PEI_S3_RESUME_FAILED, 4 },

    {0,0}
};

================================================
DXE
================================================

STATUS_CODE_TO_BYTE_MAP ProgressCheckpointMap[] =
{
    { DXE_CORE_STARTED, 0x60 },
    { DXE_NVRAM_INIT, 0x61 },
    { DXE_SBRUN_INIT, 0x62 },
    { DXE_CPU_INIT, 0x63 },
    //reserved for CPU 0x64 - 0x67
    { DXE_NB_HB_INIT, 0x68 },
    { DXE_NB_INIT, 0x69 },
    { DXE_NB_SMM_INIT, 0x6A },
    //reserved for NB 0x6B - 0x6F
    { DXE_SB_INIT, 0x70 },
    { DXE_SB_SMM_INIT, 0x71 },
    { DXE_SB_DEVICES_INIT, 0x72 },
    //reserved for SB 0x73 - 0x77
    { DXE_ACPI_INIT, 0x78 },
    { DXE_CSM_INIT, 0x79 },
    //reserved for AMI use: 0x7A - 0x7F
    //reserved for OEM use: 0x80 - 0x8F
    { DXE_BDS_STARTED, 0x90 },
    { DXE_BDS_CONNECT_DRIVERS, 0x91 },
    { DXE_PCI_BUS_BEGIN, 0x92 },
    { DXE_PCI_BUS_HPC_INIT, 0x93 },
    { DXE_PCI_BUS_ENUM, 0x94 },
    { DXE_PCI_BUS_REQUEST_RESOURCES, 0x95 },
    { DXE_PCI_BUS_ASSIGN_RESOURCES, 0x96 },
    { DXE_CON_OUT_CONNECT, 0x97 },
    { DXE_CON_IN_CONNECT, 0x98 },
    { DXE_SIO_INIT, 0x99 },
    { DXE_USB_BEGIN, 0x9A },
    { DXE_USB_RESET, 0x9B },
    { DXE_USB_DETECT, 0x9C },
    { DXE_USB_ENABLE, 0x9D },
    //reserved for AMI use: 0x9E - 0x9F
    { DXE_IDE_BEGIN, 0xA0 },
    { DXE_IDE_RESET, 0xA1 },
    { DXE_IDE_DETECT, 0xA2 },
    { DXE_IDE_ENABLE, 0xA3 },
    { DXE_SCSI_BEGIN, 0xA4 },
    { DXE_SCSI_RESET, 0xA5 },
    { DXE_SCSI_DETECT, 0xA6 },
    { DXE_SCSI_ENABLE, 0xA7 },
    { DXE_SETUP_VERIFYING_PASSWORD, 0xA8 },
    { DXE_SETUP_START, 0xA9 },
    //reserved for AML use: 0xAA
    { DXE_SETUP_INPUT_WAIT, 0xAB },
    //reserved for AML use: 0xAC
    { DXE_READY_TO_BOOT, 0xAD },
    { DXE_LEGACY_BOOT, 0xAE },
    { DXE_EXIT_BOOT_SERVICES, 0xAF },
    { RT_SET_VIRTUAL_ADDRESS_MAP_BEGIN, 0xB0 },
    { RT_SET_VIRTUAL_ADDRESS_MAP_END, 0xB1 },
    { DXE_LEGACY_OPROM_INIT, 0xB2 },
    { DXE_RESET_SYSTEM, 0xB3 },
    { DXE_USB_HOTPLUG, 0xB4 },
    { DXE_PCI_BUS_HOTPLUG, 0xB5 },
    { DXE_NVRAM_CLEANUP, 0xB6 },
    { DXE_CONFIGURATION_RESET, 0xB7 },
    //reserved for AMI use: 0xB8 - 0xBF
    //reserved for OEM use: 0xC0 - 0xCF

    {0,0}
};

STATUS_CODE_TO_BYTE_MAP ErrorCheckpointMap[] =
{
    { DXE_CPU_ERROR, 0xD0 },
    { DXE_NB_ERROR, 0xD1 },
    { DXE_SB_ERROR, 0xD2 },
    { DXE_ARCH_PROTOCOL_NOT_AVAILABLE, 0xD3 },
    { DXE_PCI_BUS_OUT_OF_RESOURCES, 0xD4 },
    { DXE_LEGACY_OPROM_NO_SPACE, 0xD5 },
    { DXE_NO_CON_OUT, 0xD6 },
    { DXE_NO_CON_IN, 0xD7 },
    { DXE_INVALID_PASSWORD, 0xD8 },
    { DXE_BOOT_OPTION_LOAD_ERROR, 0xD9 },
    { DXE_BOOT_OPTION_FAILED, 0xDA },
    { DXE_FLASH_UPDATE_FAILED, 0xDB },
    { DXE_RESET_NOT_AVAILABLE, 0xDC },
    //reserved for AMI use: 0xDE - 0xDF

    {0,0}
};

//**********************************************************************
// Beep codes map
//**********************************************************************
STATUS_CODE_TO_BYTE_MAP ProgressBeepMap[] =
{
    {0,0}
};

STATUS_CODE_TO_BYTE_MAP ErrorBeepMap[] =
{
    { DXE_ARCH_PROTOCOL_NOT_AVAILABLE, 4 },
    { DXE_NO_CON_OUT, 5 },
    { DXE_NO_CON_IN, 5 },
    { DXE_INVALID_PASSWORD, 1 },
    { DXE_FLASH_UPDATE_FAILED, 6 },
    { DXE_RESET_NOT_AVAILABLE, 7 },
    { DXE_PCI_BUS_OUT_OF_RESOURCES, 8},

    {0,0}
};