Thread has been deleted
Last comment
Programing
FalleN | 
Indonesia marcus4k 
can someone gave me tips to programing and i still learing Dev C++
2018-01-13 13:47
#1
 | 
Brazil coldzao 
yes go do aimbot
2018-01-13 13:48
#2
Jonti | 
Japan MrBean444 
take it bro imgur.com/a/N3VSy
2018-01-13 13:49
#6
FalleN | 
Indonesia marcus4k 
haha lockerboy
2018-01-13 13:53
#8
Jonti | 
Japan MrBean444 
<333 ez.
2018-01-13 13:54
Lockerboy VS TOP 5 TEAMS
2018-01-13 13:56
ez for lockerboy.
2018-01-13 13:56
#3
 | 
Ukraine beaztoff 
its HTML
2018-01-13 13:51
#4
 | 
Poland KyMon 
Learn english first.
2018-01-13 13:52
take it bitch. imgur.com/a/N3VSy
2018-01-13 13:54
#14
 | 
Poland KyMon 
Thank mr you <3
2018-01-13 13:58
#9
FalleN | 
Indonesia marcus4k 
ty arab
2018-01-13 13:54
Do the python course first, easier language to grasp concepts
2018-01-13 14:01
#7
 | 
Other flynttt 
always comment your code
2018-01-13 13:54
what do you mean ?
2018-01-13 13:54
i think he means enter comments to your code
2018-01-13 13:58
oh
2018-01-13 13:59
cout<<"what do you mean?"<<endl; //Polish guy doesnt know how to comment his code
2018-01-13 13:59
int main() cout << "LOCKERBOY TOP1" <<endl; system("PAUSE"); return 0;
2018-01-13 14:00
#23
 | 
Other flynttt 
u didnt comment your code bad student bad very bad
2018-01-13 14:01
#20
 | 
Other flynttt 
who uses cout now days printf() master race include <stdlib.h> or <stdio.h>
2018-01-13 14:01
#51
 | 
Russia insanijke 
printf in 2k18 EleGiggle
2018-01-13 14:43
#53
 | 
Other flynttt 
as i use out commands to read then in a serial or a display cout is just useless for me but programming in a console i do agree "printf in 2k18 EleGiggle"
2018-01-13 14:59
#18
 | 
Other flynttt 
use // to comment the code every step u take (like (if x>10){y=0;}) make a comment like //logic to make var y go to 0 after 10 loops.. will help you since as your code gets big u will find where change a mistake or a bug easier
2018-01-13 14:00
oh ty for the tips
2018-01-13 14:01
#24
 | 
Other flynttt 
i'm here to help you anything you need look my code in c++ for arduino to a lcd touchscreen display that i'm making rn
2018-01-13 14:03
#25
 | 
