Selecting an Epoch to count from

April 30th, 2010

When starting a project a good way to select an epoch would be to select the closest year in the past that is divisible by 400.

This will simplify time conversions to / from days since epoch to years as
Years that are evenly divisible by 100 are not leap years, unless they are also evenly divisible by 400, in which case they are leap years.

Sam Uncategorized

Naming Convention

October 26th, 2009

Class_Name

Structure_Name
variable_name

MethodName
_argument_name

Sam Uncategorized

Change SVN Editor

October 7th, 2009

in bash type
export SVN_EDITOR=gedit

Sam Uncategorized , ,

CFLAGS to get assembly and c code together

October 5th, 2009

export CFLAGS = -Wall -g -Wa,-a,-ad,-ahls=$@.lst

Sam Uncategorized

svn & kompare

September 24th, 2009

svn diff -r500 | kompare -o -
svn diff -r549:551 | kompare -o -

Sam Uncategorized , ,

Blue Ink

September 19th, 2009

Weird thing about some government forms is you cant use blue ink. There should be a list of reasons for this. Here are some of my suggestions.

And the color shall be black. Not Grey, nor green or yellow. Red is right out.

If any other color than black is used the writer shall perform tracing jobs over all blue.

The reader of this document may be color blind to any color than black.

Sam Uncategorized

Inline Assembly set / clear status register

September 1st, 2009

/*Lock Interupts*/
uint16 srTemp;
asm volatile (”move.w %%sr, %0;” : “=r”(srTemp)::/*none*/);
asm volatile (”move.w #0×2700, %sr;”); /* Lock out interrupts */

Sam Uncategorized

Assembly listing from a make file

August 31st, 2009

%.o: %.cpp $(HEADERS)
@$(CC) -c $(CFLAGS) -c -g -Wa,-a,-ad,-ahls=$@.lst $(INCPATH) $< -o $@
@echo Compiling $<

Sam Uncategorized

Visual Command Alpha 0.0.0.0.0.1

June 22nd, 2009

Visual Command

I have been playing around with this idea since I graduated in May.  I learned a lot about QT from this project.

It can dynamically create an interface for a command prompt application.

It currently uses check boxes, numerical integer , and strings as inputs.

Files, doubles, and sliders will be next, along with a way to upload/download GUI interfaces to a server.

It was built using QT over the previous month.  Never used Qt before so it was more of a learning experience.

Visual Command Edit ModeVisual Command run Mode

Sam Uncategorized

Calling base function, and base constructor C++

June 17th, 2009

class ParentClass{

ParentClass(){

}

void FunctionA(){

}

}

class ChildClass:ParentClass{

ChildClass():ParentClass(){

}

void FunctionA(){

ParentClass::FunctionA();

}

}

Sam Uncategorized ,