I wanted to discuss how I have recently setup my desk at my office in an attempt to be ergonomically correct. I hope that this may help you set up your own office/home desk to allow for ergonomically correct computer use.

To build the monitor stand, I bought a wall shelve from IKEA, specifically the EBKAY JARPEN in size 46 7/8X11″. I then also bought two 4 packs of Capita legs from IKEA. These 4 packs of Capita legs come in different sizes 4″, 6″, 8″. I bought the 6″ version for this setup but since I am 6’4″ I liked the few extra inches. Most people probably just want the 4″ legs.

Once I bought the wall shelve and the legs from IKEA I had to install all of the 8 legs. This required me to measure out with a tape measure equal spacings between the legs and I marked the locations with a pencil. I then took a drill and drilled each of the holes in a bit. This made it easier for me to then take a screwdriver and screw in all 8 legs with screws.

The desk was supplied by my employer Ellumen so I am not entirely sure where it came from.

For the keyboard tray I bought a Humanscale 6G keyboard system.  This was ordered online and I had it come with a 12R swivel 10″ right mouse platform as well. Ergodirect allows you to customize the track length and track and this will depend on your desk.  My desk is very deep so I selected the 27″ track and the more than 22″ clear space under the track length option. You should measure your own desk to see which length is right for you.

Once the Humanscale 6G keyboard system arrived I had to install it. The first step was to install the track underneath the desk. What is nice about the Humanscale keyboard system is that you can peel off a sticker on the track and mount it to the underside of the desk.  Then I had to lie on my back underneath the desk and screw in 10 screws directly into the bottom of the desk. This was a bit difficult and required a lot of strength and use of several screw drivers. Now my desk is thick so none of these screws popped up through the top but this is something to be careful of. You will want to install the track about 1/2″ back from the front of your desk. Humanscale provides clear instructions on all the installation steps. I also had to put in 2 rubber stoppers in the screws at the back of the track. This is to prevent the arms from going too far back.

Once the track was installed I simply had to insert the 6G arms into the track. Once the arms were in place, I put the keyboard tray on the arms and used 4 screws to screw it into place. There is also a front locking mechanism to prevent the arms from coming out that can be installed as the last step which requires 2 addition screws into the bottom of the desk.

The Humanscale 6G keyboard system allows for the keyboard to be adjusted up and down so that you can get the proper height you want. It also allows for a negative tilt up to 15 degrees.  I currently have the negative tilt set at 10 degrees. A negative tilt has been recommended to help maximize neutral hand, wrist, and upper body postures. However, it is important to note that the negative tilt on the keyboard tray also causes a negative tilt on the mouse tray. This will cause the mouse to roll down where as the keyboard tray has some rubber to prevent this. To counter this mouse rolling motion due to gravity, I used the Allsop Wrist Aid which has a 7 degree positive tilt.

The mouse I am using is a Smartfish Ergomotion Laser Mouse. The mouse takes a small amount of time to get used to but the design of the mouse allows it to rock, swivel, and pivot and may help with repetitive stress injury and wrist pain.

Regarding the keyboard, I am currently just using a standard Dell keyboard although I prefer using Microsoft Natural Keyboards and use one at home.  I recently purchased the Microsoft Natural Keyboard 4000 but ended up returning it. I have been using a Microsoft Natural Multimedia Keyboard for many years at home but it has been discontinued by Microsoft. The Microsoft Natural Keyboard 4000 is supposed to be a follow up to the Microsoft Natural Multimedia Keyboard; however, I was disappointed because the Microsoft Natural Keyboard 4000 has keys that feel too squishy and spongy for my liking where as the Microsoft Natural Multimedia Keyboard has tactile keys which do not have this feeling. I do hope Microsoft can release a version to my liking of their Natural Keyboard series line soon.

The chair I am using is a Gelvas High-Black Vinyl Chair from Office Depot, although I am sure there are better chairs available.

If you have any thoughts or suggestions let me know in the comments.