Other flynttt 
#include <EEPROM.h> #include <Wire.h> // inclui a biblioteca Wire #include <math.h> // inclui a biblioteca math #include <Adafruit_GFX.h> // Core graphics library #include <Adafruit_TFTLCD.h> // Hardware-specific library #include <TouchScreen.h> #define YP A1 // Y+ is on Analog1 #define XM A2 // X- is on Analog2 #define YM 7 // Y- is on Digital7 #define XP 6 // X+ is on Digital6 #define TS_MINX 150 #define TS_MINY 120 #define TS_MAXX 920 #define TS_MAXY 940 TouchScreen ts = TouchScreen(XP, YP, XM, YM, 100); //Definicao de cores #define BLACK 0x0000 #define GRAY 0xC618 #define DGRAY 0x4AAA #define BLUE 0x001F #define DBLUE 0x2311 #define RED 0xF800 #define GREEN 0x07E0 #define CYAN 0x07FF #define MAGENTA 0xF81F #define YELLOW 0xFFE0 #define WHITE 0xFFFF //PP_TFTLCD tft(LCD_CS, LCD_CD, LCD_WR, LCD_RD, LCD_RESET); //CS, CD, WR, RD, RESET Adafruit_TFTLCD tft(A3, A2, A1, A0, A4); #define MINPRESSURE 10 #define MAXPRESSURE 1000 // variaveis telas bool tl_principal = true; bool tl_config = false; bool verificar_bt_tl_principal = true; bool verificar_bt_tl_config = false; // variaveis caixas tela principal bool valor_bt_R1 = 0; bool valor_bt_R2 = 0; bool valor_bt_R3 = 0; bool valor_bt_R4 = 0; //variaveis tempo static unsigned long ult_tempo = 0; int tempo=0; int seg = 0; //variaveis auxiliares int auxmemo=1600; int auxseg=0; int xhor = 95; int auxxhor = 10; bool auxtela=0; bool auxR1=0; bool auxR2=0; bool auxR3=0; bool auxR4=0; char simbgc=247; bool auxbtmais1 = 0; bool auxbtmenos1 = 0; bool auxbtmais2 = 0; bool auxbtmenos2 = 0; int auxtemp1; int auxtemp2; int auxtemp3; int auxtemp4; //variavel com valor da temperatura lido dos thermistores int temperatura_1; int temperatura_2; int temperatura_3; int temperatura_4; //variaveis horimetro memoria int addr = 0;// declarar espaço na EEPROM para horas byte alto int addr2 = 1;// declarar espaço na EEPROM para horas byte baixo int addr3 = 2;// declarar espaço na EEPROM para minutos //variaveis temperatura memoria int addr4 = 1019;// declarar espaço na EEPROM para temp matriz int addr5 = 1018;// declarar espaço na EEPROM para temp taluneta //declara variaveis lidas na memoria EEPROM para temperatura int temp_ref_matriz = EEPROM.read(addr4); // temperatura em que desliga as resistencias da matriz int temp_ref_taluneta = EEPROM.read(addr5); // temperatura em que desliga a resistencia da taluneta //declara variaveis lidas na memoria EEPROM para horimetro int min = EEPROM.read(addr3); byte high = EEPROM.read(addr); byte low = EEPROM.read(addr2); //função para calculo de hora int hor = (high << 8) + low; //declara pinos dos triacs int triac_1 = 14; // declara pino do triac 1 int triac_2 = 15; // declara pino do triac 2 int triac_3 = 16; // declara pino do triac 3 int triac_4 = 17; // declara pino do triac 4 //declara pinos dos termistores int terms1 = A8; int terms2 = A9; int terms3 = A10; int terms4 = A11; void setup() { Serial.begin(9600); Serial.println("TFT Test");// teste inicialização da serial tft.reset(); delay(500); pinMode (triac_1, OUTPUT); //modo do pino triac 1 digitalWrite(triac_1, HIGH); // pinMode (triac_2, OUTPUT); //modo do pino triac 2 digitalWrite(triac_2, HIGH); pinMode (triac_3, OUTPUT); //modo do pino triac 3 digitalWrite(triac_3, HIGH); pinMode (triac_4, OUTPUT); //modo do pino triac 4 digitalWrite(triac_4, HIGH); high = EEPROM.read(addr); low = EEPROM.read(addr2); min = EEPROM.read(addr3); hor = (high << 8) + low; temp_ref_matriz = EEPROM.read(addr4); temp_ref_taluneta = EEPROM.read(addr5); //variavel com valor da temperatura lido dos thermistores temperatura_1 = (Thermister1(analogRead(terms1))); temperatura_2 = (Thermister1(analogRead(terms2))); temperatura_3 = (Thermister1(analogRead(terms3))); temperatura_4 = (Thermister1(analogRead(terms4))); auxtemp1 = temperatura_1; auxtemp2 = temperatura_2; auxtemp3 = temperatura_3; auxtemp4 = temperatura_4; tft.begin(0x9325);// inicializa tela touch tft.fillScreen(BLACK);// fundo preto tft.setRotation(1);//posição da tela } void loop() { TSPoint p = ts.getPoint(); pinMode(XM, OUTPUT); digitalWrite(XM, LOW); pinMode(YP, OUTPUT); digitalWrite(YP, HIGH); pinMode(YM, OUTPUT); digitalWrite(YM, LOW); pinMode(XP, OUTPUT); digitalWrite(XP, HIGH); //ativação de triacs ativa_triacs(); //teste da posição do touch if (p.z > MINPRESSURE && p.z < MAXPRESSURE) { p.x = tft.width() - (map(p.x, TS_MINX, TS_MAXX, tft.width(), 0)); p.y = tft.height() - (map(p.y, TS_MINY, TS_MAXY, tft.height(), 0)); /*if (p.y > 0) { Serial.print("py: "); Serial.print(p.y); Serial.print(" px: "); Serial.println(p.x); delay(150); }*/ } //inicio do loop especifico if(tl_principal == true) { auxtela=0; tela_principal(); tl_principal = false; verificar_bt_tl_principal = true; } if (verificar_bt_tl_principal == true) { verifica_botoes_tl_princ(); } if(tl_config == true) { auxtela=1; tela_config(); tl_config = false; verificar_bt_tl_config = true; } if (verificar_bt_tl_config == true) { verifica_botoes_tl_config(); } atualiza_hor(); if (auxseg > 5 && auxtela == 0){ temperatura_1 = (Thermister1(analogRead(terms1))); temperatura_2 = (Thermister1(analogRead(terms2))); temperatura_3 = (Thermister1(analogRead(terms3))); temperatura_4 = (Thermister1(analogRead(terms4))); verifica_bt_Rx(); atualiza_val_tl_principal(); auxseg=0; auxtemp1 = temperatura_1; auxtemp2 = temperatura_2; auxtemp3 = temperatura_3; auxtemp4 = temperatura_4; } } //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////************************************************//////////////////////////////////////////////// ////////////////////////////////////////////////****************** FUNÇÕES *********************//////////////////////////////////////////////// ////////////////////////////////////////////////************************************************//////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// void atualiza_val_tl_principal() { if(valor_bt_R1 == 0) { //muda cor de quadrado if (auxR1 != valor_bt_R1){ tft.fillRoundRect(61, 40, 89, 60, 5, RED); } auxR1=0; //apaga valor tft.setTextColor(RED); tft.setCursor(81, 59); if (auxtemp1 < 10) tft.print("0"); if (auxtemp1 < 100) tft.print("0"); tft.println(auxtemp1); //escreve novo valor tft.setTextColor(WHITE); tft.setCursor(81, 59); if (temperatura_1 < 10) tft.print("0"); if (temperatura_1 < 100) tft.print("0"); tft.println(temperatura_1); } if (valor_bt_R1 == 1) { if (auxR1 != valor_bt_R1){ tft.fillRoundRect(61, 40, 89, 60, 5, GREEN); } auxR1=1; tft.setTextColor(GREEN); tft.setCursor(81, 59); if (auxtemp1 < 10) tft.print("0"); if (auxtemp1 < 100) tft.print("0"); tft.println(auxtemp1); tft.setTextColor(WHITE); tft.setCursor(81, 59); if (temperatura_1 < 10) tft.print("0"); if (temperatura_1 < 100) tft.print("0"); tft.println(temperatura_1); } if(valor_bt_R2 == 0) { if (auxR2 != valor_bt_R2){ tft.fillRoundRect(221, 40, 89, 60, 5, RED); } auxR2=0; tft.setTextColor(RED); tft.setCursor(241, 59); if (auxtemp2 < 10) tft.print("0"); if (auxtemp2 < 100) tft.print("0"); tft.println(auxtemp2); tft.setTextColor(WHITE); tft.setCursor(241, 59); if (temperatura_2 < 10) tft.print("0"); if (temperatura_2 < 100) tft.print("0"); tft.println(temperatura_2); } if (valor_bt_R2 == 1) { if (auxR2 != valor_bt_R2){ tft.fillRoundRect(221, 40, 89, 60, 5, GREEN); } auxR2=1; tft.setTextColor(GREEN); tft.setCursor(241, 59); if (auxtemp2 < 10) tft.print("0"); if (auxtemp2 < 100) tft.print("0"); tft.println(auxtemp2); tft.setTextColor(WHITE); tft.setCursor(241, 59); if (temperatura_2 < 10) tft.print("0"); if (temperatura_2 < 100) tft.print("0"); tft.println(temperatura_2); } if(valor_bt_R3 == 0) { if (auxR3 != valor_bt_R3){ tft.fillRoundRect(61, 115, 89, 60, 5, RED); } auxR3=0; tft.setTextColor(RED); tft.setCursor(81, 134); if (auxtemp3 < 10) tft.print("0"); if (auxtemp3 < 100) tft.print("0"); tft.println(auxtemp3); tft.setTextColor(WHITE); tft.setCursor(81, 134); if (temperatura_3 < 10) tft.print("0"); if (temperatura_3 < 100) tft.print("0"); tft.println(temperatura_3); } if (valor_bt_R3 == 1) { if (auxR3 != valor_bt_R3){ tft.fillRoundRect(61, 115, 89, 60, 5, GREEN); } auxR3=1; tft.setTextColor(GREEN); tft.setCursor(81, 134); if (auxtemp3 < 10) tft.print("0"); if (auxtemp3 < 100) tft.print("0"); tft.println(auxtemp3); tft.setTextColor(WHITE); tft.setCursor(81, 134); if (temperatura_3 < 10) tft.print("0"); if (temperatura_3 < 100) tft.print("0"); tft.println(temperatura_3); } if(valor_bt_R4 == 0) { if (auxR4 != valor_bt_R4){ tft.fillRoundRect(221, 115, 89, 60, 5, RED); } auxR4=0; tft.setTextColor(RED); tft.setCursor(241, 134); if (auxtemp4 < 10) tft.print("0"); if (auxtemp4 < 100) tft.print("0"); tft.println(auxtemp4); tft.setTextColor(WHITE); tft.setCursor(241, 134); if (temperatura_4 < 10) tft.print("0"); if (temperatura_4 < 100) tft.print("0"); tft.println(temperatura_4); } if (valor_bt_R4 == 1) { if (auxR4 != valor_bt_R4){ tft.fillRoundRect(221, 115, 89, 60, 5, GREEN); } auxR4=1; tft.setTextColor(GREEN); tft.setCursor(241, 134); if (auxtemp4 < 10) tft.print("0"); if (auxtemp4 < 100) tft.print("0"); tft.println(auxtemp4); tft.setTextColor(WHITE); tft.setCursor(241, 134); if (temperatura_4 < 10) tft.print("0"); if (temperatura_4 < 100) tft.print("0"); tft.println(temperatura_4); } } void tela_principal() { // Inicio - Texto e botoes tft.setTextColor(WHITE); tft.setTextSize(3); tft.setCursor(37, 5); tft.println("AJL PNEUMATICA"); //caixa botão R1 tft.fillRoundRect(6, 36, 148, 68, 5, GRAY); tft.drawRoundRect(60, 39, 91, 62, 5, WHITE); tft.setCursor(17, 59); tft.println("R1"); //se botao tiver valor ligado/desligado if(valor_bt_R1 == 0) { tft.fillRoundRect(61, 40, 89, 60, 5, RED); tft.setCursor(81, 59); if (temperatura_1 < 10) tft.print("0"); if (temperatura_1 < 100) tft.print("0"); tft.println(temperatura_1); } if (valor_bt_R1 == 1) { tft.fillRoundRect(61, 40, 89, 60, 5, GREEN); tft.setCursor(81, 59); if (temperatura_1 < 10) tft.print("0"); if (temperatura_1 < 100) tft.print("0"); tft.println(temperatura_1); } //caixa botão R2 tft.fillRoundRect(166, 36, 148, 68, 5, GRAY); tft.drawRoundRect(220, 39, 91, 62, 5, WHITE); tft.setCursor(177, 59); tft.println("R2"); //se botao tiver valor ligado/desligado if(valor_bt_R2 == 0) { tft.fillRoundRect(221, 40, 89, 60, 5, RED); tft.setCursor(241, 59); if (temperatura_2 < 10) tft.print("0"); if (temperatura_2 < 100) tft.print("0"); tft.println(temperatura_2); } if (valor_bt_R2 == 1) { tft.fillRoundRect(221, 40, 89, 60, 5, GREEN); tft.setCursor(241, 59); if (temperatura_2 < 10) tft.print("0"); if (temperatura_2 < 100) tft.print("0"); tft.println(temperatura_2); } //caixa "botao" R3 tft.fillRoundRect(6, 111, 148, 68, 5, GRAY); tft.drawRoundRect(60, 114, 91, 62, 5, WHITE); tft.setCursor(17, 134); tft.println("R3"); //se botao tiver valor ligado/desligado if(valor_bt_R3 == 0) { tft.fillRoundRect(61, 115, 89, 60, 5, RED); tft.setCursor(81, 134); if (temperatura_3 < 10) tft.print("0"); if (temperatura_3 < 100) tft.print("0"); tft.println(temperatura_3); } if (valor_bt_R3 == 1) { tft.fillRoundRect(61, 115, 89, 60, 5, GREEN); tft.setCursor(81, 134); if (temperatura_3 < 10) tft.print("0"); if (temperatura_3 < 100) tft.print("0"); tft.println(temperatura_3); } //caixa "botao" R4 tft.fillRoundRect(166, 111, 148, 68, 5, GRAY); tft.drawRoundRect(220, 114, 91, 62, 5, WHITE); tft.setCursor(177, 134); tft.println("R4"); //se botao tiver valor ligado/desligado if(valor_bt_R4 == 0) { tft.fillRoundRect(221, 115, 89, 60, 5, RED); tft.setCursor(241, 134); if (temperatura_4 < 10) tft.print("0"); if (temperatura_4 < 100) tft.print("0"); tft.println(temperatura_4); } if (valor_bt_R4 == 1) { tft.fillRoundRect(221, 115, 89, 60, 5, GREEN); tft.setCursor(241, 134); if (temperatura_4 < 10) tft.print("0"); if (temperatura_4 < 100) tft.print("0"); tft.println(temperatura_4); } //caixa botao CONFIG. tft.drawRoundRect(35, 187, 90, 45, 11, WHITE); tft.fillRoundRect(36, 188, 89, 44, 10, DGRAY); tft.fillRoundRect(36, 188, 84, 38, 10, GRAY); tft.setTextColor(WHITE); tft.setCursor(46, 198); tft.println("CONF"); //caixa botao HOR. tft.drawRoundRect(195, 187, 90, 45, 11, WHITE); tft.fillRoundRect(196, 188, 89, 44, 10, DGRAY); tft.fillRoundRect(196, 188, 84, 38, 10, GRAY); tft.setCursor(215, 198); tft.println("HOR"); } void verifica_botoes_tl_princ() { //teste da posição do touch //restaura tela apos touch TSPoint p = ts.getPoint(); pinMode(XM, OUTPUT); digitalWrite(XM, LOW); pinMode(YP, OUTPUT); digitalWrite(YP, HIGH); pinMode(YM, OUTPUT); digitalWrite(YM, LOW); pinMode(XP, OUTPUT); digitalWrite(XP, HIGH); if (p.z > MINPRESSURE && p.z < MAXPRESSURE) { p.x = tft.width() - (map(p.x, TS_MINX, TS_MAXX, tft.width(), 0)); p.y = tft.height() - (map(p.y, TS_MINY, TS_MAXY, tft.height(), 0)); /*if (p.y > 0) { Serial.print("py: "); Serial.print(p.y); Serial.print(" px: "); Serial.println(p.x); delay(150); }*/ } //botao config if (p.x > 205 & p.x < 295 & p.y > 175 & p.y < 245)//coordenadas da area do botao { tft.fillRoundRect(36, 188, 89, 44, 10, DGRAY); tft.drawRoundRect(35, 187, 90, 45, 11, WHITE); tft.setTextColor(GREEN); tft.setCursor(46, 198); tft.println("CONF"); verificar_bt_tl_principal = false; tl_config = true; } //botao HOR if (p.x > 50 & p.x < 135 & p.y > 175 & p.y < 245)//coordenadas da area do botao { tft.fillRoundRect(196, 188, 89, 44, 10, DGRAY); tft.drawRoundRect(195, 187, 90, 45, 11, WHITE); tft.setCursor(215, 198); tft.setTextColor(GREEN); tft.println("HOR"); verificar_bt_tl_principal = false; tl_principal = false; tela_hor(); delay(5000); tft.fillScreen(BLACK); tl_principal = true; } } void tela_config() { tl_config = true; verificar_bt_tl_principal = false; tft.fillScreen(BLACK);// fundo preto tft.setRotation(1);//posição da tela tft.setTextColor(WHITE); tft.setTextSize(3); tft.setCursor(60, 15); tft.println("CONFIGURACAO"); temp_ref_matriz = EEPROM.read(addr4); temp_ref_taluneta = EEPROM.read(addr5); //caixa matriz tft.drawRoundRect(10, 50, 220, 90, 5, WHITE); tft.drawRoundRect(10, 50, 220, 40, 5, WHITE); tft.drawRoundRect(10, 90, 50, 50, 5, WHITE); tft.drawRoundRect(180, 90, 50, 50, 5, WHITE); tft.setTextColor(WHITE); tft.setTextSize(3); tft.setCursor(68, 60); tft.println("MATRIZ"); tft.setCursor(27, 105); tft.println("-"); tft.setCursor(76, 105); tft.print(temp_ref_matriz); tft.print(simbgc); tft.print("C"); tft.setCursor(198, 105); tft.println("+"); //caixa taluneta tft.drawRoundRect(10, 150, 220, 90, 5, WHITE); tft.drawRoundRect(10, 150, 220, 40, 5, WHITE); tft.drawRoundRect(10, 190, 50, 50, 5, WHITE); tft.drawRoundRect(180, 190, 50, 50, 5, WHITE); tft.drawRoundRect(255, 190, 50, 50, 5, WHITE); tft.fillRoundRect(256, 191, 49, 49, 5, DGRAY); tft.fillRoundRect(256, 191, 46, 46, 5, GRAY); tft.setCursor(263, 205); tft.println("OK"); tft.setCursor(50, 160); tft.println("TALUNETA"); tft.setCursor(27, 205); tft.println("-"); if (temp_ref_taluneta < 100){ tft.setCursor(86, 205); } else{ tft.setCursor(76, 205); } tft.print(temp_ref_taluneta); tft.print(simbgc); tft.print("C"); tft.setCursor(198, 205); tft.println("+"); } void verifica_botoes_tl_config() { //teste da posição do touch //restaura tela apos touch TSPoint p = ts.getPoint(); pinMode(XM, OUTPUT); digitalWrite(XM, LOW); pinMode(YP, OUTPUT); digitalWrite(YP, HIGH); pinMode(YM, OUTPUT); digitalWrite(YM, LOW); pinMode(XP, OUTPUT); digitalWrite(XP, HIGH); if (p.z > MINPRESSURE && p.z < MAXPRESSURE) { p.x = tft.width() - (map(p.x, TS_MINX, TS_MAXX, tft.width(), 0)); p.y = tft.height() - (map(p.y, TS_MINY, TS_MAXY, tft.height(), 0)); /*if (p.y > 0) { Serial.print("py: "); Serial.print(p.y); Serial.print(" px: "); Serial.println(p.x); delay(150); }*/ } //botao ok if (p.x > 35 & p.x < 85 & p.y > 180 & p.y < 225)//coordenadas da area do botao { EEPROM.write(addr4,int(temp_ref_matriz)); EEPROM.write(addr5,int(temp_ref_taluneta)); tft.fillRoundRect(256, 191, 49, 49, 5, DGRAY); tft.drawRoundRect(255, 190, 50, 50, 5, WHITE); tft.setTextColor(GREEN); tft.setCursor(263, 205); tft.println("OK"); verificar_bt_tl_config = false; tl_principal = true; tft.fillScreen(BLACK);// fundo preto } //botao -(1) if (p.x > 270 & p.x < 325 & p.y > 95 & p.y < 140)//coordenadas da area do botao { //verififica valor minimo if (temp_ref_matriz <= 100) { tft.fillRoundRect(11, 91, 48, 48, 5, RED); tft.setTextColor(WHITE); tft.setCursor(27, 105); tft.println("-"); auxbtmenos1 = 1; } //verifica se valor maximo foi alcancado if (auxbtmais1 == 1){ auxbtmais1 = 0; tft.fillRoundRect(181, 91, 48, 48, 5, BLACK); tft.setTextColor(WHITE); tft.setCursor(198, 105); tft.println("+"); } //apaga valor tft.setTextColor(BLACK); tft.setCursor(76, 105); tft.print(temp_ref_matriz); tft.print(simbgc); tft.print("C"); //subtrai 1 e escreve novamentente if (auxbtmenos1 == 0){ temp_ref_matriz--; } tft.setTextColor(WHITE); tft.setCursor(76, 105); tft.print(temp_ref_matriz); tft.print(simbgc); tft.print("C"); delay(50); } //botao +(1) if (p.x > 105 & p.x < 160 & p.y > 95 & p.y < 140)//coordenadas da area do botao { if (temp_ref_matriz >= 200) { tft.fillRoundRect(181, 91, 48, 48, 5, RED); tft.setTextColor(WHITE); tft.setCursor(198, 105); tft.println("+"); auxbtmais1 = 1; } if (auxbtmenos1 == 1){ auxbtmenos1 = 0; tft.fillRoundRect(11, 91, 48, 48, 5, BLACK); tft.setTextColor(WHITE); tft.setCursor(27, 105); tft.println("-"); } //apaga valor tft.setTextColor(BLACK); tft.setCursor(76, 105); tft.print(temp_ref_matriz); tft.print(simbgc); tft.print("C"); //soma 1 e escreve novamentente if (auxbtmais1 ==0){ temp_ref_matriz++; } tft.setTextColor(WHITE); tft.setCursor(76, 105); tft.print(temp_ref_matriz); tft.print(simbgc); tft.print("C"); delay(50); } //botao -(2) if (p.x > 280 & p.x < 320 & p.y > 180 & p.y < 220)//coordenadas da area do botao { if (temp_ref_taluneta <= 80) { tft.fillRoundRect(11, 191, 48, 48, 5, RED); tft.setTextColor(WHITE); tft.setCursor(27, 205); tft.println("-"); auxbtmenos2 = 1; } if (auxbtmais2 == 1){ auxbtmais2 = 0; tft.fillRoundRect(181, 191, 48, 48, 5, BLACK); tft.setTextColor(WHITE); tft.setCursor(198, 205); tft.println("+"); } //apaga valor tft.setTextColor(BLACK); if (temp_ref_taluneta < 100){ tft.setCursor(86, 205); } else{ tft.setCursor(76, 205); } tft.print(temp_ref_taluneta); tft.print(simbgc); tft.print("C"); //subtrai 1 e escreve novamentente if (auxbtmenos2 == 0 ){ temp_ref_taluneta--; } tft.setTextColor(WHITE); if (temp_ref_taluneta < 100){ tft.setCursor(86, 205); } else{ tft.setCursor(76, 205); } tft.print(temp_ref_taluneta); tft.print(simbgc); tft.print("C"); delay(50); } //botao +(2) if (p.x > 100 & p.x < 140 & p.y > 180 & p.y < 220)//coordenadas da area do botao { if (temp_ref_taluneta >= 120) { tft.fillRoundRect(181, 191, 48, 48, 5, RED); tft.setTextColor(WHITE); tft.setCursor(198, 205); tft.println("+"); auxbtmais2 = 1; } if (auxbtmenos2 == 1){ auxbtmenos2 = 0; tft.fillRoundRect(11, 191, 48, 48, 5, BLACK); tft.setTextColor(WHITE); tft.setCursor(27, 205); tft.println("-"); } //apaga valor tft.setTextColor(BLACK); if (temp_ref_taluneta < 100){ tft.setCursor(86, 205); } else{ tft.setCursor(76, 205); } tft.print(temp_ref_taluneta); tft.print(simbgc); tft.print("C"); //soma 1 e escreve novamentente if (auxbtmais2 == 0){ temp_ref_taluneta++; } tft.setTextColor(WHITE); if (temp_ref_taluneta < 100){ tft.setCursor(86, 205); } else{ tft.setCursor(76, 205); } tft.print(temp_ref_taluneta); tft.print(simbgc); tft.print("C"); delay(50); } } void tela_hor() { tft.fillScreen(BLACK);// fundo preto //caixa mensagem tft.drawRoundRect(10, 30, 310, 190, 5, BLUE); tft.fillRoundRect(11, 31, 308, 188, 5, DBLUE); tft.setTextSize(3); tft.setTextColor(WHITE); tft.setCursor(81, 60); tft.print("HORIMETRO"); if (hor >= auxxhor){ xhor=xhor-8; auxxhor=auxxhor*10; } tft.setCursor(xhor, 120); tft.print(hor); //hora tft.print(":"); if (min < 10) tft.print("0"); tft.print(min); //minutos tft.print(":"); if (seg < 10) tft.print("0"); tft.print(seg); //segundos } //variaveis da função termometro 1 double Thermister1(int RawADC1) { // pega os dados lido do Thermistor quando chamada a função e armazena em RawADC, este é um valor relacionado a queda de tensão double Temp1; // variável usada no cálculo Temp1 = log(((10240000/RawADC1) - 10000)); // relaciona o valor de queda de tensão lido com resistência 10000 é o valor da resistência do Thermistor se for necessário usar um Thermistor diferente ajustar o valor corretamente Temp1 = 1 / (0.001129148 + (0.000234125 * Temp1) + (0.0000000876741 * Temp1 * Temp1 * Temp1)); // formula para dar a temperatura em Kelvin Temp1 = Temp1 - 273.15; // converte de Kelvin para Celcius return Temp1; // retorna o valor da temperatura calculada } //variaveis da função termometro 2 double Thermister2(int RawADC2) { double Temp2; Temp2 = log(((10240000/RawADC2) - 10000)); Temp2 = 1 / (0.001129148 + (0.000234125 * Temp2) + (0.0000000876741 * Temp2 * Temp2 * Temp2)); Temp2 = Temp2 - 273.15; return Temp2; } //variaveis da função termometro 3 double Thermister3(int RawADC3) { double Temp3; Temp3 = log(((10240000/RawADC3) - 10000)); Temp3 = 1 / (0.001129148 + (0.000234125 * Temp3) + (0.0000000876741 * Temp3 * Temp3 * Temp3)); Temp3 = Temp3 - 273.15; return Temp3; } //variaveis da função termometro 4 double Thermister4(int RawADC4) { double Temp4; Temp4 = log(((10240000/RawADC4) - 10000)); Temp4 = 1 / (0.001129148 + (0.000234125 * Temp4) + (0.0000000876741 * Temp4 * Temp4 * Temp4)); Temp4 = Temp4 - 273.15; return Temp4; } //função para atualizar horimetro void atualiza_hor() { tempo = millis(); if(tempo - ult_tempo >= 1000) { ult_tempo = tempo; seg++; auxseg++; } if(seg>=60) { seg = 0; min++; //EEPROM.write(addr3,int(min)); } if(min>=60) { seg = 0; min = 0; hor++; EEPROM.write(addr,highByte(hor)); EEPROM.write(addr2,lowByte(hor)); EEPROM.write(addr3,int(min)); } if (hor == auxmemo){ addr3++; auxmemo = auxmemo+1600; EEPROM.write(addr3,int(min)); } } void ativa_triacs() { if(temperatura_1<temp_ref_matriz-5){ digitalWrite(triac_1, LOW); } else if(temperatura_1>=temp_ref_matriz){ digitalWrite(triac_1,HIGH); } if(temperatura_2<temp_ref_matriz-5){ digitalWrite(triac_2, LOW); } else if(temperatura_2>=temp_ref_matriz){ digitalWrite(triac_2,HIGH); } if(temperatura_3<temp_ref_matriz-5){ digitalWrite(triac_3, LOW); } else if(temperatura_3>=temp_ref_matriz){ digitalWrite(triac_3,HIGH); } if(temperatura_4<temp_ref_taluneta-5){ digitalWrite(triac_4, LOW); } else if(temperatura_4>=temp_ref_matriz){ digitalWrite(triac_4,HIGH); } } void verifica_bt_Rx() { if (temperatura_1<(temp_ref_matriz+5) && temperatura_1>(temp_ref_matriz-5)){ valor_bt_R1=1; } else{ valor_bt_R1=0; } if (temperatura_2<(temp_ref_matriz+5) && temperatura_2>(temp_ref_matriz-5)){ valor_bt_R2=1; } else{ valor_bt_R2=0; } if (temperatura_3<(temp_ref_matriz+5) && temperatura_3>(temp_ref_matriz-5)){ valor_bt_R3=1; } else{ valor_bt_R3=0; } if (temperatura_4<(temp_ref_taluneta+5) && temperatura_4>(temp_ref_taluneta-5)){ valor_bt_R4=1; } else{ valor_bt_R4=0; } }
2018-01-13 14:03
so long
2018-01-13 14:04
#27
 | 
