Skip to content

Instantly share code, notes, and snippets.

View Xplorer001's full-sized avatar

Sandeep Patil Xplorer001

  • ExploreEmbedded
  • Bangalore, India
View GitHub Profile
#include "ST7565.h"
// the LCD backlight is connected up to a pin so you can turn it on & off
#define BACKLIGHT_LED 10
// pin 29 - Serial data out (SID)
// pin 28 - Serial clock out (SCLK)
// pin 27 - Data/Command select (RS or A0)
// pin 26 - LCD reset (RST)
// pin 25 - LCD chip select (CS)
ST7565 glcd(29, 28, 27, 26, 25);
#include <TinyGPS++.h>
//We are using HW serial port on Explore M3 hence commented out
//#include <SoftwareSerial.h>
/*
This sample sketch demonstrates the normal use of a TinyGPS++ (TinyGPSPlus) object.
It requires the use of SoftwareSerial, and assumes that you have a
9600-baud serial GPS device hooked up on pins 4(rx) and 3(tx).
Explore M3 note: The soft serial object ss is replaced with Serial0
#include <SPI.h>
#include <MFRC522.h>
#define RST_PIN 5 // Configurable, see typical pin layout above
#define SS_PIN 13 // Configurable, see typical pin layout above
MFRC522 mfrc522(SS_PIN, RST_PIN); // Create MFRC522 instance
void setup() {
// delay(5000);
/*
ADXL3xx
Reference:
http://www.arduino.cc/en/Tutorial/ADXL3xx
The circuit:
analog 0: accelerometer self test
analog 1: z-axis
Terminal log file
Date: 7/9/2016 - 12:16:48 PM
-----------------------------------------------
AT
OK
AT+CFUN=1
OK
/*
Sketch: GPRS HTTP Test
*/
#include <gprs.h>
#include <SoftwareSerial.h>
char http_cmd[] = "GET exploreembedded.com/wiki/images/1/15/Hello.txt HTTP/1.0\r\n\r\n";
char buffer[512];
/*******Interrupt-based Rotary Encoder Sketch*******
by Simon Merrett, based on insight from Oleg Mazurov, Nick Gammon, rt, Steve Spence
modified at EE to include the select switch
Tutorial at:
http://exploreembedded.com/wiki/Interactive_Menus_for_your_project_with_a_Display_and_an_Encoder
*/
static int pinA = 2; // Our first hardware interrupt pin is digital pin 2
static int pinB = 3; // Our second hardware interrupt pin is digital pin 3
/*
|
| For tutorial visit:
| http://exploreembedded.com/wiki/index.php?title=Interactive_Menus_for_your_project_with_a_Display_and_an_Encoder
|
*/
#include <SPI.h>
#include <Adafruit_GFX.h>
/*
Blink
Turns on an LED on for one second, then off for one second, repeatedly.
This example code is in the public domain.
*/
// Pin 13 has an LED connected on most Arduino boards.
// Pin 11 has the LED on Teensy 2.0
// Pin 6 has the LED on Teensy++ 2.0
#include<delay.h>
int pin = 2;
int numLED = 17;
int cnt =0;
int ledCount = 3;
int rCircle =0;
uint8_t pixels[48];
uint8_t bite = 0xf0;