I want to upload my Arduino code to a Micro controller(ATMega16).My code is working properly in Arduino Mega2560, is it work properly in controller or i have to change something in code to make it work properly ?
What do you mean by that title? Usually in the Arduino world we compile the code every time before we upload but when you say "Using of Arduino Code Hex File", that sounds like you want to upload a pre-compiled .hex file.
Whether code that works on an ATmega2560 will also work on an ATmega16 depends on the code but uploading a .hex file compiled for ATmega2560 to an ATmega16 is much less likely to work.