Skip to content

Instantly share code, notes, and snippets.

View futureshocked's full-sized avatar

Peter Dalmaris futureshocked

View GitHub Profile
@futureshocked
futureshocked / 05.60_-_Grove_servo_motor.ino
Last active July 30, 2019 01:02
This sketch demonstrates how to use the Grove servo motor.
/* 05.60 - Grove servo motors
*
This sketch demonstrates how to use the Grove servo motor.
For the servo motor to
work, you must connect it to a PWM-capable pin.
Grove sockets that breakout PWM pins are D3, D5, D6, and D8 (inner pin only).
Connect the servo motor to Grove socket D3 and upload the sketch.
@futureshocked
futureshocked / 06.10_-_Grove_LCD_RGB_Backlight_Hello.ino
Created July 30, 2019 01:03
This sketch demonstrates how to use the Grove LCD RGB Backlight module.
/* 06.10 - Grove LCD RGB Backlight module Hello World
*
This sketch demonstrates how to use the Grove LCD RGB Backlight module.
It will print a welcome message and start a counter, with a red backlight.
Components
----------
@futureshocked
futureshocked / 06.12_-_Grove_LCD_RGB_Backlight_custom_chars.ino
Created July 30, 2019 01:04
This sketch demonstrates how to use the Grove LCD RGB Backlight module.
/* 06.12 - Grove LCD RGB Backlight module, custom characters
*
This sketch demonstrates how to use the Grove LCD RGB Backlight module.
Specifically, it shows how to create and display custom characters.
To create a custom character, you must draw it using pixels. Each character
is drawn on a 8x5 pixel array (8 rows, 5 columns).
For example, a smily emoji would looks like this ("x" is an "off" pixel,
@futureshocked
futureshocked / 06.20_-_Grove_Quad_Alphanumerical_demo.ino
Last active July 30, 2019 01:06
This sketch demonstrates how to use the Grove - 0.54 inch Red Quad Alphanumeric Display.
/* 06.20 - Grove - 0.54 inch Red Quad Alphanumeric Display demo
*
This sketch demonstrates how to use the Grove - 0.54 inch Red Quad Alphanumeric Display.
It will print letters and numbers.
Components
----------
@futureshocked
futureshocked / 06.21_-_Grove_Quad_Alphaneumerical_positions.ino
Last active July 30, 2019 01:08
This sketch demonstrates how to use the Grove - 0.54 inch Red Quad Alphanumeric Display.
/* 06.21 - Grove - 0.54 inch Red Quad Alphanumeric Display position demo
*
This sketch demonstrates how to use the Grove - 0.54 inch Red Quad Alphanumeric Display.
It will print letters and numbers at specific positions, and also control the
blink rate and dots.
Components
----------
@futureshocked
futureshocked / 07.40_-_Grove_controlled_blink.ino
Last active July 30, 2019 01:11
Grove - Project 1: Control the LED blink rate with a potentiometer (this Gist contains two files)
@futureshocked
futureshocked / 09.40_-_Environment_monitor.ino
Created July 30, 2019 01:12
Grove - Project 3: Make an environment monitor
/* 9.40 - Grove - Project 3: Make an environment monitor
This sketch implements an environment monitor.
It measures and calculates the air temperature using the Grove temperature module (thermistor).
It measures the ambient light using a photoresistor.
It displays the calculated temperature and measured light intensity in the Grove LCD.
If the light intensity is below a certain value, it turns on an LED strip via a Grove relay.
*** A challenge for you: ***
Can you adjust the circuit and sketch so that the value below which the LED strip is turned on can
@futureshocked
futureshocked / 10.40_-_Motor_control_with_potentiometer.ino
Created July 30, 2019 01:14
Grove - Project 4: Motor control with a potentiometer
/* 10.40 - Grove - Project 4: Motor control with a potentiometer
This sketch copies the position of a potentiometer to the servo motor.
As you turn the knob of the potentiometer, the servo motor moves accordingLy.
*** A challenge for you: ***
Can you make the necessary changes to this sketch and the hardware so that the motor
indicates the current temperature drawn on a sheet of paper?
@futureshocked
futureshocked / 11.40_-_Loud_noise_detector.ino
Last active July 30, 2019 01:16
Grove For Busy People - Project 5 - loud noise detector
/* 11.40 - Project 5 - Grove loud noise detector
This sketch implements a loud noise detector. It uses a simple soundsensor to pick up
noise. It calculates the volume of the noise, and if it is above a certain threshold,
it switches on an LED and increases the loud noise counter by 1.
The threshold is configurable via a potentiometer.
The sketch displays its operation parameters on an LCD screen.
@futureshocked
futureshocked / 08.40_-_Grove_dice.ino
Created August 1, 2019 22:56
This sketch implements an electronic dice.
/* 8.40 - Grove - Project 2: Make an electronic dice
This sketch implements an electronic dice.
When you press the momentary button or touch the touch sensor, the electronic dice
will start to "roll", and then display your lucky number on the LCD.
During the roll, the gadget will produce a tone of changin pitch, to add to the
anticipation, and several random numbers will appear in the LCD.
Components