Skip to content

Instantly share code, notes, and snippets.

View wess's full-sized avatar
💭
When am I not writing code?

Wess Cope wess

💭
When am I not writing code?
View GitHub Profile
@wess
wess / ENDER 3 BLTOUCH SETUP
Last active April 27, 2022 03:18
BLTouch Config for Ender 3 (download from http://marlinfw.org)
Configuration.h
COMMENT 78: //#define SHOW_BOOTSCREEN // Save memory.
COMMENT 97: //#define CUSTOM_STATUS_SCREEN_IMAGE // Save memory.
EDIT 375: #define DEFAULT_Kp 32.24 // PID settings with Micro Swiss all metal hotend.
EDIT 376: #define DEFAULT_Ki 3.71 // PID settings with Micro Swiss all metal hotend.
EDIT 377: #define DEFAULT_Kd 69.98 // PID settings with Micro Swiss all metal hotend.
class OnboardingScreen extends StatefulWidget {
const OnboardingScreen({Key? key}) : super(key: key);
@override
_OnboardingScreenState createState() => _OnboardingScreenState();
}
class _OnboardingScreenState extends State<OnboardingScreen> {
final TextEditingController _nameController = TextEditingController();
#!/usr/bin/env bash
export SODA_SCRIPTS_ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
source ${SODA_SCRIPTS_ROOT}/__echo.sh
#### Websocket Setup
SERVER_PORT=3333
WS_PIPE=/tmp/_websocket.tmp
IN_PIPE=/tmp/_in_websocket.tmp
@wess
wess / request.coffee
Created February 6, 2012 17:06
Basic and Simple to Use Request Class for CoffeeScript
#
# request.coffee
#
# Created by Wess Cope on 2012-01-30.
#
# Just a start. The basics in place and working
# to expand as elements are needed.
#
class Request
//
// color.dart
// foundation
//
// Author: Wess Cope (me@wess.io)
// Created: 09/16/2021
//
// Copywrite (c) 2021 Wess.io
//
@wess
wess / meta.dart
Last active September 3, 2021 13:35
import 'dart:convert';
class Meta {
Map<String, dynamic> _backing;
dynamic get(String key) => _backing[key];
void insert(Map<String, dynamic> data) => _backing = {..._backing, ...data};
Meta set(String key, dynamic value) {
_backing[key] = value;
import 'package:bastion/providers/data.dart';
import 'package:fluentui_system_icons/fluentui_system_icons.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:hive/hive.dart';
import 'package:window_size/window_size.dart';
enum NavOption {
converter,
profiles,
@wess
wess / FlutterChannel.swift
Last active June 4, 2021 18:10
FlutterChannel.swift
class FlutterChannel {
static private let _instance = FlutterChannel()
private let channel = {
let _channel = FlutterMethodChannel(...)
channel.setMethodCallhandler(FlutterChannel.route)
return _channel
}()
@wess
wess / gist:3353556
Created August 14, 2012 22:28
Convert command line arguments in Objective-c to an NSDictionary
// Supports --foo=bar and -f bar
static NSDictionary *arguments()
{
NSArray *arguments = [[NSProcessInfo processInfo] arguments];
if(arguments.count < 2)
return nil;
NSMutableDictionary *argsDict = [[NSMutableDictionary alloc] init];
def handle_call({:put, key, value}, _from, state) do
{:reply, :ok, Map.put(state, key, value)}
end
def handle_call({:get, key, value}, _from, state) do
{:reply, :ok, Map.get(state, key, value)}
end