Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int Temp = 0;
- const int MaxTemp = 1200;
- const char eps[9] = "=FFFFA85";
- char forsend[16] = "";
- void setup() {
- Serial.begin(9600, SERIAL_8N2);
- }
- void loop() {
- char StrTemp[7] = "";
- if (Temp > MaxTemp) {
- Temp = 0;
- }
- sprintf(StrTemp, "%4d\r\n", Temp);
- strcat(forsend, eps);
- strcat(forsend, StrTemp);
- Serial.print(forsend);
- Temp++;
- delay(1000);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement