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
import easymidi from 'easymidi'; | |
import notifier from 'node-notifier'; | |
import path from 'path'; | |
import Player from 'play-sound'; | |
import throttle from 'lodash.throttle'; | |
// Settings | |
const ANSWER_DELAY = 3000; | |
const RED_BUTTON = 80; | |
const GREEN_BUTTON = 83; |

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
import UIKit | |
extension UIImage { | |
func resize(to newSize: CGSize) -> UIImage? { | |
guard self.size != newSize else { return self } | |
UIGraphicsBeginImageContextWithOptions(newSize, false, 0.0) | |
self.draw(in: CGRect(x: 0, y: 0, width: newSize.width, height: newSize.height)) |
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 axios = require('axios'); | |
const maps = ['A', 'B', 'C', 'D', 'E', 'F']; | |
const ROWS_COUNT = 6; | |
const COLUMN_COUNT = 9; | |
const USERNAME = 'shinework' | |
let TEMPLATE = ` | |
__________________________ | |
__..--/".' '. |
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
// Variables used by Scriptable. | |
// These must be at the very top of the file. Do not edit. | |
// icon-color: red; icon-glyph: camera; | |
const WIDTH = 60; | |
const HEIGHT = 60; | |
let widget = await createWidget(); | |
if (!config.runsInWidget) { |
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
from escpos.printer import Serial | |
""" 9600 Baud, 8N1, Flow Control Enabled """ | |
p = Serial(devfile='/dev/serial0, | |
baudrate=9600, | |
bytesize=8, | |
parity='N', | |
stopbits=1, | |
timeout=1.00, | |
dsrdtr=True) | |
p.text("Hello World\n") |
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
d |