Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.

shobana's Content

There have been 15 items by shobana (Search limited from 30-March 23)


By content type

See this member's

Sort by                Order  

#48430 how can i implement netduino plus garage door opener project

Posted by shobana on 16 April 2013 - 06:37 AM in Netduino Plus 2 (and Netduino Plus 1)

i connect one lan with pc with ip 192.168.1.7

other lan with netduino plus 2 with ip 192.168.1.6

 

itz all local host..

 

when i put this ip 192.168.1.6 in the other browser itz telling data is not received..




#48429 how can i implement netduino plus garage door opener project

Posted by shobana on 16 April 2013 - 06:35 AM in Netduino Plus 2 (and Netduino Plus 1)

hi sebswed,

 

thank you do much for ur help i did what all u said when i put the url i get the response no data is received,

now i am using VISUAL STUDIO c#2010 EXPRESS in WINDOWS 7 should i do change in this..




#48403 Network Settings

Posted by shobana on 15 April 2013 - 09:16 AM in Netduino Plus 2 (and Netduino Plus 1)

HI CHRIS,

I am not able to connect my netduino plus 2 to erase and when i deploy the ERROR-CONFIG , FLASH file not able deploy itz telling unable to deploy,

 

hope i don know the proper procedure

 

first i hold the button n plugged into the micro usb to pc when i ping in mf deploy the device doesnt appears m not able to erase and not able to deploy the browsed EROR_CONFIG EROR_FLASH files, if i remove it n connect then the device is showing but could'nt deploy the hex files what is reason pls tel me the solution.. 

 

can u pls tel me the proper procedure for netduino plus 2 to do the above settings..




#48402 Network Settings

Posted by shobana on 15 April 2013 - 08:20 AM in Netduino Plus 2 (and Netduino Plus 1)

HI CHRIS,

 when i ping my netduino plus 2 from pc itz not responding itz telling destination host is unreachable

 

mean while how to find out my netduino plus 2 ip can u jus tell me the solution to use the netduino plus 2 for internet(webserver transmit/receive) pls look into my above webservice.cs and program.cs coding whether itz working with ur netduino plus 2 or can u pls modify the codings and put in the post .zip file..

 

Thnx in advance chris..




#48399 how can i implement netduino plus garage door opener project

Posted by shobana on 15 April 2013 - 04:46 AM in Netduino Plus 2 (and Netduino Plus 1)

hello sebswed,

 

thank you so much for ur solution sir, but what u told to do i did in MFDeploy Tool i i pinged i get only response as TINY CLR

 

my netduino IP is not generating and also sir, when i run the coding if i connect the LAN the network config in MFDEPLOY TOOL shows me the at present LAN ip only like my connection with 192.168.1.4 if i put this in the browser i don get the page.. i getting confused with DNS primary:8.8.8.8 DNS secoundary :8.8.4.4 but in my pc itz DNS server like 252.83.etc

 

what can i do changes in this network config..

 

can u pls put me photo copy of ur webserver hello world output when u debuged,

i wil come to how the settings to be done,

 

> ur pc network config page

>ur device network cofig page..




#48382 how can i implement netduino plus garage door opener project

Posted by shobana on 14 April 2013 - 03:57 PM in Netduino Plus 2 (and Netduino Plus 1)

hello sebswed,

 thnx for reply the link which u showed only i trying itz not working the android app is jus demo app n the 2nd is netduino plus 2 m using this hardware coding is not working for me in the hardware  if i put the ip in other browser the page is not opening..




#48292 Monitor & Control your Garage Door with Android App

Posted by shobana on 11 April 2013 - 07:33 AM in Project Showcase

hello greg , IMPORTANT

 

now i have problem with this coding i don know what wud be the reason, the program is for netduino v4.1 but m having netduino plus 2 v4.2, i upgraded the project version 4.1 to 4.2 if i run this program i get an ip called 192.168.1.4 but if i give this ip in the web browser no data is received from the device

i set the network cofiguration using MFDeploy with 192.168.1.4
subnet mask is 255.255.255.0
default gateway is 192.168.1.1
but dns primary i gave the default 8.8.8.8
dns secoundary 8.8.4.4
in my pc i use one lan for that it shows ip 192.168.1.7
for device in the output window it shows 192.168.1.4

