static void  __stdcall timer_proc(HWND,unsigned int, unsigned int, unsigned long) {
 		///*
	write_read_serial(hSerial,tx_data);
	if(dwBytesRead>1){
		//printf ("Bytes %d\n",dwBytesRead);
		chars_read=0;
		while(chars_read<dwBytesRead&&serial_packet_arrived==FALSE){
			if(szBuff[chars_read]=='$'){
				bytes_read_till_now=0;
				if(chars_read>1){
					printf("zeroed\n");
					int zero=0;
					for(zero=0;zero<31;zero++)
						read_data_buffer[zero]='0';
				}
			}
			read_data_buffer[bytes_read_till_now]=szBuff[chars_read];
			bytes_read_till_now++;
			chars_read++;
			if(bytes_read_till_now==31){
				serial_packet_arrived=TRUE;
				bytes_read_till_now=0;		//zero counter
				valid_packet=TRUE;			//Check for validation right after
			}
			else 
				if(bytes_read_till_now>31){
					printf("error\n!!!");
					break;
				}
		}//while	
	}
	if(serial_packet_arrived){//Check for consistency
		#include "code/packet_consistency.cpp"
		if(valid_packet){
			#include "code/update.cpp"
		}
		else
			printf ("Invalid packet\n");
	}
	//*/
	
	//Read from VBOX
	//write_read_serial_vbox(hSerial_vbox);


 }