Remove this ad



Posts: 284


Apr 20 10 7:43 PM

Tags : :

Originally Posted by EricN on February 3, 2010 at 11:26pm

Axiotron has dropped the ball on Quickflip, their proposed screen rotation utility that would, like the iPhone, automatically adjust the orientation of the display to match the way the user is holding Modbook. They announced last January, a full year ago, that this would be a free download for Modbooks that support display rotation (which so far are only those with Nvidia graphics chips). Well, we are still waiting.

It occurred to me recently that unlike Axiotron's other broken promises for 2009, the Modbook Pro and Synergy Touch, Quickflip is relatively easy to do. In fact, with Amit Singh's AMSTracker (download here) and my meager AppleScript skills, I think this is doable.

The catch is the Modbook's Sudden Motion Sensor(SMS) that detects forces on the Modbook and makes Quickflip possible may need calibration, may work work differently in Modbooks made from different Macbooks, and, to make matters more complicated, I'm concerned that the SMS in my Modbook may not be working properly.

But no problem. We can make this a community effort. I've downloaded AMSTracker and noted its readings for different orientations of my Modbook. If bunch of other Modbook users do the same, I'm confident that we could put together an AppleScript that runs in the background and re-orients the display in response to movements of the Modbook.

The AMSTracker reads the forces (accelerations) on the SMS in the x, y, and z directions.

For example, when my Modbook is flat on the floor, AMSTracker generates the following output:

Last login: Wed Feb 3 17:11:47 on ttys000

$ /Volumes/AMSTracker\ 0.34/AMSTracker ; exit;

AMS hardware present and initialized

-5 -1 12


[Process completed]

So for flat, the readings are x: -5, y: -1 z: 12.

I've made a bunch of other measurements.

First, rotating around the x-axis:


For +90º rotation about x-axis, x=-7  y=-1  z=11.

For +45º rotation about x-axis, x=-14  y=-1  z=-51.


For -90º rotation about x-axis, x=-10  y=-1  z=10.

For -45º rotation about x-axis, x=-7  y=-1  z=81.

Then, rotating around the y-axis: 


For +90º rotation about y-axis, x=-11  y=0  z=7.

For +45º rotation about y-axis, x=-79  y=0  z=14.


For -90º rotation about y-axis, x=-2  y=-2  z=14.

For -45º rotation about y-axis, x=63  y=-1  z=13.

As you can see, my SMS doesn't measure much force in the y-direction. Perhaps this is normal, but I'm guessing not.

Please contribute to the effort. Download AMSTracker, get the readings for these orientations, and post them in a reply below along with the model and processor of your Modbook. Let's make this happen.

Oh, yes, my Modbook is 2.4 GHz core2duo 800 MHz bus speed (from System Profiler or About This Mac) made from an early 2008 Macbook.

Questions and Tasks

Get this SMS/orientation data for a variety of Modbooks:

2.4 GHz core2duo 800 MHz bus speed, early 2008

2.13 GHz core2duo, 1066 Hz Bu,s Nvidia Graphics Mid 2009. 

Is there better info on the SMS than Amit Singh's site?

Where is the SMS? Is it on the disk drive? If you replace the hard disk with a solid state drive, will it still work?

Certainly, we could build a GUI script to rotate the display, but there is probably a property list (.plist) file somewhere that controls the display, that would make the script faster and easier. Where is the .plist file and what is the property list key controlling display orientation?

What else should we think about?


Quote    Reply   
Remove this ad
Remove this ad



Posts: 284

#1 [url]

Apr 20 10 7:55 PM

Original Reply by EricN on February 5, 2010 at 12:26am

The AMSTracker utility that I used to get the above data is, it seems, designed for a different sudden motion sensor, one in a Powerbook. Fortunately, I found Daniel Griscom's Suitable Systems site where he provides a Mac-based seismic sensor, a tool for calibrating your Mac's SMS, and a software library of tools to make use of the sudden motion sensor. His tools are made to work with a wide variety of Macs, and work perfectly with my Modbook.The data his tools generate is structured around the x, y, z axes shown below,

where a positive one magnitude is given to the axis that points straight up. Hence that following data follows my Modbook starting flat, then tilting up to landscape orientation and back down, then tilting up to portrait orientation:


-0.037167 0.147548 0.999738

-0.088244 0.243957 0.963886

-0.033238 0.012576 0.920067

-0.096102 0.016432 1.031606

-0.045025 0.047283 0.999738

-0.048954 0.043426 1.003721

-0.052883 0.066565 1.003721

-0.029309 0.382787 0.904133

-0.037167 0.614168 0.752759

-0.029309 0.837838 0.505780

-0.033238 0.949672 0.171163

-0.048954 0.961241 0.051657


-0.037167 0.860976 0.414158

-0.033238 0.529328 0.820479

-0.017522 0.112841 0.983804


-0.072528 0.062708 0.999738

-0.418280 0.043426 0.892182

-0.693310 0.051139 0.689022

-0.862257 0.062708 0.450010

-0.952624 0.043426 0.210998


This data is generated by a command line utility, smsutil, which you can download below. Unzip the archive after you have downloaded the zip file, put the smsutil file in your Home folder, launch the (found in the Utility folder), and then type: ./smsutil Then move your Modbook around, and note how the numbers change.

I'm curious if it works as well for others as it worked for me.


Click here to view the attachment

Quote    Reply   



Posts: 284

#2 [url]

Apr 20 10 7:58 PM

Reply by EricN on February 8, 2010 at 7:53pm

I've used Daniel Griscom's smsutil on a 2.13GHz mid-2009 MacBook, and it works. However, as a slight anomaly, it reverses the x and z axes.

It appears that even with User Interface scripting, Applescript seems unable to produce the command, option click needed to access the display rotation controls in "System Preferences". I have had to figure out a work around, but in some cases, the workaround needs a workaround. I"11 post what I've got later
tonight. It works, but due to the screwy approach I've had to take, it is not very practical. Think of it as a proof of concept.

Quote    Reply   



Posts: 284

#3 [url]

Apr 20 10 8:07 PM

Let me add two footnotes to this thread: 

First, the above mentioned screwy approach eventually gave way to a better approach which lead to the AppleScript applet “MacFlip”, found elsewhere in these forums. 

Second, Daniel Griscom's smsutil was updated in February 2010 to correct the axis reversal in some Apple laptops. MacFlip uses the new version.

Download:  [February 2010 version]

Quote    Reply   
Add Reply

Quick Reply

bbcode help