2/3: Auto Update Date Column on Row Change

UncategorizedShawnNo Comments

I was needing a method to automatically update a date field when I adjusted my worksheet row.

Auto Date Worksheet

This is what I ended up with. Change ? to what column you want to track updates on.

Private Sub Worksheet_Change(ByVal Target As Range)
    If Target.Cells.Count = 1 And Target.Cells.Column = ? Then
        Target(1, 2) = Date
        Target(1, 2).EntireColumn.AutoFit
    End If
End Sub

1/29: Sorting Dates in Access with Nulls

AccessShawnNo Comments

If you need to get a report sorted and grouped by date but your query contains null values use this expression to solve your dilemma.

=IIf([Ship Date] Is Null,1,0)

Within your Group, Sort, and Total Window set the Sort by to expression:


Add in our code. Ok to finish and your nulls are now at the end of the list.

Expression Builder

5/24: Safe Interrupt Enable / Disable

Axiom, HC12ShawnNo Comments

Having trouble switching from cooperative tasking? One of the easiest oversights is your “sei” and “cli” sections.

The diagram below shows how you can run into problems within the critical sections of code. In this example when the memory allocation ends the interrupts are enabled with “cli” removing the critical section around the linked list manager. Once this happens RTI ISR fires and switches in thread 2. This example shows thread 2 popping an item from this list breaking the flow inside of thread 1.

Read the rest of this entry »

4/29: Threading

Axiom, HC12ShawnNo Comments

Threading allows functions to execute concurrently. The example below shows two threads switching between running and sleeping. As the RTI ISR executes it takes the current process off the schedule (list of processes) and switches in the next process on the schedule. Once all processes have been removed from the schedule the “Scheduler” steps in and creates a new schedule.

Read the rest of this entry »

4/16: Missing FFXI-Garuda?

UncategorizedShawn1 Comment

If anyone is here looking for FFXI-Garuda.com post a comment and I’ll bring it back online.

4/16: Hex Memory Dump

UncategorizedShawnNo Comments

Here is a nice looking hex dump for those interested.

ADDR | B0 B1 B2 B3 B4 B5 B6 B7  B8 B9 BA BB BC BD BE BF | 0123456789ABCDEF
0000 | FF D8 FF E0 00 10 4A 46  49 46 00 01 02 01 00 48 | ......JFIF.....H
0010 | 00 48 00 00 FF ED 0A 96  50 68 6F 74 6F 73 68 6F | .H......Photosho
0020 | 70 20 33 2E 30 00 38 42  49 4D 04 04 07 43 61 70 | p 3.0.8BIM...Cap

Read the rest of this entry »

4/7: HC12 Read String or Char

Axiom, HC12Shawn2 Comments

Use this to read a string on the HC12. What this function does is check to see if there is an available character in the HC12′s Serial Communication Interface Port 0 Data Register. If you need to use this function with 9bit values the function needs to be adjusted to incorporate SC0DRH. Similarity if you would like to use Port 1 change SC0 to SC1.

UPDATE: I added the single char version because thats more basic.
Read the rest of this entry »

1/17: ExtUSB AV Cable

HTCShawnNo Comments

HTC ExtUSB Connector

A – USB Ground
B – +5V allows phone to suck 1000mA to charge faster
C – +USB Data Line
D – -USB Data Line
E – +5V @ 1000mA (If you only have 500mA ground B)
1 – Video Out
2 – Audio Right
3 – Ground (Video Sense)
4 – No connection otherwise you loose video
5 – Audio Ground
6 – Audio Left
Shield – Ground / Cable Shield

12/30: MON12 Jump Table

Axiom, HC12ShawnNo Comments

This is the jump table from the CML12S-DP256 v2.7F. Use this if you want to access MON12 functionality inside of your programs.

Read the rest of this entry »

12/20: HC12 Build you’r own Character

Axiom, HC12ShawnNo Comments

Using code from the manufacturer Axiom and several data sheets to figure out what they are talking about I finally found how to send your own character to the CGRAM (Character Generator RAM).

Read the rest of this entry »