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
//A for loop is a loop dictated by 3 expressions | |
for( | |
//This is executed once at the beginning of the loop | |
var i=0; | |
//The loop continues as long as this evaluates to TRUE | |
i<5; | |
//This is executed at the end of every iteration | |
++i | |
) | |
{ |
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
Starting program: /usr/bin/php | |
[Thread debugging using libthread_db enabled] | |
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1". | |
Program received signal SIGILL, Illegal instruction. | |
0xb6e0b5e0 in ?? () from /usr/lib/arm-linux-gnueabihf/libcrypto.so.1.0.0 | |
(gdb) bt | |
#0 0xb6e0b5e0 in ?? () from /usr/lib/arm-linux-gnueabihf/libcrypto.so.1.0.0 | |
Cannot access memory at address 0x0 | |
#1 0xb6e07fc4 in OPENSSL_cpuid_setup () from /usr/lib/arm-linux-gnueabihf/libcrypto.so.1.0.0 |
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
NSDateFormatter *f = [NSDateFormatter new]; | |
f.dateFormat = @"M/d/yyyy"; | |
NSLog(@"Date: %@", [f dateFromString:@"8/29/2014"]); | |
//Logs: | |
// Date: 2014-08-29 07:00:00 +0000 |
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
BMW 2002 Checks | |
Rust | |
shock towers | |
floor pans / The driver and passenger floors | |
spare tire well in the trunk | |
The lower rocker panels on each side of the car | |
The gas tank area | |
mainly look in those spots as those the hard places to fix it |
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
NSDictionary *cases = @{ | |
@"name": ^{ | |
return field.name; | |
}, | |
@"type": ^{ | |
return field.typeString.lowercaseString; | |
} | |
} | |
void (^block)() = cases[ident]; |
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
// | |
// RangeStreamer.h | |
// iOS Player | |
// | |
// Created by Ryan Layne on 4/2/15. | |
// | |
#import <Foundation/Foundation.h> | |
#import <AVFoundation/AVFoundation.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
var async = require('async'); | |
var _ = require('lodash'); | |
var SerialPort = require('serialport'); | |
// SerialPort.list(function (err, ports) { | |
// ports.forEach(function(port) { | |
// console.log(port.comName); | |
// console.log(port.pnpId); | |
// console.log(port.manufacturer); | |
// }); |
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
use std::any::Any; | |
use std::collections::HashMap; | |
use std::fmt; | |
pub struct GStore | |
{ | |
map: HashMap<String, Box<Any>> | |
} | |
impl GStore |
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
- (NSData *)build | |
{ | |
uint32_t type = _type; // 0 | |
uint32_t command = _command; // 3 | |
NSString *data = _data; // @"" | |
unsigned char byte = 0x00; // 0 | |
unsigned long size = sizeof(command) + sizeof(type) + data.length + sizeof(byte); // 9 | |
unsigned long totalSize = sizeof(uint32_t) + size; // 10 (including size uint32) | |
unsigned char bytes[totalSize]; |
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
import os | |
from threading import Thread | |
from time import sleep | |
import asyncio | |
FIFO_PATH = "/path/to/crash-log" | |
class FifoReader(Thread): | |
def __init__(self, path, crash): | |
super().__init__() |