Skip to main content

Posts

Showing posts from March, 2016

【WP】Role Model

劉安婷 (Anting Liu) By watching her TED talk in 2013, I knew her story. She is the founder of Teach for Taiwan which is a nonprofit organization that aims to help children in rural areas have a proper education. 1.  Focus and go all-out for her dream After she told her parents that she decided to get into a university in the U.S.A., her parents set two conditions. First, she had to get an excellent score in GSAT in Taiwan. Second, she needed to get a scholarship to reduce the tuition fees in the university in the U.S.A. During the time she had been working on for that goal, she taught herself English and only slept 4 or 5 hours a day. In the end, she made it and got a full amount scholarship from Princeton University. 2. Willing(adj.) to help people During her days at Princeton, she devoted herself to volunteering in different parts of the world, including Haiti, Ghana(迦納) and Cambodia(柬埔寨) 3.  Willing to solve problems, make actions Although she had a job

ScanSettings.Builder().setReportDelay()會有硬體不支援的狀況發生

Q: ScanSettings.Builder(),在Nexus 7上可以設定ScanMode,但是一將setReportDelay填入非0值,就ScanCallback就會吐onScanFailed,errorCode是4( SCAN_FAILED_FEATURE_UNSUPPORTED )。 A: 由於是新的API,所以可能會發生硬體不支援的狀況。可以使用下列程式碼做檢測: if  ( bluetoothAdapter .isOffloadedScanBatchingSupported())     Log. d ( TAG ,  "Scan Batching is Supported" ); else     Log. d ( TAG ,  "Scan Batching is NOT Supported" ); 如果出現Scan Batching is NOT Supported表示該裝置不支援這個功能,填入非0值就會出現錯誤。 P.S 可以使用isOffloadedFilteringSupported檢查是否支援應用filter。 bluetoothAdapter . isOffloadedFilteringSupported (); 參考: http://stackoverflow.com/questions/35266845/how-to-fix-android-ble-scan-failed-feature-unsupported-on-nexus-5 這封郵件來自 Evernote。Evernote 是您專屬的工作空間, 免費下載 Evernote

【新知練習】 Android XmlPullParser-Basic

由於Android系統內挾帶大量xml檔案,所以便想研究一下XmlPullParser的作用跟用法,本文主要參考網路、Android開發者網頁,並製作讀取政府開放資料(空氣品質資料)的範例。

【實用技巧】 用7-zip合併mp3檔案

網路上有人分享怎麼用7-zip合併mp3檔案,但是合併後的檔案並沒有真的把mp3合併起來,原來是步驟二的設定有改,這邊做個筆記給以後的自己或其他人參考囉。 步驟一 :選取要合併的mp3檔案們->點選右鍵->7-Zip->加入壓縮檔 步驟二:設定各項參數。檔案名稱一定要是「xxx.mp3」,壓縮檔格式要設定為「7z」,壓縮層級選擇「封存」。接著按下確定就完成了。