Skip to content

Instantly share code, notes, and snippets.

View codetricity's full-sized avatar

Craig Oda codetricity

View GitHub Profile
@codetricity
codetricity / main.dart
Created November 10, 2021 00:46
Oppkey THETA ATK Tutorial - Getting Started
import 'package:flutter/material.dart';
import 'package:thetaf/thetaf.dart';
void main() {
runApp(const AtkTutorial());
}
class AtkTutorial extends StatelessWidget {
const AtkTutorial({Key? key}) : super(key: key);
@codetricity
codetricity / main.dart
Last active November 10, 2021 03:47
THETA ATK Layout Tutorial
import 'package:flutter/material.dart';
import 'package:thetaf/thetaf.dart';
void main() {
runApp(const AtkTutorial());
}
class AtkTutorial extends StatelessWidget {
const AtkTutorial({Key? key}) : super(key: key);
@codetricity
codetricity / main.dart
Created November 9, 2021 18:27
Simple template for Flutter App
import 'package:flutter/material.dart';
/// simple template for Flutter app
void main() {
runApp(const AtkTutorial());
}
class AtkTutorial extends StatelessWidget {
const AtkTutorial({Key? key}) : super(key: key);
@codetricity
codetricity / Main.java
Created November 9, 2021 15:20
example of finding matches in a string
public class Main {
public static void main(String[] args) {
String data = "CCAAAAATTT!";
char maxLetter = data.charAt(0);
int maxCount = 1;
for (int i = 0; i < data.length() -1; i++) {
int currentCount = 1;
char letter = data.charAt(i);
@codetricity
codetricity / main.dart
Last active June 14, 2021 01:28
Basic Dart Stream example
void main() async {
Stream<String> sushi = Stream<String>.periodic(Duration(seconds: 1), (x) => '$x: fish').take(10);
var mappedSushi = sushi.map((sushiPiece) => sushiPiece + ' mapped');
await mappedSushi.forEach( print);
}
/* output
0: fish mapped
1: fish mapped
@codetricity
codetricity / main.dart
Created August 2, 2020 00:22 — forked from alexeyismirnov/main.dart
MJPEG player written entirely in Flutter/Dart
import 'package:flutter/material.dart';
import 'mjpeg_view.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
@codetricity
codetricity / MainActivity.java
Created April 9, 2020 12:33
RICOH THETA Plug-in sample code by KA-2 for TensorFlow Lite plug-in
/**
* Copyright 2018 Ricoh Company, Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
@codetricity
codetricity / Oled.java
Last active June 20, 2019 00:51
RICOH THETA Z1 Open Source KA-2 OLED Library
/**
* Copyright 2018 Ricoh Company, Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@codetricity
codetricity / rainfall-01.03.js
Last active November 1, 2018 13:19
d3 rainfall lessons
d3.csv('data/rainfall-by-state.csv').then(data => {
data.forEach(stateData => {
stateData.rainfall = +stateData.rainfall;
const checkChar = /^[A-Z]/;
for (let i = 0; i < 5; i++) {
if (checkChar.test(stateData.state)) {
console.log('found capital letter');
break;
} else {
stateData.state = stateData.state.substring(1);
@codetricity
codetricity / bts-profile-4.rst
Last active October 22, 2018 12:35
BTS Member Profile Part 4

BTS Profile Height Analysis

image

Use the previous projects on temperature and BTS member height as a reference to create a chart that uses a graphic as data point marker instead of the previous circle.