but if i put in the web browser the page is not opening

this is the source code

weserver.cs

using System;
using System.Net.Sockets;
using System.Net;
using System.Threading;
using System.Text;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using SecretLabs.NETMF.Hardware;
using SecretLabs.NETMF.Hardware.Netduino;
namespace NetduinoGarageDoorOpener
{
  public class WebServer : IDisposable
  {
  private Socket socket = null;
  //open connection to onbaord led so we can blink it with every request
  private OutputPort led = new OutputPort(Pins.ONBOARD_LED, false);
  private OutputPort Garage2CarOpener = new OutputPort(Pins.GPIO_PIN_D13, false);
  public WebServer()
  {
  //Initialize Socket class
  socket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);
  //Request and bind to an IP from DHCP server
  socket.Bind(new IPEndPoint(IPAddress.Any, 80));
  //Debug print our IP address
  Debug.Print(Microsoft.SPOT.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces()[0].IPAddress);
  //Start listen for web requests
  socket.Listen(10);
  ListenForRequest();
  }
  public void ListenForRequest()
  {
  while (true)
  {
  using (Socket clientSocket = socket.Accept())
  {
  //Get clients IP
  IPEndPoint clientIP = clientSocket.RemoteEndPoint as IPEndPoint;
  EndPoint clientEndPoint = clientSocket.RemoteEndPoint;
  //int byteCount = cSocket.Available;
  int bytesReceived = clientSocket.Available;
  if (bytesReceived > 0)
  {
  //Get request
  byte[] buffer = new byte[bytesReceived];
  int byteCount = clientSocket.Receive(buffer, bytesReceived, SocketFlags.None);
  string request = new string(Encoding.UTF8.GetChars(buffer));
  string firstLine = request.Substring(0, request.IndexOf('n')); //Example "GET /activatedoor HTTP/1.1"
  string[] words = firstLine.Split(' ');  //Split line into words
  string command = string.Empty;
  if (words.Length > 2)
  {
  string method = words[0]; //First word should be GET
  command = words[1].TrimStart('/'); //Second word is our command - remove the forward slash
  }
  switch (command.ToLower())
  {
  case "activatedoor":
  ActivateGarageDoor();
  //Compose a response
  string response = "I just opened or closed the garage!";
  string header = "HTTP/1.0 200 OKrnContent-Type: text; charset=utf-8rnContent-Length: " + response.Length.ToString() + "rnConnection: closernrn";
  clientSocket.Send(Encoding.UTF8.GetBytes(header), header.Length, SocketFlags.None);
  clientSocket.Send(Encoding.UTF8.GetBytes(response), response.Length, SocketFlags.None);
  break;
  //   default:
  //   //Did not recognize command
  //   response = "Bad command";
  //   header = "HTTP/1.0 200 OKrnContent-Type: text; charset=utf-8rnContent-Length: " + response.Length.ToString() + "rnConnection: closernrn";
  //   clientSocket.Send(Encoding.UTF8.GetBytes(header), header.Length, SocketFlags.None);
  //   clientSocket.Send(Encoding.UTF8.GetBytes(response), response.Length, SocketFlags.None);
  //   break;
  }
  }
  }
  }
  }
  private void ActivateGarageDoor()
  {
  led.Write(true);   //Light on-board LED for visual cue
  Garage2CarOpener.Write(true); //"Push" garage door button
  Thread.Sleep(1000); //For 1 second
  led.Write(false); //Turn off on-board LED
  Garage2CarOpener.Write(false);  //Turn off garage door button
  }

  #region IDisposable Members
  ~WebServer()
  {
  Dispose();
  }
  public void Dispose()
  {
  if (socket != null)
  socket.Close();
  }
  #endregion

  }
}

program.cs

using System;
using System.Net;
using System.Net.Sockets;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using SecretLabs.NETMF.Hardware;
using SecretLabs.NETMF.Hardware.Netduino;
namespace NetduinoGarageDoorOpener
{
  public class Program
  {
  public static void Main()
  {
  Microsoft.SPOT.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces()[0].EnableDhcp();
  WebServer webServer = new WebServer();
  webServer.ListenForRequest();
  }
  }

}

 

http://netduinohacki...-with-your.html

 

 

in this link the code u hv given is not working i want to interface the app with neduino plus 2 tel me the solution in what network configuration changes to be done..