Other flynttt 
its avarage to industrial applications
2018-01-13 14:06
im stil stuck at makin calculator
2018-01-13 14:07
#29
 | 
Other flynttt 
just google it u will find a lot of exemples ready to use read the code and the comments then customize the code to make it looks even better after understand everything start one from sketch trying to do bye yoourself without external help when u done u will never stuck at makin a calculator again good studies my friend
2018-01-13 14:09
int main() { double a; double b,c; a = 0; b = 0; cout << "Enter A: "; cin >> a; cout << "Enter B: "; cin >> b; c = a * b; cout << "Value Of Variables c is " << c << endl; system ("pause"); return 0; // ini perkalian }
2018-01-13 14:11
#32
 | 
Other flynttt 
this is a good enought start remember that u cant be lazy when programming code will be extensive and will be a pain in the ass to compile cause most of the time u will get a error just focus, put a good music, and dont stop until u have it done (separete what u will do in steps)
2018-01-13 14:15
i remeber when i making the calculator im so confusing asf and i wasted alot off my hours to make a calculator
2018-01-13 14:19
#34
 | 
Other flynttt 
never start something from sketch if u dont already know every step u will have to make follow #29 to optimize your time learning
2018-01-13 14:22
#29 ?
2018-01-13 14:23
#37
 | 
Other flynttt 
"just google it u will find a lot of exemples ready to use read the code and the comments then customize the code to make it looks even better after understand everything start one from sketch trying to do bye yoourself without external help when u done u will never stuck at makin a calculator again good studies my friend" u can find anything about programing now days on the internet start studing what is already done
2018-01-13 14:24
oh
2018-01-13 14:25
#39
 | 
Other flynttt 
sometimes u will stuck to find something that will help u but belive me u will find exactly what u need if u make enought efort
2018-01-13 14:25
thank you man i will take all off your tips
2018-01-13 14:26
#41
 | 
Other flynttt 
np everytime u need =)
2018-01-13 14:27
zzZZzzzZZzzzzZZZzZZZzZzzzzZZzZzzzZZzZzZZZzzzzzz
2018-01-13 14:24
Actually your comment practice is quite bad. Methods should have a block comment explaining the process and outcome. Rarely functions maybe commented. Variables should never be commented as they should be self-explanatory. Get yourself a copy of clean code - Robert C. Martin, its a great book and will help you a lot.
2018-01-13 15:30
#59
 | 
