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.

zimmersm's Content

There have been 1 items by zimmersm (Search limited from 29-April 23)


By content type

See this member's

Sort by                Order  

#57899 Netduino 2 Plus Serial (COM) Port

Posted by zimmersm on 02 May 2014 - 10:04 PM in Netduino Plus 2 (and Netduino Plus 1)

Hi everyone, 

I am experiencing a kind of odd problem having to do with SerialPort on the Netduino 2 Plus.  In a black project, I can successfully create, open, and write to COM1 (pins D0 and D1).  However, I am using NeonMika Webserver in my project to host a web interface.  When in this project, my SerialPort will not open.  Here's the code below. Thanks! 

using System;
using System.Net;
using System.Net.Sockets;
using System.Collections;
using System.Threading;
using System.IO.Ports;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using SecretLabs.NETMF.Hardware;
using SecretLabs.NETMF.Hardware.Netduino;
using NeonMika.Webserver;
using NeonMika.Webserver.Responses;

namespace HomeAutomation
{
    public class Program
    {
        public static SerialPort serial = new SerialPort(SerialPorts.COM1, 9600);

        public static void Main()
        {
            serial.Open(); // error is thrown here and breaks the program

            Server server = new Server(PinManagement.OnboardLED, 80, false, "192.168.1.120", "255.255.255.0", "192.168.1.1", "netduinoplus");
            //server.AddResponse(new XMLResponse("send", new XMLResponseMethod(Program.Send)));
        }




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.