#48291 Network Settings

Posted by shobana on 11 April 2013 - 07:19 AM in Netduino Plus 2 (and Netduino Plus 1)

hello dave,

 

http://netduinohacki...-with-your.html visit dis link this code is not giving me the output..

 

i want interface android app with this board to controll the garage door open/close




#48290 Network Settings

Posted by shobana on 11 April 2013 - 07:13 AM in Netduino Plus 2 (and Netduino Plus 1)

thnx for reply dave . now i have problem with this coding i don know what wud be the reason, the program is for netduino v4.1 but m having netduino plus 2 v4.2, i upgraded the project version 4.1 to 4.2 if i run this program i get an ip called 192.168.1.4 but if i give this ip in the web browser no data is received from the device

 

i set the network cofiguration using MFDeploy with 192.168.1.4

subnet mask is 255.255.255.0

default gateway is 192.168.1.1

but dns primary i gave the default 8.8.8.8

dns secoundary 8.8.4.4

 in my pc i use one lan for that it shows ip 192.168.1.7

for device in the output window it shows 192.168.1.4

 

but if i put in the web browser the page is not opening

 

this is the source code

 

weserver.cs

 

using System; using System.Net.Sockets; using System.Net; using System.Threading; using System.Text; using Microsoft.SPOT; using Microsoft.SPOT.Hardware; using SecretLabs.NETMF.Hardware; using SecretLabs.NETMF.Hardware.Netduino;

namespace NetduinoGarageDoorOpener {   public class WebServer : IDisposable   {   private Socket socket = null;   //open connection to onbaord led so we can blink it with every request   private OutputPort led = new OutputPort(Pins.ONBOARD_LED, false);   private OutputPort Garage2CarOpener = new OutputPort(Pins.GPIO_PIN_D13, false);

