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
import 'package:path/path.dart'; | |
import 'dart:io'; | |
import 'dart:async'; | |
import 'package:dio/dio.dart'; | |
/** | |
* accepts two parameters,the endpoint and the file | |
* returns Response from server | |
*/ | |
Future<Response> sendFile(String url, File file) async { |
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 <WiFi.h> | |
#include "time.h" | |
const char* ntpServer1 = "time.google.com"; | |
const char* time_zone = "IST-5:30"; | |
const uint8_t CLK_CYCLE_DELAY = 100;// us | |
const uint8_t CLK_PIN = 22; | |
const uint8_t DIO_PIN = 19; | |
const uint8_t NUM_DIGITS = 4; |
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 <WiFi.h> | |
#include <WiFiClient.h> | |
#include <WebServer.h> | |
const uint8_t CLK_CYCLE_DELAY = 100;// us | |
const uint8_t CLK_PIN = 22; | |
const uint8_t DIO_PIN = 19; | |
const uint8_t NUM_DIGITS = 4; | |
const char* ssid = "****"; | |
const char* password = "****"; |
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
const mongoose = require('mongoose') | |
const util = require('util') | |
const stream = require('stream') | |
const pipeline = util.promisify(stream.pipeline) | |
const stringify = require('csv-stringify') | |
const fs = require('fs') | |
const fsp = require('fs').promises | |
let schema = mongoose.Schema({ |
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 id=99; | |
#include <SoftwareSerial.h> | |
SoftwareSerial sw(2, 3); // RX, TX | |
void setup() { | |
Serial.begin(115200); | |
Serial.println("Interfacfing arduino with nodemcu"); | |
sw.begin(115200); | |
} |
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
import 'package:path/path.dart'; | |
import 'dart:io'; | |
import 'dart:async'; | |
import 'package:dio/dio.dart'; | |
/** | |
* accepts three parameters, the endpoint, formdata (except fiels),files (key,File) | |
* returns Response from server | |
*/ | |
Future<Response> sendForm( |
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
import 'package:flutter/material.dart'; | |
import 'package:path/path.dart'; | |
import 'package:image_picker/image_picker.dart'; | |
import 'dart:io'; | |
import 'dart:async'; | |
import 'package:dio/dio.dart'; | |
/** | |
* accepts three parameters, the endpoint, formdata (except fiels),files (key,File) | |
* returns Response from server |
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 <stdio.h> | |
#include "freertos/FreeRTOS.h" | |
#include "freertos/task.h" | |
#include "freertos/queue.h" | |
QueueHandle_t q=NULL; | |
void consumer_task(void *pvParameter) | |
{ | |
unsigned long counter; |
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 <WiFi.h> | |
#include <PubSubClient.h> | |
// Update these with values suitable for your network. | |
const char* ssid = "SSID"; | |
const char* password = "password"; | |
const char* mqtt_server = "broker.mqtt-dashboard.com"; | |
#define mqtt_port 1883 | |
#define MQTT_USER "mqtt username" |
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 "TFT_eSPI.h" | |
#include "rpcWiFi.h" | |
#include "WiFiClientSecure.h" | |
#include "HTTPClient.h" | |
#include "ArduinoJson.h" | |
DynamicJsonDocument jsonResponse(1024); | |
const char *ssid = "m1Danger"; | |
const char *password = "abivarsh@2016"; | |
const String checkUrl = "https://api.freshping.io/v1/public-check-statuses/524828/"; |
NewerOlder