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
using System; | |
using System.Collections.Generic; | |
using System.Management; | |
namespace TTR_RMM | |
{ | |
class HardDisk | |
{ | |
public String Model { get; set; } | |
public String Interface { get; set; } |
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
#include <stdio.h> | |
#include <string> | |
#include <iostream> | |
#include <windows.h> | |
#include <vector> | |
using namespace std; | |
//Simple struct to return from lsfiles |
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
//Potentiometer Reader | |
/* | |
+++Wiring+++ | |
(ground)----(potentiometer)----|----(+5VDC) | |
| | |
Analog Pin 5 | |
*/ | |
int potPin = A5; //Analog input pin 5, labeled A5 |
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
int pins[7]; | |
void setup(){ | |
pinMode(4, OUTPUT); | |
pinMode(3, OUTPUT); | |
pinMode(2, OUTPUT); | |
pinMode(5, OUTPUT); | |
pinMode(6, OUTPUT); | |
pinMode(7, OUTPUT); | |
pinMode(9, OUTPUT); | |
pinMode(10, OUTPUT); |
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
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=true"></script> | |
<script type="text/javascript"> | |
geocoder = new google.maps.Geocoder() | |
function geoCode(address){ | |
var simpleLoc = {}; | |
geocoder.geocode({ 'address': address }, function(results, status) { | |
simpleLoc['status'] = status; | |
simpleLoc['latlng'] = new google.maps.LatLng(results[0].geometry.location.lat(), results[0].geometry.location.lng()); | |
}); |
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
package com.mt.myapplication2.app; | |
/** | |
* Created by Mitchell on 3/28/14. | |
*/ | |
class C | |
{ | |
private String _me; | |
public String getC(){ | |
return _me; |
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
echo 1 > /proc/sys/net/ipv4/ip_forward | |
#Assuming eth0 is connected to the Internet or other network and eth1 is connected to a private network | |
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE | |
iptables -A FORWARD -i eth0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT | |
iptables -A FORWARD -i eth1 -o eth0 -j ACCEPT |
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
using Amazon.S3; // Add reference to C:\Program Files (x86)\AWS SDK for .NET\bin\Net35\AWSSDK.dll | |
using Amazon.S3.Model; | |
using System; | |
using System.Net.Security; | |
using System.Security.Cryptography.X509Certificates; | |
namespace ConsoleApplication2 | |
{ | |
class Program | |
{ | |
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
<?xml version="1.0"?> | |
<!--The example shows how to program the softkeys for GXP-2020/2010 --> <Screen> | |
<IdleScreen> | |
<DisplayBitmap> <Bitmap>///// </Bitmap> | |
<X>0</X> | |
<Y>0</Y> </DisplayBitmap> | |
<DisplayString font="f8"> | |
<DisplayStr>$W, $M $d</DisplayStr> <X>0</X> | |
<Y>0</Y> | |
</DisplayString> <DisplayString font="f13h" halign="Center" a1reg="false"> |
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
function csv2objArr(data, strip, callback){ | |
(strip instanceof Function) ? (callback = strip, strip = 0) : (strip = strip || 0); //Did the user specify strip? | |
data = data.split('\n' || '\r'); | |
if(strip){ | |
for(var elem in data){//loop to convert "val, val, val" to ["val", " val", " val"] | |
var tmpArr = data[elem].split(','); | |
for(var tmpElem in tmpArr){//loop to convert ["val", " val", " val"] to ["val", "val", "val"] | |
tmpArr[tmpElem] = tmpArr[tmpElem].trim(); | |
} | |
data[elem] = tmpArr.join(); //convert ["val", "val", "val"] to "val,val,val" |
OlderNewer