  public WebServer()   {   //Initialize Socket class   socket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);   //Request and bind to an IP from DHCP server   socket.Bind(new IPEndPoint(IPAddress.Any, 80));   //Debug print our IP address   Debug.Print(Microsoft.SPOT.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces()[0].IPAddress);   //Start listen for web requests   socket.Listen(10);   ListenForRequest();   }

  public void ListenForRequest()   {   while (true)   {   using (Socket clientSocket = socket.Accept())   {   //Get clients IP   IPEndPoint clientIP = clientSocket.RemoteEndPoint as IPEndPoint;   EndPoint clientEndPoint = clientSocket.RemoteEndPoint;   //int byteCount = cSocket.Available;   int bytesReceived = clientSocket.Available;   if (bytesReceived > 0)   {   //Get request   byte[] buffer = new byte[bytesReceived];   int byteCount = clientSocket.Receive(buffer, bytesReceived, SocketFlags.None);   string request = new string(Encoding.UTF8.GetChars(buffer));   string firstLine = request.Substring(0, request.IndexOf('n')); //Example "GET /activatedoor HTTP/1.1"   string[] words = firstLine.Split(' ');  //Split line into words   string command = string.Empty;   if (words.Length > 2)   {   string method = words[0]; //First word should be GET   command = words[1].TrimStart('/'); //Second word is our command - remove the forward slash   }   switch (command.ToLower())   {   case "activatedoor":   ActivateGarageDoor();   //Compose a response   string response = "I just opened or closed the garage!";   string header = "HTTP/1.0 200 OKrnContent-Type: text; charset=utf-8rnContent-Length: " + response.Length.ToString() + "rnConnection: closernrn";   clientSocket.Send(Encoding.UTF8.GetBytes(header), header.Length, SocketFlags.None);   clientSocket.Send(Encoding.UTF8.GetBytes(response), response.Length, SocketFlags.None);   break;   //   default:   //   //Did not recognize command   //   response = "Bad command";   //   header = "HTTP/1.0 200 OKrnContent-Type: text; charset=utf-8rnContent-Length: " + response.Length.ToString() + "rnConnection: closernrn";   //   clientSocket.Send(Encoding.UTF8.GetBytes(header), header.Length, SocketFlags.None);   //   clientSocket.Send(Encoding.UTF8.GetBytes(response), response.Length, SocketFlags.None);   //   break;   }   }   }   }   }   private void ActivateGarageDoor()   {   led.Write(true);   //Light on-board LED for visual cue   Garage2CarOpener.Write(true); //"Push" garage door button   Thread.Sleep(1000); //For 1 second   led.Write(false); //Turn off on-board LED   Garage2CarOpener.Write(false);  //Turn off garage door button   }

  #region IDisposable Members   ~WebServer()   {   Dispose();   }   public void Dispose()   {   if (socket != null)   socket.Close();   }   #endregion

  } }

 

program.cs

 

using System; using System.Net; using System.Net.Sockets; using System.Threading; using Microsoft.SPOT; using Microsoft.SPOT.Hardware; using SecretLabs.NETMF.Hardware; using SecretLabs.NETMF.Hardware.Netduino;

namespace NetduinoGarageDoorOpener {   public class Program   {   public static void Main()   {   Microsoft.SPOT.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces()[0].EnableDhcp();   WebServer webServer = new WebServer();   webServer.ListenForRequest();

  }

  } }




#48205 Network Settings

Posted by shobana on 09 April 2013 - 07:04 AM in Netduino Plus 2 (and Netduino Plus 1)

Dave VanderWekke var interf = NetworkInterface. GetAllNetworkInterfaces ()[0]; interf. EnableDynamicDns(); interf.EnableDhcp(); //System.Diagnostics. Debug.WriteLine(" Webserver is running on " + interf. IPAddress + " /// DHCP: " + interf. IsDhcpEnabled); WebServer webServer = new WebServer(); hello Dave wer shud i include dis code in the program..



#47972 Introducing Netduino Plus 2

Posted by shobana on 03 April 2013 - 10:59 AM in Netduino Plus 2 (and Netduino Plus 1)

thank you so much for the post,

wat i understud in that link is itz for 4.1 softwares to be installed but what m asking is ,

i now purchased new ND+2 board in that what i did is VBc# --> new project --> vbc#--> netduino plus 2 ( i selected)--> i put the code program.cs and webservice.cs--> debugged --> i got the output generating an ip but if i put that ip into other webbrowser m getting oops page doesn't opens , may i know the reason, can u pls suggest me how to implement..


mean while how to upgrade  project v4.1 to 4.2

 

 

http://wiki.netduino...y-mscorlib.ashx

 

 

in this link i followed the 4th step in this but i din get good response for this project..




#47971 Introducing Netduino Plus 2

Posted by shobana on 03 April 2013 - 10:57 AM in Netduino Plus 2 (and Netduino Plus 1)

thank you so much for the post,

 

wat i understud in that link is itz for 4.1 softwares to be installed but what m asking is ,

 

i now purchased new ND+2 board in that what i did is VBc# --> new project --> vbc#--> netduino plus 2 ( i selected)--> i put the code program.cs and webservice.cs--> debugged --> i got the output generating an ip but if i put that ip into other webbrowser m getting oops page doesn't opens , may i know the reason, can u pls suggest me how to implement..

 

 

mean while how to upgrade  project v4.1 to 4.2

 

http://wiki.netduino...y-mscorlib.ashx

 

in this link i followed the 4th step in this but i din get good response for this project..




#47968 Introducing Netduino Plus 2

Posted by shobana on 03 April 2013 - 10:40 AM in Netduino Plus 2 (and Netduino Plus 1)

im new to visual studio CAN U PLS DO THAT CHANGES IN THE CODE AND SEND ONE ATTACHMENT FILE LIKE .ZIP PLS

 

DIS IS MY MAIL ID shoby09@gmail.com




#47966 Introducing Netduino Plus 2

Posted by shobana on 03 April 2013 - 10:37 AM in Netduino Plus 2 (and Netduino Plus 1)

HOW TO DO UPGRADE THE PROJECT FROM 4.1 TO 4.2




#47922 Introducing Netduino Plus 2

Posted by shobana on 02 April 2013 - 08:46 AM in Netduino Plus 2 (and Netduino Plus 1)

hello sir,
 Now i purchased new netduino plus 2 board iand i want to run the garage door open or close project using netduino plus 2 but m gettin the error cannot deploy mcorlib.dll assmebilies of program 4.1 into the netduino plus 2 version4.2 pls tel me the solution
 
 
in this link this project i want to do in netduino plus 2  http://androidcodemonkey.blogspot.in
 
pls tel the solution..





home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.