Edi Wang

.NET and Azure Developer

Microsot Azure The Best Cloud

Azure Fire Alarm by Raspberry Pi and Windows 10 IoT Core

防火是日常生活中非常重要的意识,如果你是一只恩爱狗,出门在外,家里被FFF团点了,那真是太惨(hao)了。如果你恰好有Windows 10的设备,比如Lumia,Surface,能及时收到火警是至(mei)关(sha)重(luan)要(yong)的。今天就教大家如何用Microsoft Azure公有云+Windows 10 IoT Core在树莓派上实现一个远程火警系统。 阅读这篇文章,你需要的前置知识: Windows 10,UWP的基本开发能力 MVVM基础知识 ASP.NET MVC的基础知识 树莓派、GPIO及逻辑电路的基本知识(也就是大学里的计算机电路) Azure公有云的使用经验 ……当然,还要有对微软的信仰 一、设计原理 基本想法是,通过火焰传感器的输入信号,触发一个警报,把消息发送到Azure上的Notification Hub,这个服务是专门给 …
Windows Azure IoT Raspberry Pi

Raspberry Pi Surveillance Camera with Linux and Azure

Because Windows 10 IoT Core is not supporting Pi Camera, I can only use Linux instead. These days, I made a surveillance camera, the functionality is simple, when a person passed by the camera, it will take a picture and upload to Microsoft Azure Storage. It also got a website to remotely view the photos. 1. Hardware A PIR Sensor, a Pi Camera, a couple of jump wires. Connect the Singal port of …
Azure IoT Raspberry Pi Linux Python

Azure Remote Controlled Light with Windows 10 IoT Core

For those who have watched the "Big Bang Theory", you would probably remember that those physicists build an Internet controlled lamp. The signal send from their laptop traveled around the world and come back to their house to light up the lamp. Now, with Windows 10 IoT Core and Microsoft Azure, we could also achieve the same thing on a Raspberry Pi 3. First, I strongly recommend you to read …
Windows Azure IoT Raspberry Pi

How to Manage Azure App Service in IIS Manager (inetmgr)

The website we created on Azure seems can be only managed in the web portal or in the Server Explorer of Visual Studio. If we would like to use IIS to manage more powerful scenarios, seems VM is the only way. But that's not true. First, the IIS comes with Windows 8.1 can't connect to Azure by default. We need to install an extension http://www.iis.net/downloads/microsoft/iis-manager After install. …
IIS Azure

Azure Website Showing 404 for .woff Fonts in IE

If you are using Website on Microsoft Azure (Currently renamed to Web Apps), you will find the .woff web font is not working in IE, it returns 404. Based on my experience, this is because IIS is not configured to use the correct MimeType. However, we can not operate the IIS on Azure, there's no RDP into an Azure Web Apps backend machine. How can we do that? In fact, after IIS7, the MineType is …
IIS Azure

Azure SQL数据库如何做定期自动备份

Azure上的数据库可以通过手工export来备份,方法我在博客里写过。但是如果要求定期做的话,需要人工参与。偷懒的做法是用Azure自带的定期备份功能。 1. 在Azure Portal点开你的数据库,切换到CONFIGURE页面。 Automated Export的意思就是自动导出数据库(bacpac格式),默认是NONE,也就是不自动备份。选择AUTOMATIC。 2. 选完之后,下面会出来详细设置。 STORAGE ACCOUNT选你要保存备份文件的存储账户。FREQUENCY是频率,这个例子里我选择每28天备份一次,从2015年4月2日12:00A.M.开始。保留90天内的备份(这个选项的意思就是备份文件多久以后会被自动删除) 另外,还需要填写SQL数据库服务器的登录账户和密码。然后保存设置就完成了! 3. 一旦到了指定时间,触发了备份。你就能在你刚才设置的存储账户里找到一个 …
SQL Azure

Azure SQL数据库Web Tier爆了,如何迁移数据库

今天做了次数据库迁移,目的是开个最新版的Azure SQL Database(V12 Update),然后把博客的数据库迁移到新的server上去。按以往的做法(也就是我曾经写过的《图解:如何将SQL Server数据库迁移到SQL Azure 》),把bacpac文件下载下来,然后import到新的数据里,结果爆了: 爆炸是因为Web Tier和Business Tier在最新版的Azure上面已经被微软撸掉了,SSMS 2014却没有升级,不认识这两个Tier,还在用老的Web Tier。 TITLE: Microsoft SQL Server Management Studio ------------------------------ An exception occurred while executing a Transact-SQL statement or batch. …
SQL SSMS Azure

How to move Microsoft Azure Application Insights

本文目前仅适用于国际版的Azure,国内版没有Application Insight服务,请注意。如果你还没有感受过Application Insight这个人类的最新希望,可以到大微软的Channel 9电视台学习一下:http://channel9.msdn.com/Series/Application-Insights-for-Visual-Studio-Online 另外,本文所说的迁移方法不会保留Application Insight的历史数据,如果你看到这里就想喷:你TM在逗我?这叫什么迁移? 。。。 那还是别往下看了。我的标题叫迁移,是因为我实在找不到别的词了。 如果你换了个Microsoft Azure的订阅,怎么迁移以往的ASP.NET, WP工程上面已经配置好的Application Insight呢?目前Azure Portal没有提供更改订阅的功能。所以我们只能在 …
Visual Studio Azure Application Insight

如何定时开关机Microsoft Azure上的虚拟机

作为一个屌丝,用Azure的时候得处处想着省钱,在你不用虚拟机的时候关机是个省钱的好办法。当然,每天手动登录Portal去开关机比较麻烦。如果你用VM的时间段比较固定,可以做个定时开关机的任务帮你省钱。 做法是用一台机器作为Controller,在上面建立开关机任务,调度Azure上的VM。比如你自己的机器每天早上8点开机,下午5点关机。你希望Azure上的某台VM早上8:30开机,下午4:30关机。那你就可以把自己的机器作为Controller。当然,你也可以在Azure上开一台专门作为Controller的Server,给它分配一个768MB内存的屌丝instance(diaostance)来省钱。 这台Controller机器上必须安装Microsoft Azure PowerShell,并且要在PowerShell里登录一次Azure。本文不再叙述,具体做法请看我之前写的《图解 …
Azure PowerShell VM

图解:如何在Visual Studio 2013中连接中国版的Azure

VS2013的Server Explorer在第一次连接Azure的时候默认弹出的登录框只能登录国际版的Azure。但是国内很多屌丝没有国际版怎么办呢?其实国内世纪互联运营的windowsazure.cn也可以通过导入订阅的方式来连接。 1. 登录国内版Azure之后,访问这个地址,下载你的订阅文件:https://manage.windowsazure.cn/publishsettings/index 2. 在VS2013里打开Server Explorer,不管你有没有连接到国际版的Azure,这里操作方法都是一样的。在“Azure”上点右键,选择“Manage Subscriptions...” 3. 在弹出的对话框里,选择“Certificates”选项卡,然后点击“Import”按钮,把刚才下载的订阅文件导入。 4. 导入成功以后应该是这个样子的。 5. 接下来,你就能同 …
Azure