Posts

Showing posts from August, 2012

Chinese Android Debugging: How to use a Unbranded Android Device for Application Testing on Ubuntu with Eclipse

Image
developer.android.com has a nice writeup on how to setup a hardware android device for application testing on the Using Hardware Devices page. It also gives a list of USB Vendor IDs, which are required to setup your hardware device. But the list of vendors may not include your Chinese / Unbranded android phone or tablet. For eg. The vendor ID of a NATPC/MID tablet is apparently not on the list of vendor ids which includes the likes of HTC, Asus, Google,Foxconn, etc. In such a case, these are the errors you may get: On selecting Run app in Eclipse, you are greeted with a prompt asking you to select an Android Device. However the list of Android devices shows a Android Device with Serial Number as "??????????" i.e a series of question marks and same for the state of the device. Additionally, this device is not selectable. Eclipse: Prompt showing unrecognised android device  Open Terminal and cd into your android-sdk/platform-tools folder and run adb (Android Debug

CS50: "undefined reference to `GetString' " and other errors

Image
I was going through the CS50 lectures of Fall 2011. CS50 recommends using the CS50 Appliance which is a VirtualBox installation of Fedora with libraries and software needed for the CS50 course. However, if you are already running a flavour of Linux (Ubuntu 12.04 in the case of this article) and want to do the examples natively, read on. On Linux, the CS50 manual gives instructions on how to install the CS50 Library for C  for Linux ( Fedora / Ubuntu ). After installing the CS50 Library for C, I tried running some samples. While making pointers.c in the Week 5 lecture, I came across this error $make pointers cc     pointers.c   -o pointers pointers.c: In function ‘main’: pointers.c:27:5: error: ‘for’ loop initial declarations are only allowed in C99 mode pointers.c:27:5: note: use option -std=c99 or -std=gnu99 to compile your code make: *** [pointers] Error 1 If instead of using make, you use gcc pointers .c you will get a similar error. To correct this, I ran $gcc pointers.