This file contains hidden or 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
/* | |
HelloWorld.ino | |
"Hello World" version for U8x8 API | |
Universal 8bit Graphics Library (https://github.com/olikraus/u8g2/) | |
Copyright (c) 2016, [email protected] | |
All rights reserved. |
This file contains hidden or 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 <Arduino.h> | |
#include <U8g2lib.h> | |
#ifdef U8X8_HAVE_HW_SPI | |
#include <SPI.h> | |
#endif | |
#ifdef U8X8_HAVE_HW_I2C | |
#include <Wire.h> | |
#endif |
This file contains hidden or 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 <Arduino.h> | |
#include <U8g2lib.h> | |
#ifdef U8X8_HAVE_HW_SPI | |
#include <SPI.h> | |
#endif | |
#ifdef U8X8_HAVE_HW_I2C | |
#include <Wire.h> | |
#endif |
This file contains hidden or 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
var Enhance = InnerComponent => class extends React.Component { | |
render() { | |
return <InnerComponent {...this.props} data={"wasdwasd"} />; | |
} | |
}; | |
// HOC Usage | |
// import { Enhance } from "./Enhance"; | |
class MyComponent extends React.Component { | |
render() { |
This file contains hidden or 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
CREATE TABLE IF NOT EXISTS "calendar_dates" ( | |
"service_id" varchar(100), | |
"date" decimal(10,2), | |
"exception_type" decimal(10,2) | |
); | |
CREATE TABLE IF NOT EXISTS "routes" ( | |
"route_id" int PRIMARY KEY, | |
"route_short_name" varchar(15), | |
"route_long_name" varchar(15), |
This file contains hidden or 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 w = require('winston') | |
const chalk = require('chalk'); | |
w.level = 'silly'; | |
w.error('error log') | |
w.warn('warn log') | |
w.info('info log') | |
w.verbose('verbose log') | |
w.debug('debug log') | |
w.silly('silly log') |
This file contains hidden or 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
/** | |
* CLI-CLOCK | |
* | |
* Cli-Clock is a clock for your terminal. Once you run the program, it will display the current time on your | |
* terminal windo and ti will update every thirty seconds. The clock is formed by two characters, which are choosen | |
* from a preselected set of characters or passed as arguments by the user. Once the program starts, the application will | |
* measure the size of the current terminal window and display the time in the center of the window. | |
* | |
* Example usage: | |
* |
This file contains hidden or 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 <Adafruit_GFX.h> | |
#include <Adafruit_SSD1306.h> | |
#include "Wire.h" | |
extern "C" { | |
#include "utility/twi.h" // from Wire library, so we can do bus scanning | |
} | |
#define TCAADDR 0x70 | |
void tcaselect(uint8_t i) { |
This file contains hidden or 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 "Wire.h" | |
extern "C" { | |
#include "utility/twi.h" // from Wire library, so we can do bus scanning | |
} | |
#define TCAADDR 0x70 | |
void tcaselect(uint8_t i) { | |
if (i > 7) return; | |
NewerOlder