This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This program is to communicate with bluetooth | |
and android mobile phone | |
by Dr. Aung Win Htut | |
*/ | |
#include <SoftwareSerial.h> | |
SoftwareSerial mySerial(9, 10); // RX, TX | |
int in1=2; //Arduino pin 2 connected to L298 pin in1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream> | |
using namespace std; | |
class BST | |
{ | |
struct node | |
{ | |
int data; | |
node* left; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* C++ program to find Inorder successor in a BST */ | |
#include<iostream> | |
using namespace std; | |
struct Node { | |
int data; | |
struct Node *left; | |
struct Node *right; | |
}; | |
//Function to find some data in the tree |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <LiquidCrystal.h> | |
LiquidCrystal lcd(12, 11, 10, 9, 8, 7); | |
#include "HX711.h" | |
#define calibration_factor -669.10 | |
#define DOUT 3 | |
#define CLK 2 | |
HX711 scale(DOUT, CLK); | |
char * floatToString(char * outstr, float value, int places); | |
void setup() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<head> <meta http-equiv="refresh" content="30" /> </head> | |
Auto Refresh Webpage with PHP, HTML and JavaScript | |
I’m developing server checking & monitoring webpage. I would left the page open all the time on my browser. So it will be good to that page auto refresh every certain amount of time so I don’t have to keep hitting F5 manually to refresh. | |
There are a few option that I have, I can do it either by using PHP Code, HTML Meta tag or JavaScript. | |
For example I want to refresh the webpage every 10 seconds. The are the code. | |
PHP Code | |
*********************************** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "Time.h" | |
#include<iostream> | |
#include<string> | |
void Time::Clear() { | |
hour = 0; | |
minute = 0; | |
} | |
Time::Time() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream> | |
#include<conio.h> | |
using namespace std; | |
int funArea(); | |
int main() | |
{ | |
float gold_weight_in_kyat, kyat, pae, yway, total_gold_price,one_kyat_price; | |
cout<<"pls enter one kyat price "; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Program 2018121002GreenHackersArduinoBaydin.ino | |
//Programmer Dr. Aung Win Htut | |
//Date: 20181210:1538 | |
int iAns = 0; | |
void setup() { | |
Serial.begin(9600); | |
Serial.println("Green Hackers Arduino Baydin"); | |
Serial.println("****************************"); | |
Serial.println("Please Type Your Name in Serial Monitor!"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Displays text sent over the serial port (e.g. from the Serial Monitor) on | |
* an attached LCD. | |
*/ | |
//This program is originally an example program for LiquidCrystal_I2C.h | |
//This program is modified by Dr. Aung Win Htut | |
//This program read from serial and print on lcd | |
//we modified it to move next line if char reach col 16 | |
#include <Wire.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/////////////////// | |
int getID() { | |
// Getting ready for Reading PICCs | |
if ( ! mfrc522.PICC_IsNewCardPresent()) { //If a new PICC placed to RFID reader continue | |
return 0; | |
} | |
if ( ! mfrc522.PICC_ReadCardSerial()) { //Since a PICC placed get Serial and continue | |
return 0; | |
} | |
// There are Mifare PICCs which have 4 byte or 7 byte UID care if you use 7 byte PICC |
NewerOlder