亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? plot.c

?? 基于AVRETH1的最新網絡軟件
?? C
字號:
/*,-----------------------------------------------------------------------------------------.| io/plot|-----------------------------------------------------------------------------------------| this file implements a very basic bmp generator| - plot temperature graph as a black and white BMP|| Author   : {{removed according to contest rules}}|            -> circuitcellar.com avr design contest 2006|            -> Entry #AT2616||-----------------------------------------------------------------------------------------| License:| This program is free software; you can redistribute it and/or modify it under| the terms of the GNU General Public License as published by the Free Software| Foundation; either version 2 of the License, or (at your option) any later| version.| This program is distributed in the hope that it will be useful, but|| WITHOUT ANY WARRANTY;|| without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR| PURPOSE. See the GNU General Public License for more details.|| You should have received a copy of the GNU General Public License along with| this program; if not, write to the Free Software Foundation, Inc., 51| Franklin St, Fifth Floor, Boston, MA 02110, USA|| http://www.gnu.de/gpl-ger.html`-----------------------------------------------------------------------------------------*/#include "plot.h"//ACTIVATE DEBUG by editing this file:#include "debug.h"#define PLOT_BMP_HEADER_LENGTH 62//bmp data must be a multiple of 16 ?! -> maybe add padding !#define PLOT_BMP_WIDTH 264//264 pixel -> 33 byte ! must be divided by 4 -> use 36 byte -> use 288px !#define PLOT_BMP_LINE_WIDTH 288#define PLOT_BMP_HEIGHT 136//288 -> 36 bytes -> 36/4 = 9 -> OK!#define PLOT_BMP_FILESIZE (PLOT_BMP_LINE_WIDTH/8)*(PLOT_BMP_HEIGHT)+62PROGMEM unsigned char PLOT_BMP_HEAD [] = {0x42, 0x4D, 0x5E, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, //100x3E, 0x00, 0x00, 0x00, //first image data at pos 0x3E -> at byte 620x28, 0x00, 0x00, 0x00, //header size (infoheader only!!) -> 40 byteslo8(PLOT_BMP_WIDTH), hi8(PLOT_BMP_WIDTH), 0x00, 0x00, //width <lo,hi,0,0>lo8(PLOT_BMP_HEIGHT), hi8(PLOT_BMP_HEIGHT), 0x00, 0x00, //height <lo,hi,0,0>0x01, 0x00, //1color plane0x01, 0x00, //1bit0x00, 0x00, 0x00, 0x00, //no compressionlo8(PLOT_BMP_FILESIZE), hi8(PLOT_BMP_FILESIZE), 0x00, 0x00, //imagesize in bytes: -> 0x1320 = 4896 bytes0x10, 0x0B, 0x00, 0x00, //x pixels per meter0x10, 0x0B, 0x00, 0x00, //y pixels per meter0x02, 0x00, 0x00, 0x00, //2 colors (B/W)0x02, 0x00, 0x00, 0x00, //2 important colors0xFF, //background B0xFF, //background G0xFF, //background R0x00,0xFF, //foreground B0x00, //foreground G0x00, //foreground R0x00 //62};PROGMEM unsigned char PLOT_BMP_LEGEND[] = {//0x00, 0x00, 0x00,//0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x03, 0xC3, 0x81, 0x02, 0x04, 0x41, 0xE1, 0x04, 0x47,0x00, 0x84, 0x41, 0x00, 0x44, 0x41, 0x02, 0x46, 0x41, 0x01, 0x83, 0x81,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x01, 0xC3, 0x81, 0x00, 0x84, 0x41, 0x70, 0x84, 0x47, 0x00, 0x84, 0x41,0x00, 0x84, 0x41, 0x01, 0x86, 0x41, 0x00, 0x83, 0x81, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x03, 0x81,0x00, 0x04, 0x41, 0x00, 0x04, 0x47, 0x00, 0x04, 0x41, 0x00, 0x04, 0x41,0x00, 0x06, 0x41, 0x00, 0x03, 0x81, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x01, 0xC3, 0x81, 0x00, 0x84, 0x41,0x00, 0x84, 0x47, 0x00, 0x84, 0x41, 0x00, 0x84, 0x41, 0x01, 0x86, 0x41,0x00, 0x83, 0x81, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x03, 0xC3, 0x81, 0x02, 0x04, 0x41, 0x01, 0x04, 0x47,0x00, 0x84, 0x41, 0x00, 0x44, 0x41, 0x02, 0x46, 0x41, 0x01, 0x83, 0x81,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x03, 0x83, 0x81, 0x02, 0x44, 0x41, 0x00, 0x44, 0x47, 0x00, 0xC4, 0x41,0x01, 0x84, 0x41, 0x00, 0x46, 0x41, 0x03, 0x83, 0x81, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x43, 0x81,0x00, 0x44, 0x41, 0x03, 0xE4, 0x47, 0x01, 0x44, 0x41, 0x01, 0x44, 0x41,0x00, 0xC6, 0x41, 0x00, 0x43, 0x81, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x03, 0xC3, 0x81, 0x02, 0x64, 0x41,0x00, 0x24, 0x47, 0x02, 0x24, 0x41, 0x03, 0xC4, 0x41, 0x02, 0x06, 0x41,0x03, 0xC3, 0x81, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x01,0x00, 0x00, 0x01, 0x00, 0x00, 0x01, 0x00, 0x1C, 0x01, 0x00, 0x20, 0x01,0x00, 0x20, 0x01, 0x02, 0x10, 0x01, 0x05, 0x0C, 0x01, 0x02, 0x00, 0x01,0x00, 0x00, 0x01};void plot_test(){	//for (unsigned int x=0; x<288; x++)	//	eeprom_write_byte(&logger_temp_today[x], 130-x/4+80.0*sin((3.14*x)/30.0)/3.14);//  70+(x)%60);	//plot_generate_bmp(&temp[0]);}unsigned int plot_generate_bmp(unsigned char *buffer, unsigned int datapos, unsigned int len, unsigned int streampos, unsigned char source){	unsigned int x;	unsigned char y;	unsigned char out;	unsigned char eedata;	unsigned char hour_counter;	unsigned char eedata_old;	int yee;	unsigned char eepos;	unsigned char b;	eedata = (32<<1);	eedata_old = (32<<1);	//step1: send bmp header (if requested)	PGM_P header_ptr = PLOT_BMP_HEAD;	for(x=streampos; x<PLOT_BMP_HEADER_LENGTH; x++){		buffer[datapos++] = pgm_read_byte(header_ptr++);		streampos++;		len--;		//no more data allowed		if (len == 0)			return 0;	}	//step2 generate plot:	//calculate position: streampos must be > PLOT_BMP_HEADER_LEN now...	streampos -= PLOT_BMP_HEADER_LENGTH;	//-> we must skip now #streampos bytes!		//generate bottom border:	for(x=streampos; x<PLOT_BMP_LINE_WIDTH/8; x++){		if (x<24/8)			buffer[datapos++] = 0x00;		else			buffer[datapos++] = 0xFF;		streampos++;		len --;		//no more data allowed		if (len == 0)			return 0;	}		//recalculate pos:	streampos -= PLOT_BMP_LINE_WIDTH/8;	//skip now #streampos bytes	y = (streampos/(PLOT_BMP_LINE_WIDTH/8));	x = streampos - y*(PLOT_BMP_LINE_WIDTH/8);	//calculate start index of hour counter (draws vertical hour marks)	hour_counter = 10;	if (x>3)		hour_counter = 10 - (((x-3)*8) % 10);			//softuart_puts_progmem("y: ");softuart_put_uint16(y);	//softuart_puts_progmem("x: ");softuart_put_uint16(8*x);	PGM_P legend_ptr = PLOT_BMP_LEGEND;	if (y != 0)		legend_ptr += 3*(y+1);	if (x < 24/8){		legend_ptr += x;	}	y = (135) - y;	unsigned char picpos_now = (clock[CLOCK_HOUR]*60+clock[CLOCK_MIN])/6;	if (picpos_now > (23*60+59)/6)		picpos_now = (23*60+59)/6;	//main image:	for( ; y>1; y--){		//show data:		if (y==92){			for( ; x<PLOT_BMP_LINE_WIDTH/8; x++){				if (x<(24/8)){					out = pgm_read_byte(legend_ptr++);				}else{					out = 0xFF;				}				buffer[datapos++] = out;				len--;								if (len == 0)					return 0;			}			x=0;		}else{			//y = 91 - (((ee-(32<<1))*4)/3)			//-> (ee-(32<<1))*4/3 = (91 - y) <=> (3(91-y))/4 = (ee-(32<<1)) <=> (3(91-y))/4 + (32<<1) = ee			yee = ((92 - y)*4)/3 + (32<<1);						//data source ?!			if (source == PLOT_SOURCE_EEPROM)				eedata_old = eeprom_read_byte(&logger_temp_today[0]); //EEPROM			else				eedata_old = eedata_old + 1; //DATAFLASH			for( ; x<PLOT_BMP_LINE_WIDTH/8; x++){				if (x<(24/8)){					out = (pgm_read_byte(legend_ptr++));				}else{					out = 0x00;										for(b=0; b<8; b++){						out = out<<1;						eepos   = ((x-3)*8+b);						//get data:						if (source == PLOT_SOURCE_EEPROM){							eedata  = eeprom_read_byte(&logger_temp_today[eepos]); //EEPROM						}else{							eedata = eedata + 1; //DATAFLASH -> add later! FIXME						}												//bold line:						//if ((yee+2 > (eedata&0xFF)) && (yee-2 < (eedata&0xFF)))						//	out += 1;						//filled:						/*if (yee > (32<<1)){							if (yee < (eedata&0xFF))								out += 1;						}else{							if (yee > (eedata&0xFF))								out += 1;						}*/						//connected line:						if (eedata_old < eedata){							if ((yee > eedata_old-1) && (yee <= eedata+1))								out |= 1;						}else{							if ((yee <= eedata_old+1) && (yee > eedata-1))								out |= 1;						}						eedata_old = eedata;						//add now marker:						if (eepos == picpos_now)							out |= 1;												//draw a vertical line every 60min (=10px)						hour_counter--;						if (!hour_counter){							hour_counter = 10;							if(!(y&0x03))								out|=1;						}					}					//mark every 48 min (=8 pixel)					//if(((x-3)&0x01) && (y&0x01))					//	out|=1;				}				//right border				if (x == ((PLOT_BMP_WIDTH/8)-1)) //BMP WITH !!! (=280, do not use 288 here)					out |= 1;				buffer[datapos++] = out;				len--;				streampos++;				if (len == 0)					return 0;			}			x = 0;			//restart hour_counter (draws vertical lines)			hour_counter = 10;		}	}		//recalc streampos:	streampos  = streampos - 134*(PLOT_BMP_LINE_WIDTH/8);	legend_ptr = PLOT_BMP_LEGEND + 134*3;	//generate bottom border:	for(x=streampos; x<PLOT_BMP_LINE_WIDTH/8; x++){		if (x<24/8)			buffer[datapos++] = pgm_read_byte(legend_ptr++);		else			buffer[datapos++] = 0xFF;				len--;		if (len == 0){			if (x<PLOT_BMP_LINE_WIDTH/8-1)				return 0;			else 				return datapos;		}	}	return datapos;}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产91精品欧美| 欧美日韩精品一区二区在线播放| 亚洲最新视频在线观看| 欧美不卡一二三| 欧美日韩国产一级二级| 成人一级片在线观看| 日本不卡一二三| 亚洲伊人伊色伊影伊综合网| 亚洲国产成人午夜在线一区| 日韩精品一区二区三区在线观看| 日本道在线观看一区二区| 国产91富婆露脸刺激对白| 日韩精彩视频在线观看| 亚洲免费在线观看| 久久久久久久av麻豆果冻| 欧美一级精品大片| 欧美色图片你懂的| 91免费看`日韩一区二区| 国产精品 日产精品 欧美精品| 免费日韩伦理电影| 亚洲第一福利视频在线| 一区二区三区国产精华| 亚洲视频一二三区| 国产精品久久久久久户外露出| 26uuu色噜噜精品一区二区| 欧美一区二区视频在线观看| 欧美日本一道本在线视频| 91成人免费在线视频| 色综合久久久久综合体桃花网| 岛国av在线一区| 国产v日产∨综合v精品视频| 国产成人在线免费观看| 国产一区亚洲一区| 激情文学综合丁香| 国产一区二区女| 国产美女在线精品| 国产成都精品91一区二区三| 国产福利一区二区三区在线视频| 精品一区二区国语对白| 九九精品一区二区| 蜜桃久久av一区| 九色综合狠狠综合久久| 精品一区二区日韩| 国产精品亚洲一区二区三区妖精| 国产精品伊人色| 不卡的av中国片| 色偷偷88欧美精品久久久| 欧美最新大片在线看 | 一本大道久久a久久精品综合| 国产成人精品免费一区二区| 国产成a人亚洲精品| 高清av一区二区| 99re热这里只有精品视频| 91小宝寻花一区二区三区| 在线视频你懂得一区二区三区| 欧美在线免费观看亚洲| 欧美精品在线观看一区二区| 欧美大胆一级视频| 久久一区二区视频| 国产精品成人免费| 亚洲国产另类精品专区| 麻豆91在线观看| 国产精品夜夜嗨| 色哟哟国产精品| 7777精品伊人久久久大香线蕉超级流畅 | 欧美在线观看视频在线| 91黄色激情网站| 91麻豆精品国产| 久久精品夜色噜噜亚洲a∨| 亚洲欧洲精品一区二区三区| 午夜国产不卡在线观看视频| 国内精品视频一区二区三区八戒| 波多野结衣精品在线| 欧美视频自拍偷拍| 久久综合色8888| 夜夜精品视频一区二区| 久久国产精品免费| 一本大道av伊人久久综合| 91精品国产一区二区三区| 国产欧美视频在线观看| 亚洲国产日韩在线一区模特| 黄一区二区三区| 日本伦理一区二区| www国产亚洲精品久久麻豆| 一区二区三区中文在线| 国产精品一区二区久久不卡| 欧美日韩亚洲综合在线| 欧美国产精品v| 午夜亚洲国产au精品一区二区| 成人午夜私人影院| 欧美一区二区三区影视| 国产精品视频一二三| 另类中文字幕网| 欧美亚洲愉拍一区二区| 欧美国产1区2区| 老司机一区二区| 欧美专区亚洲专区| 亚洲国产成人一区二区三区| 麻豆国产91在线播放| 91精品91久久久中77777| 国产亚洲欧美在线| 日本亚洲三级在线| 一本色道久久综合亚洲aⅴ蜜桃| 2020国产精品自拍| 日韩成人免费电影| 欧美视频一区二| 亚洲视频香蕉人妖| 国产iv一区二区三区| 欧美一区二区在线播放| 午夜一区二区三区视频| 一本色道久久综合亚洲aⅴ蜜桃 | 亚洲成人av在线电影| 99久久久久免费精品国产| 久久中文娱乐网| 九九**精品视频免费播放| 日韩视频一区二区三区| 亚洲成人免费av| 欧美在线视频你懂得| 亚洲精品国产无套在线观| 成人在线综合网| 中文字幕不卡三区| 国产精品91xxx| 国产视频一区在线播放| 国产原创一区二区三区| 日韩一级免费一区| 日韩av高清在线观看| 欧美日韩精品一区二区三区蜜桃| 亚洲尤物在线视频观看| 欧美在线观看一区| 怡红院av一区二区三区| 色婷婷久久99综合精品jk白丝| 亚洲人成亚洲人成在线观看图片 | 欧美在线免费视屏| 一区二区三区高清不卡| 在线观看亚洲专区| 性做久久久久久久免费看| 欧美日韩激情一区二区三区| 亚洲成人你懂的| 欧美一区二区美女| 蜜桃精品在线观看| 亚洲精品一区二区精华| 激情偷乱视频一区二区三区| 久久日韩精品一区二区五区| 国产在线视频精品一区| 欧美激情中文字幕| 97久久久精品综合88久久| 亚洲精品网站在线观看| 欧美色爱综合网| 免费成人在线网站| 久久综合色一综合色88| 福利一区二区在线| 亚洲少妇屁股交4| 欧美日韩精品一二三区| 久久91精品国产91久久小草| 欧美激情综合五月色丁香小说| 97久久超碰精品国产| 亚洲va国产va欧美va观看| 日韩一区二区三区免费观看| 91免费国产视频网站| 亚洲成a人片在线不卡一二三区| 欧美一区二区三级| 国产成人免费视频| 亚洲精品视频免费观看| 6080午夜不卡| 国产成人欧美日韩在线电影| 伊人一区二区三区| 日韩欧美精品三级| 成人精品高清在线| 亚洲小说欧美激情另类| 欧美不卡123| 色老汉一区二区三区| 蜜臀av国产精品久久久久| 久久精品在线观看| 欧美亚洲国产怡红院影院| 六月丁香综合在线视频| 1024国产精品| 欧美一级高清片在线观看| 99视频热这里只有精品免费| 丝袜美腿亚洲综合| 中文字幕不卡一区| 91精品国产入口| 91色|porny| 久久99国内精品| 亚洲一级二级三级| 欧美激情艳妇裸体舞| 欧美疯狂性受xxxxx喷水图片| 成人黄色国产精品网站大全在线免费观看 | 欧美视频在线一区| 国产 欧美在线| 久久精品国产99久久6| 一区二区三区资源| 日本一区二区不卡视频| 欧美妇女性影城| 色欧美乱欧美15图片| 高清不卡在线观看av| 蜜桃在线一区二区三区| 亚洲综合色成人| 欧美国产精品久久| 亚洲精品在线一区二区| 8x福利精品第一导航|