Skip to content

Instantly share code, notes, and snippets.

Awali dengan basmalah..

Muhammad Ichsanul Fadhil ichsanputr

Awali dengan basmalah..
View GitHub Profile
ichsanputr / main.go
Created October 6, 2021 01:46
Get current ip address for your PC
View main.go
* get current ip address
* as a replacment for command ifconfig (linux ubuntu)
package main
import (
ichsanputr / insertjsontoelasticseacrh.js
Created November 15, 2021 11:05
Node Js Script for add JSON to Elasticsearch database
View insertjsontoelasticseacrh.js
var {Client} =require('@elastic/elasticsearch');
var http = require('http');
var movies = require("./movies1.json")
var actors = require("./actors.json")
// connect to elastic
const client = new Client({
node: 'uri to post elasticseacrh',
auth: {
username: '1200',
ichsanputr / main.go
Created November 21, 2021 09:40
simple web server using gin
View main.go
package main
import ""
func main() {
r := gin.New()
r.GET("/", func(c *gin.Context) {
c.JSON(200, gin.H{
"nama": "ichsan",
View helloworld.go
package helloworld
import "fmt"
func Print(){
fmt.Println("Hello World")
ichsanputr / halo.go
Created February 2, 2022 01:46
View halo.go
#include "RTClib.h"
#include <LiquidCrystal_I2C.h>
RTC_DS1307 rtc;
char daysOfTheWeek[7][12] = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"};
LiquidCrystal_I2C lcd(0x27,20,4);
void setup () {
ichsanputr / rtctolcd.c
Created March 9, 2022 02:31
Display current date, hour, second with RTC and LCD Arduino
View rtctolcd.c
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
#include <RTClib.h>
RTC_DS1307 rtc;
LiquidCrystal_I2C lcd(0x27,20,4);
void setup()
ichsanputr / mkdir.asm
Last active December 8, 2022 09:26
Create a directory using mkdir syscall with x64 assembly linux
View mkdir.asm
;compile and running using command below
;nasm -f elf64 -g -F dwarf -o a.o a.asm
;ld -o a a.o
global _start
section .data
pathDir db "dirTest",0
ichsanputr / fdfdf
Created January 24, 2023 13:56
View fdfdf
iframe {
top:0; left:0;
filter:alpha(opacity=10); /* in a real attack this would be opacity=0 */
View chart.json
"data": [
"ketua": [
"id": 1,
"name": "Joko",
"category": "Ketua",
"summary": 1341
View motor_esp32.ino
#include <WiFi.h>
#include <WebServer.h>
#define ENA 13
#define ENB 12
#define IN_1 32
#define IN_2 33
#define IN_3 34
#define IN_4 35