Other flynttt 
thx for advice.. yes i'm finishing my code today and will do a hard review adding every comment that it need will def check it since u not the first person recommending me this book have a nice weekend my friend <3
2018-01-13 16:29
Why C++? Learn Swift!
2018-01-13 14:12
#42
 | 
Russia k3ron 
Who needs programming language from Apple?
2018-01-13 14:31
Me?
2018-01-13 14:32
#44
 | 
Russia k3ron 
It's useless, I guess.
2018-01-13 14:34
How is it useless if you develop apps with it for iOS and Mac which are used by billions?
2018-01-13 14:35
#48
 | 
Russia k3ron 
I won't say "for billions". A chance to get your app popular is like 0.01%, to be honest. But if you like it - learn it, I am not aganist that.
2018-01-13 14:37
"A chance to get your app popular is like 0.01%" It is not THAT difficult if you make a generally good quality app and know some basic marketing strats. Talking from experience ;) Besides, if you fail at your own thing you can always go work for a company to get more experience and $
2018-01-13 14:40
#50
 | 
Russia k3ron 
That's true, I must say. Good luck in the future with it :)
2018-01-13 14:41
Thanks u too :))))
2018-01-13 15:02
#46
 | 
Germany Merkelistan 
1. Use English only while programming 2. Ignore C++, learn civilized language. Python is good for a beginner.
2018-01-13 14:36
+1
2018-01-13 14:36
#52
 | 