todd_office_desk_setup

So in case you were not yet aware, I have recently moved out to the Washington D.C. area upon completing my masters degree in Biomedical Engineering at Northwestern University in Evanston, Illinois. I am now living in Northern Virginia (specifically Rosslyn, Virginia, which is in Arlington County). I am now working for a company called Ellumen, Inc. in the Rosslyn area. Here are some recent pictures I took while walking around the area after work.

national_mall

arlington_national_cemetery

washington_dc

the_capitol

I have spent a significant amount of time attempting to write a dll in C/C++ and call it in Matlab. An article was previously written on this topic at http://guoliangye.com/2009/01/21/how-to-write-a-dll-in-cc-and-call-it-in-matlab/ (link no longer working as of 2018) but I feel the need to discuss it further in both the Windows and Linux environments.

In Windows 32 bit with 32 bit MATLAB.

1) Create two files named Test.h and Test.cpp

Test.h

#ifndef MY_API
#define MY_API extern “C” __declspec(dllexport)
#endif
MY_API int add(int a, int b);
MY_API int sub(int a, int b);

Test.cpp

#ifndef MY_API
#define MY_API extern “C” __declspec(dllexport)
#endif
#include “Test.h”
int add(int a,int b)
{
return a + b;
}
int sub(int a,int b)
{
return a – b;
}

2) Compile into a DLL (.dll) file using Visual Studio 2008 Professional or Express Edition. If neither is installed, you will need to download and install. Check the MATLAB documentation to see the list of all of the supported compilers for your version of MATLAB .

Step by step instructions for creating a .dll using Visual Studio can be found at http://msdn.microsoft.com/en-us/library/ms235636(VS.80).aspx

3) You then need to copy the newly created .dll file along with the original .h file to a MATLAB directory search path or you can just include the call to the directory.

Now open MATLAB and type

loadlibrary(‘Test.dll’, ‘Test.h’);

4) You can view the newly loaded function using

libfunctionsview Test;

5) You can also call the functions such as

A = calllib(‘Test’,’add’,5,4);
B = calllib(‘Test’,’sub’,5,4);

6) You can also unload the library using

unloadlibrary Test

In Windows 64 bit with 64 bit MATLAB.

Getting the dll file to compile in the 64 bit Windows version is a bit more tricky. MATLAB wants a C file not a C++ file. So one needs to be careful.

1) Create two files named Test.h and Test.c

Test.h

int sum(int, int);

Test.c

__declspec(dllexport) int sum(int a, int b)
{
return a + b;
}

NOTE: A “.c” file is not a selectable file type in Visual Studio 2008 so you may have to manually enter the file extension. You can select a .cpp file when adding to your project, but make sure to call it ‘Test.c’ so that .cpp is not the extension.

2) Compile into a DLL (.dll) file using Visual Studio 2008 Professional SP1.  Check the MATLAB documentation to see the list of all of the supported compilers for your version of MATLAB .

Step by step instructions for creating a .dll using Visual Studio can be found at http://msdn.microsoft.com/en-us/library/ms235636(VS.80).aspx

However, you need to be careful here. Before building the dll you need to go into properities and then the configuration manager and then choose a new active solution platform. Then you need to select ‘x64’ copy the settings for win32 and click OK.

Now you may or may not see x64. By default the x64 compiler is not installed during the install of Microsoft Visual Studio 2008 Pro. You will need to select it or just choose the full install. Even doing this I had an issue where it would not show up unless I also installed SP1. So make sure you install SP1 and select the x64 compilers if you do not do a full install, they are not default.

These instructions go into more details on getting a x64 .dll to work http://msdn.microsoft.com/en-us/library/9yb4317s.aspx.

3) You then need to copy the newly created .dll file along with the original .h file to a MATLAB directory search path or you can just include the call to the directory.

Now open MATLAB and type

loadlibrary(‘Test.dll’, ‘Test.h’);

4) You can view the newly loaded function using

libfunctionsview Test;

