This is an example of using the Arduino and ASP.NET.
You can use this project as the core of your Home automation / Internet of things.
The Arduino connects to the network using an Ethernet Shield.
ASP.NET project runs on a windows (IIS).
This repository contains two projects.
IRControl allows you to control any devices from the Internet.
This requires the Arduino to connect the IR Reciever and IR Transmitter.
The Arduino can memorize any code of remote control in the learning mode.
Temperature refers to the Arduino every minute, requests the temperature and humidity from DTH11 sensor and stores the data in the database.
Then you can see a nice graph of temperature and humidity.
You can use two of these projects simultaneously with a single Arduino Board.
Connect the IR Reciever to pin 5, IR Transmitter to pin 3, DTH11 to pin 2. Ethernet shield uses pins 10, 11,12,13.
In ArduinoASP_Device.ino file you need to configure the ip address of the Arduino:
IPAddress ip(192, 168, 1, 20);
IPAddress gateway(192, 168, 1, 1);
Then this IP address must be specified in the file ArduinoIRControl.cs and ArduinoTemperatureSensor.cs:
private string arduinoAddress = "http://192.168.1.20";
In Web.config files you need to specify the connection string to the SQL server:
add name="DbConnection" ... User ID=username;Password=password"
I am using hangfire to background task worked without user activity.
You need to configure IIS, otherwise the web application will be unloaded from memory spontaneously.
Instructions here: http://docs.hangfire.io/en/latest/deployment-to-production/making-aspnet-app-always-running.html
-
Notifications
You must be signed in to change notification settings - Fork 2
dy-sh/arduino-asp-example
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
This is an example of using the Arduino and ASP.NET. You can use this project as the core of your Home automation / Internet of things.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published