Arduino killed trying to load a sketch?
I know after awhile on my arduino that i had to start pressing the reset button before sending the sketch, this may help. Next try just using a simple LED blinky sketch(can be found in the examples on the IDE) If it works your arduino is fine. 

as for the other sketch I don't understand what you mean by this 


  This code [does not] work for me, until I break line into two separate and re-merge at runtime. I need to remove some piece of code to make it works.


can you explain that a little better?