Saturday, February 18, 2012

[wares]

Still remember my HDD hack back in 2009?

Last tuesday, my E8410 suffered a BSOD then followed by a core dump.
It din't managed to reboot after all that. Can't even complete the POST (Power On Self Test)

I have tried various troubleshooting sequence, trying to isolate the problem.
1. Ram, by swapping fresh rams.
2. Pull out the hdd and CDrom just to boot from bare machine

It has beeping sounds, with various sequence.
1 long 2 short
1 long 3 short
4 short
=============================================

FML, time to waste $$$ again.

Tuesday, February 14, 2012

[game] Shogun2 Legandary difficulty level for Tokugawa clan pt2

Perseverance my friends. After countless events of total annihilation by my rival daimyos', my army turned against me, rebellion created by enemy monks. I survived until turn 220.

The methodologies to win the war are rather idiosyncratic. War is all about money and economics. 

My shogunate could not progress at the tech tree at a faster pace then my rivals. Hence my soldiers are mainly regular yari ashigaru and bow ashigaru with the exception few units of sword samurai. My castles are 2 level below my rivals and the production speed of my soldiers are rather limited. Most of the time, my army was outnumbered. I learned to let go my ego of banging head on with the hardened enemy and circumvent them using my newly devised methods. 

Having said that amassing a large fleet of ships, large contingent of army and agent units are very taxing on the finance for the rival state. I make a good guess on the financial status and the rice supply status. At every turn, maybe my rivals are not making enough profit to cover the new army created.  

If you guys could recall months back game play at turn 45, I have a couple of metsuke (secret police) running around, coupled with some monks and ninjas. 

My metsukes' was leveled up regularly by apprehending rival agent units at each and every turn. The success rate of apprehending grow slowly from 20% to 95%. While level up, I would choose to develop the bribery skill to the highest level. Usually, the apprehending would be successful, because Tokugawa clan specialty have a +2% of success rate.

I did level up my ninjas' too. Sabotaging rival rice plantations at every turn. This would decrease the rice supply by -1. Beside rice plantations, structures such as castle gate, rice merchant, tea house are possible targets too. If rival army are marching near to my territory, my ninja would sabotage the army to buy me time to lay an ambush. The skill sets of the ninja are build towards the "Ninjutsu" at level6. After my ninjas were leveled up, I start the process of assassinating rival generals, to make the rival army bare naked without the positive influence of a general. 

As for my monks, I send them far back into enemy lines, creating rebellion at poorly garrison castle. Of course, along the way I would use my monks to convert the enemy agent units.

The above 3 steps requires very little money to sustain. The bulk of my profit goes to building elite shock troops. It really took a very long time to build army that are truly useful. 

With my newly acquired army, sufficiently trained agent units and MONEY. The journey of clearing the Hatakeyama clan eastwards begin. At that point of time, having war at both sides of my border is a strict no no to the financial status. At the west borders, I have my agent units sabotaging enemy army and preventing them from marching to my land. At the east borders, my army is still outnumbered by the rivals. Good thing is, not every army are lead by a general. I would use my metsuke to attempt to bribe this category of army. Once successful, I would march my army near to this newly acquired army and enter battle with the rival and try to outnumber them. Once the enemy retreat or loses the battle, I attack the castle and loot the castle. Looting gave my shogunate a 20K income. Remember to set the newly acquired castle to no tax and put a metsuke to oversee the town, just in case of rebellion. 

With the new money, I could attempt to bribe more army. Some army are lead by general. Simple, send in the ninja to attempt assassination. If successful, send in the metsuke to bribe. If successful again, merger the new army with the current ones I have. Send in a ninja to sabotage the castle gate before sending in the merged army of mine. If successful, loot the castle. My rival clan recruited super elite units such as Bow hero, Sword Hero, Yari Hero, Great Guards and more. Bribing this army would make this units at my disposal. Indirectly, my army get level up without upgrading my castle facilities. 

The cycle repeats itself again. With some variations along the way of course.




revenge is sweet.
Game statistics suggesting the gruesome path that leads to the rising of my Tokugawa clan. 

I have created 4 vassal states, just to trade with. Trading will increase the financial profit. Occasional rebels were created by my monks. Then I would send in my generals to put out the rebellion. Indirectly, my generals get to level up!

The characteristic of the Tokugawa clan requires the training of the arts, rather than bushido.

Taxes are on the high side, but the populations are happy! Just train the Daimyo with lots of honour.

One of my awesome general with the traits of "Intimidating"

One of my awesome army with awesome agent units.

Check out my save game

Tuesday, February 7, 2012

[Arduino] 4x4x4 LED cube

I was really caught up with work, as always but I will try to update as frequent as possible.

back in 2009, I came across the idea of making 3x3x3 LED cube as part of the teaching material for programming, electronics , and leading the concept to computer engineering.
http://shin-ajaran.blogspot.com/2009/06/diy-3x3x3-led-cube.html

Now at late 2011/ early 2012 one of my project students, Eagle. He picked up the idea and superseded my 3x3x3 with his creation of 4x4x4 LED cube with some really awesome electronics circuit skills and soldering skills... that is soldering of 48LEDs into 3 layers, each layer consist of 16LEDs, with a XYZ+ (I lost count of it) solder joints.  IMBA!! To make life easier he is making this into an arduino shield for those that are interested to pick it up easily (minus the hassle of soldering, just plug and play).



Now hook it up to the arduino microcontroller. 4pins to control the layers , 4+4 pins to control the individual LEDs at each layer, 4 analog pins to control the dimming effect. Displaying of patterns on the LED cube requires the idea of refreshing the pattern at a high speed, to give human an illusion that there is animation. In actual fact, the LED just took turn to light up, one by one. 

now, code time. This code can be quite scary, looking at the binary pattern used to display the led pattern and using progmem to store the "animations". The code was adopted from an instructable.


The end product is totally worth the hours put in to this pet project! Check it out~


Next stage, would be modifying the circuit to use LED driver chip MAX7221. Luckily I bought some during my last visit to Shen Zhen.

I brought this LED cube around, like a young boy showing off his geeky toy. Upload to my facebook account just to attract some interest.... Little did I know, one of my programming class student surfaced with his 3x3x3 LED cube that he has made.... And the voyage to kernel begins...
check this out yo!