Wednesday, August 6, 2014

Official Java Tutorial

In the Sprint 2015 I might be teaching Java at CLC.

I am thinking I might use online tutorial instead of a book:

Friday, July 11, 2014

Android Studio: porting Eclipse formatter xml

If you are working in the mix team of Eclipse and Android Studio you will need to share Eclipse formatter.xml to maintain the consistency.

On Mac:

- Android Studio > Preferences.. > search for Plugins
- Browse repositories... [button]
- Search for "Eclipse Code Formatter"
- Instal plugin [button]
- restart  Android Studio
- Android Studio > Preferences.. > Search for "Eclipse Code Formatter"
- find "Eclipse Java Formatter config file" > Browse > select your file
- Apply
- Select Java class to format > Code > Reformat code.. (Shift + command + f)

Monday, June 9, 2014

check what jar processes you have running

check what java jar processes you have running:

 $ ps -Alf | grep jar

Thursday, June 5, 2014

Synchronize date and time on remote board via ssh

If you have a board without a battery then you might want to synchronize a date and time with your computer.

$ DATE=`date` ;  ssh root@ "TZ=America/Chicago date --set '$DATE' " ; echo "local: ";  date ;  echo "remote: " ;  ssh root@ " TZ=America/Chicago date  " 
Mon Jun  9 14:04:16 CDT 2014 
Mon Jun  9 14:04:16 CDT 2014 
Mon Jun  9 14:04:16 CDT 2014
Note that output for Mac is CST and for Linux is UTC.

GIT: cheat sheet

Install GIT

Install Brew - Mac package installer

$ ruby -e "$(curl -fsSL"

Check existing version of git

$ git --version
git version (Apple Git-48)

Install the latest and greatest git version

$ brew install git
 /usr/local/Cellar/git/1.9.0: 1322 files, 30M
$  git --version
git version (Apple Git-48)
uki@ bin $ /usr/local/Cellar/git/1.9.0/bin/git --version
git version 1.9.0

Edit the PATH so he new GIT tool is found first

edit ~/.profile
# GIT tool path
export GIT_TOOL=/usr/local/Cellar/git/1.9.0/
export PATH=${GIT_TOOL}/bin:${PATH}
$ git --version
git version 1.9.0


Checking Status - what has changed 

$ git status

Fetching remote changes

$ git fetch

Rebasing - placing your changes on top of remote changes 

$ git rebase

Branch Operations

Switch to an existing branch

$ git checkout develop

Create a new branch named thrift

$ git checkout -b thrift

Delete an existing branch

$ git branch -D thrift

Tuesday, June 3, 2014

git does not recognize new changes

You changed or added files, but you get...
$ git status On branch release Your branch is up-to-date with 'origin/release'. nothing to commit, working directory clean
Make sure that your .gitignore file does not have pattern as follows: 


Thursday, May 22, 2014

Null Modem DB9 cable

When connection the i.MX6 micro-computer "Debug" cable to Mac's Serial to USB I need to use DB9 cable with female on both ends. As I found out a simple "Mini Gender Changer" (gender-bender) will NOT do, you need a "Null Modem" cable. 

I will provide pin-put diagram shortly, but as I understand at least pins 2 and 3 are reversed. Later I will Ohm-out the pins and build myself a smaller version of what is pictured above.

Tuesday, May 20, 2014

Connecting to i.MX6 with Ethernet

The first way you will probably connect to i.MX6 is via "Debug" Serial-to-USB cable, which is covered by one of my previous posts.

Connect i.MX6 to Ethernet, if you are using WiFi, you can share the connection with your Mac as shown in the picture below:

Go to your CootTerm, or whatever you use to connect Serial to USB:

root@imx6qsabrelite:~# ifconfig
eth0      Link encap:Ethernet  HWaddr 1e:ed:19:27:1a:b3
          inet addr:  Bcast:  Mask:

Now open Terminal and you can

$ ssh  root@

CAN bus software for Mac OSX


It is quite a hunt to try to monitor CAN bus traffic on Mac.

I started with this list:

Monica by DominantBit - FAIL

  • page comes up empty!

CanTrace - FAIL 

  • requires to provide name, company and email
  • takes forever
  • downloads CANtrace PC

I will update this article once I find a reliable tool.

Any comments?


Here is a Java JNI wrapper project for socket-can C++.

$ git clone