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
void setup() { | |
Serial.begin(9600); | |
} | |
void loop() { | |
delay(1000); | |
Serial.println("Halo ESP8266, Assalamualaikum :)"); | |
} |
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
data = load('ex1data1.txt'); | |
X = data(:, 1); y = data(:, 2); | |
m = length(y); | |
figure; | |
plot(x, y, 'rx', 'MarkerSize', 10); | |
ylabel('Harga hunian'); | |
xlabel('luas tanah'); | |
X = [ones(m, 1), data(:,1)]; |
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
// the setup routine runs once when you press reset: | |
void setup() { | |
// initialize the digital pin as an output. | |
pinMode(0, OUTPUT); //LED on Model B | |
pinMode(1, OUTPUT); //LED on Model A or Pro | |
} | |
// the loop routine runs over and over again forever: | |
void loop() { |
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 "stm32f10x_gpio.h" | |
#include "stm32f10x_rcc.h" | |
GPIO_InitTypeDef GPIO_InitStructure; | |
void wait_ms(int t){ | |
volatile int i; | |
for (i=0;i<t*2000;i++); | |
} | |
void setup_gpio(){ | |
RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOC, ENABLE); |
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
String a; | |
const int ledPin = 13; // the number of the LED pin | |
int ledState = LOW; // ledState used to set the LED | |
void setup() { | |
Serial.begin(9600); | |
pinMode(ledPin, OUTPUT); | |
} |
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
package net.ruangtedy.bey.client; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.io.PrintWriter; | |
import java.net.Socket; | |
import java.net.UnknownHostException; | |
public class SimpleClient { |
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
package net.ruangtedy.java.servlet; | |
import java.io.IOException; | |
import java.io.PrintWriter; | |
import javax.servlet.RequestDispatcher; | |
import javax.servlet.ServletConfig; | |
import javax.servlet.ServletException; | |
import javax.servlet.annotation.WebServlet; | |
import javax.servlet.http.HttpServlet; |
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 <TimerOne.h> | |
#include <Wire.h> | |
#include <MultiFuncShield.h> | |
void setup() { | |
// put your setup code here, to run once: | |
Timer1.initialize(); | |
MFS.initialize(&Timer1); // initialize multi-function shield library |
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
/* | |
ESP8266 Blink by Simon Peter | |
Blink the blue LED on the ESP-01 module | |
This example code is in the public domain | |
The blue LED on the ESP-01 module is connected to GPIO1 | |
(which is also the TXD pin; so we cannot use Serial.print() at the same time) | |
Note that this sketch uses LED_BUILTIN to find the pin with the internal LED | |
*/ |
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 <ESP8266WiFi.h> | |
const char* ssid = "YOUR_SSID";//type your ssid | |
const char* password = "YOUR_PASSWORD";//type your password | |
int ledPin = 2; // GPIO2 of ESP8266 | |
WiFiServer server(80);//Service Port | |
void setup() { | |
Serial.begin(115200); |