Brazil iansixx 
C++ is definitely the best to start, i would suggest even lower, that is C, and the reasons are: - actually know what's going on under the hood (sorting, selecting, data structures) - learn to implement your solution. - understand how your code interacts with your computer. now, i don't suggest you stay with c or c++ but use to actually understand programming. programming is routine and to program is to practice, if you are lazy you will never be able to actually code something interesting. you have to actually think about what you want to accomplish with your code, step by step, actually think and write it down the pseudocode. never ever start writing code without thinking about the step by step of your problem. after that you can use your criteria to choose a language to work with.
2018-01-13 14:49
#55
k0nfig | 
Netherlands miles- 
- Learn Object Oriented Programming (SOLID Principles) - Read theories about Data Structures & Algorhitms (o-notation). - Learn Design Patterns and how to use them - Learn what memory management and garbage collection is - Learn about async/parallell processing - Think of a project and make it - Think about how you can improve the project (performance, less code, security, decoupling objects even more) - Don't think a programming language is superior, syntax is easy to learn. Designing isn't. - Think critical when reading StackOverflow, a lot of garbage is circulating because people are karma hungry there. - Research subjects that you like and what the scope of those subjects are. (like create an app, you also need to design an API. Research those kind of subjects) - Define region blocks and comments to ease maintenance and investigation of code blocks - Learn how to work with GIt / version control Make sure you have fun and not be afraid of the theoretical side of it when you start to actually progress.
2018-01-13 15:10
#56
 | 
Other flynttt 
gooood
2018-01-13 15:13
#58
 | 
Brazil inc_eax 
+1
2018-01-13 15:33
Login or register to add your comment to the discussion.