5) You can also call the functions such as

C = calllib(‘Test’,’sum’,5,4);

6) You can also unload the library using

unloadlibrary Test

In Linux 64 bit with 64 bit MATLAB.

1) Create two files named Test.h and Test.c

Test.h

int add(int a, int b);
int sub(int a, int b);

Test.c

#include “Test.h”
int add(int a,int b)
{
return a + b;
}
int sub(int a,int b)
{
return a – b;
}

NOTE: An extra return should be added to the end of both of these files.

2) You will want to open up the Terminal. Then you will want to enter

sudo apt-get install build-essential

This will install gcc/gcc++ which will be needed to compile.

You will be compiling into a .so file. To do this make sure the two files you created in (1) are located in your username directory, if not copy them there. Then in the terminal type the following

gcc -c -fPIC Test.c -o Test.o
gcc -shared -Wl,-soname,Test.so.1 -o Test.so Test.o

3) You then need to copy the newly created .so file along with the original .h file to a MATLAB directory search path or you can just include the call to the directory.

Now open MATLAB and type

loadlibrary(‘/home/username/Test’,’/home/username/Test.h’)

Where username is the username you are on your Linux Install.

4) You can view the newly loaded function using

libfunctionsview Test;

5) You can also call the functions such as

A = calllib(‘Test’,’add’,5,4);
B = calllib(‘Test’,’sub’,5,4);

6) You can also unload the library using

unloadlibrary Test

NOTE:

The above was originally run and tested in December 2009 on a computer running Windows XP 32 bit and  MATLAB 2009 B 32 bit version,  on a computer running Windows 7 64 bit and MATLAB 2009 B 64 bit, and on a computer running Ubuntu 9.04 64 bit computer running MATLAB 2009 A 64 bit version.

This was also tested in November 2010 as an update on a computer running Ubuntu 10.10 64 bit with MATLAB 2010 B 64 bit version.

Refer to the latest MATLAB documentation for updates and what compiler you will need.

MATLAB documentation provides further information of using C shared libraries in MATLAB.

Further you may encounter errors relating to copying and pasting the above directly into files. Therefore I encourage you to directly type out all the files and commands.

I wanted to update everyone on the Northwestern University Men’s Basketball and Football teams and their progress so far as of Christmas 2009. Happy Holidays to all!

Thus far I have been very impressed with both team’s play.

The Northwestern Men’s Basketball team is 10-1. The only loss is a home loss to a ranked Butler team. Big Ten play starts against Illinois on December 30th, 2009.

Two good articles to read on the Basketball team are at http://sports.espn.go.com/chicago/columns/story?columnist=powers_scott&id=4766881 and http://sports.espn.go.com/ncb/columns/story?columnist=katz_andy&id=4766773.

Hopefully this will be the first time the basketball team makes the NCAA march madness tournament as many are predicting at this point.

Andy Katz at ESPN.com writes.

…Northwestern, for the first time ever, will be in the Dance. The Wildcats won’t be on the bubble, either. I predict NU will be in the field by the last week of the regular season.

Moving on to the Northwestern University 2009 Football Team. The Wildcats finished the regular season at 8-4.

The Wildcats will be playing the Auburn University Tigers at the Outback Bowl in Tampa, Florida, on January 1, 2010 at 10 AM CST and shown nationally on ESPN. I plan to be in attendance at the game and cheering on the wildcats for hopefully their first bowl win.

Northwestern is looking for it’s first bowl win since 1949. Here is a picture of the team celebrating a win at Purdue earlier this season.

purdue_northwestern_football_game_09

Recently, I had the privilege of attending a Chicago Bulls basketball game at the United Center on December 17, 2009. The Bulls won 98 to 89 versus the New York Knicks. Here are some pictures from the basketball game. The pictures are mostly of pre-game and half-time warmups. One picture gives respect to Michael Jordan and Scottie Pippin.

bulls_game_4

bulls_game_3

bulls_game_2

bulls_game_1