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
public static class CloudBlobExtensions | |
{ | |
/// <summary> | |
/// Uploads a string of text to a block blob. | |
/// </summary> | |
/// <param name="content">The text to upload, encoded as a UTF-8 string.</param> | |
public static void UploadText(this ICloudBlob blob, string content) | |
{ | |
UploadText(blob, content, Encoding.UTF8, null); | |
} |
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
netsh firewall set icmpsetting 8 enable |
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
#! /bin/bash | |
### BEGIN INIT INFO | |
# Provides: azureobd | |
# Required-Start: $remote_fs $syslog $network $all | |
# Required-Stop: $remote_fs $syslog $network | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Start AzureOBD at boot time | |
# Description: Start AzureOBD at boot time. | |
### END INIT INFO |
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
async void Main() | |
{ | |
var mf = MessagingFactory.CreateFromConnectionString("***"); | |
var eventHubClient = mf.CreateEventHubClient("test"); | |
Random rnd = new Random(); | |
Parallel.For(1, 11, deviceId => | |
{ | |
for(int cnt = 0; cnt < 100; cnt++) | |
{ | |
Console.WriteLine ("Sending event nr {1} for device {0}", cnt, deviceId); |
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
async void Main() | |
{ | |
var mf = MessagingFactory.CreateFromConnectionString("your cnx string here"); | |
var eventHubClient = mf.CreateEventHubClient("ehname"); | |
Random rnd = new Random(); | |
Parallel.For(1, 11, async (deviceId) => | |
{ | |
for(int cnt = 0; cnt < 50; cnt++) | |
{ | |
Console.WriteLine ("Sending event nr {0} for device {1}", cnt, deviceId); |
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
void Main() | |
{ | |
Random rnd = new Random(); | |
rnd.GetString("1-###-000").Dump(); | |
} | |
public static class RandomExtensions | |
{ | |
public static string GetString(this Random random, string format) | |
{ |
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.Diagnostics; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using Windows.Devices.Enumeration; | |
using Windows.Devices.I2c; | |
namespace Codit.IoT.PIGlow |
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
REFERENCE ASSEMBLY ImageCommon; | |
REFERENCE ASSEMBLY FaceSdk; | |
REFERENCE ASSEMBLY ImageEmotion; | |
REFERENCE ASSEMBLY ImageTagging; | |
REFERENCE ASSEMBLY ImageOcr; | |
@imgs = | |
EXTRACT FileName string, ImgData byte[] | |
FROM @"/data/employees/{FileName:*}.jpg" | |
USING new Cognition.Vision.ImageExtractor(); |
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.Text; | |
using System.Threading.Tasks; | |
using Microsoft.WindowsAzure.Storage; | |
using Microsoft.WindowsAzure.Storage.Auth; | |
using Microsoft.WindowsAzure.Storage.Table; | |
using TableStorage.Abstractions.TableEntityConverters; | |
using Traiders.Storage.Configuration; |
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.Text; | |
using System.Threading.Tasks; | |
using Azure.Storage.Files.DataLake; | |
using System.IO; | |
using System.Net; | |
using Azure; | |
using Azure.Storage; | |
using Azure.Storage.Files.DataLake.Models; | |
using Azure.Storage.Sas; |
OlderNewer