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
/* Debounce Pokaždé, když se vstupní pin změní z LOW na HIGH (například kvůli stlačení tlačítka), výstupní pin je přepnut z LOW na HIGH nebo naopak. Mezi přepnutími je minimální prodleva, která slouží pro ošetření zákmitů (debouncing) obvodu. Obvod: | |
* LED připojena od pinu 13 k zemi * tlačítko připojené od pinu 2 k +5V | |
* 10 kΩ rezistor připojen od pinu 2 k zemi | |
* Poznámka: Na většině Arduin je LED k pinu 13 již připojena, takže k tomuto příkladu už další komponenty nebudete potřebovat. vytvořeno 21. listopadu 2006 autorem David A. Mellis upraveno 30. srpna 2011 Limor Fried upraveno 28. prosince 2012 Mike Walters Příklad tohoto kódu je veřejnou doménou. http://www.arduino.cc/en/Tutorial/Debounce | |
*/ | |
// konstanty použité k nastavení čísel pinů se nezmění: | |
const int buttonPin = 2; // číslo pinu tlačítka | |
const int ledPin = 13; // číslo pinu LED | |
// Proměnné se změní: | |
int ledState = HIGH; |
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
/*=========================================================================== | |
Title: I2C Scanner | |
- Repository: https://gist.github.com/AustinSaintAubin/dc8abb2d168f5f7c27d65bb4829ca870 | |
Version: 8 | |
Date: 2018 / 02 / 17 | |
Author: Austin St. Aubin | |
Email: AustinSaintAubin@gmail.com | |
Description: |
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 <iostream> | |
using namespace std; | |
int main() | |
{ | |
int a,b; | |
cin>>a; | |
for(int i=7;i>=0;i--) | |
{ | |
b=(a>>i)&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
/********************************************************************** | |
* Description : Rotacni enkoder pro Raspberry PI 2 | |
* Author : Denis Colesnicov | |
* E-mail : eugustus@gmail.com | |
* Notice : Original code https://www.sunfounder.com/learn/Super_Kit_V2_for_RaspberryPi/lesson-8-rotary-encoder-super-kit-for-raspberrypi.html | |
* Date : 2017/11/17 | |
**********************************************************************/ | |
/********************************************************************** | |
************************* TODO *************************************** |
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
short ConvertRGB(byte R, byte G, byte B) { | |
return (((R & 0xF8) << 8) | ((G & 0xFC) << 3) | (B >> 3)); | |
} |
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 "imguiSFML.h" | |
#include <SFML/OpenGL.hpp> | |
#include <SFML/Graphics/Color.hpp> | |
#include <SFML/Graphics/RenderTarget.hpp> | |
#include <SFML/Graphics/RenderWindow.hpp> | |
#include <SFML/Graphics/Sprite.hpp> | |
#include <SFML/Graphics/Texture.hpp> | |
#include <SFML/Window/Window.hpp> |
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
/** | |
* @file Singleton.cpp part of @file Singleton.hpp | |
* @version 2 | |
* | |
* @author Denis Colesnicov <eugustus@gmail.com> | |
* @date 2017/01/15 | |
* | |
* @copyright WTFPL | |
*/ |
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
/** | |
* @file Loader.cpp part of @file Loader.hpp | |
* | |
* @author Denis Colesnicov <eugustus@gmail.com> | |
* @date 2017/01/15 | |
* | |
* @copyright MIT | |
*/ | |
#include "LibraryLoader.h" |
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
/* | |
* Considerations on the possible implementation of word-wrap text for ImGui :: InputTextMultiline. | |
* | |
* Implements a "hard" line wrapping depending on the length of the text. | |
* | |
* Use, copying, modification and distribution without any liability to the author is possible. | |
* | |
* The discussion leads here: https://github.com/ocornut/imgui/issues/952 | |
* | |
* But it is still a problems: |
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
#pragma once | |
#include "IconsFontAwesome.h" // from https://github.com/juliettef/IconFontCppHeaders | |
namespace ImGui | |
{ | |
inline void SetupImGuiStyle( bool bStyleDark_, float alpha_ ) | |
{ |