.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Robotics: Writing and Testing VPL Services for Serial Communication

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net

VPL, part of Robotics Developer Studio is intended for novice programmers, but is also useful for testing and prototyping. We write a simple serial port service that allows you to send and receive data.

Trevor Taylor

MSDN Magazine February 2010

View Complete Post

More Related Resource Links

.NET Serial/COM Port Communication over Terminal Services



I hope I'll be able to clearly formulate my question.

Scenario: we have an application that integrates with several type of scanners (i.e. credit card, barcode, passport) using serial port interface.
It's the desktop application and can be deployed to run either in stand-alone environment or can be published over terminal services layer (citrix, TS, etc).
In the preferences of the application users are able to specify which scanner is assigned to which COM port.
For example: bar code scanner = COM1, credit card scanner = COM5.
To a user, names of the COM ports don't really make much sense and they won't know that the bar code scanner needs to be assigned to COM1 unless they go to Device Manager and look up the device name associated with the COM port under Ports (COM & LPT) section.

SerialPort class in .NET Framework has the function GetPortNames that returns the list of available COM ports: COM1, COM3, COM5, COM6, etc.
After doing a little research I found a way to get the descriptive names of each COM port device using WMI.

Here is the code for this:

  Public Shared Function GetAvailableSerialPorts(

Serial Communication with the .NET Compact Framework

Learn how to make your applications communicate over a serial port and how to handle common issues when implementing serial solutions. After a general discussion about serial communication and a common serial communication standard, this article demonstrates a practical use of the technologies through sample source code written in C#.

Serial Port Communication Read and Write using C#.net

In this simple article you will learn that how you can Open and read COM port data using System.IO.Ports Namespace.
Simply just create New Project of windows application in C#.

Import ServiceProcess APIs
using System.IO.Ports

Imports System.IO.Ports

Write Parsing functions which parse port data according to attached device

Foundations: Workflow Services for Local Communication


This month's column describes how to use WCF for communication between a workflow and a host application in Windows Workflow Foundation 3. This knowledge should help developers with their efforts using WF3 and prepare them for WF4, where WCF is the only abstraction over queues (referred to as "bookmarks" in WF4) that ships with the framework.

Matthew Milner

MSDN Magazine November 2009

Contract-First Web Services: Schema-based Development with Windows Communication Foundation


Schema- first contract-first modeling of Web Services gives you the ability to model your contracts with an XML-centric mindset. This process keeps you focused on universally acceptable types and the hierarchical data structures that can be represented in XML.

Christian Weyer, Buddhike de Silva

MSDN Magazine October 2009

Know Thy Code: Simplify Data Layer Unit Testing using Enterprise Services


If you want to employ unit testing and test-driven development techniques in your database application development process, you'll have different factors to consider than you do when you're not involving a database. For example, you have to maintain a consistent state within the database and be able to roll back transactions when necessary. This article shows you how to get the best of unit testing for your database apps in a safe, usable manner.

Roy Osherove

MSDN Magazine June 2005

Test Run: Automate Your ASP.NET Web Services Testing


It's no exaggeration to say that Web services are revolutionizing application-to-application communication. Web services are already being used extensively in corporate intranet environments and are making their way into commercial use, too.

James McCaffrey

MSDN Magazine March 2005

Windows Services: New Base Classes in .NET Make Writing a Windows Service Easy


Windows services are applications that run outside of any particular user context in Windows NT, Windows 2000, or Windows XP. The creation of services used to require expert coding skills and generally required C or C++. Visual Studio .NET now makes it easy for you to create a Windows service, whether you're writing code in C++, C#, or Visual Basic. You can also write a Windows service in any other language that targets the common language runtime. This article walks you through the creation of a useful Windows service, then demonstrates how to install, test, and debug the service.

Ken Getz

MSDN Magazine December 2001

Web Services Testing Tool



Do we have any Web Services Testing tools in .net. i mean using that tool i should able to know that web service is working or not and which methods or services exposing to the client app.

Public WCF services for testing clients

I try to find some (public) WCF services out there, but do not succeed. I want to talk to some for testing my work with clients. Any list ?

WCF services testing with SOAP UI

Hi, I am using soapUI tool to test my wcf services.It is working fine when using basicHttpbinding but not working with WSHttpbinding.Please tell me how to test WSHttpbinding with soapUI tool.Thanks,Vijay

Full duplex pc to half duplex serial communication with SerialPort class in C++ (but any language wi


Hello.  I am a bit new to the .NET environment, and though I feel I was able to get a good handle on most of the basics of .NET, I believe I've encountered a problem beyond the basics.  I am trying to talk with a device called a ColorPAL that uses asynchronous serial communication, but it is half-duplex instead of full-duplex.  I am able to send it the hex string commands that it wants just fine with the TX line.  However, I find myself unable to read because the RX isn't connected to anything.  Basically what I want to do is that I want to be able to swap the TX line to become a RX line so that I can then read line of the half-duplex.  I read that there is a PinChanged event, so it lead me to believe there is a way to change pins??   If the RX line is very high impedance I could connect it to the TX line, but I have no idea about that.


How can I get a full duplex to read a half-duplex using the visual studio software?


Here is the code I'm using, in case that helps.

#include "stdafx.h"
#include <Windows.h>

using namespace System;
using namespace 

Writing mode: vertical in Reporting Services 2008



I am new to Reporting Services 2008. I have a report from SSRS 2005. In that report layout, I modified text field's orientation to Vertical and set its writing mode as tb-rl. So, a field called [Report] displays  text vertically starting from R.

If this text is long say [Reporting services] it still displayed it vertically in one single line in SSRS 2005. But in SSRS 2008, It is appearing in two vertical lines. How can I get text in one vertical line?

Please advise.


RestFul Services for CallBack(Duplex communication)



I am able to implementing restful wcf service but now i want to use callback with it.Is it possible ?As i am getting some errors can anyone provide any Link for Restful WCF service callback.



Serial Communication in C#.NET


I am trying to communicate between PC and PIC micro-controller using RS232 serial port. Using visual studio C#.NET i am trying to read and write data to and from the serial port but am unable to succeed.Earlier i used hyperterminal with positive results..here is the code in C#.NET:


 using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace SimpleSerial
public partial class Form1 : Form
// Add this variable

string RxString;

public Form1()

private void buttonStart_Click(
object sender, EventArgs e)
serialPort1.PortName = "COM1";
serialPort1.BaudRate = 9600;

if (serialPort1.IsOpen)
buttonStart.Enabled = false;
buttonStop.Enabled = true;
textBox1.ReadOnly =

Code For serial Communication in C#.net 2005?


I want to develop a windows application in C#.Net 2005.

In this there is one textbox and one button.

My PC will be connected to other PC via serial port.

Application will be running on my PC.
Now when I type "Hello World" in my textbox and then click button.

This text should be shown on hyper terminal of the other PC.
I don't want to receive that text on other PC, I just have to send that text from my PC.

How To Do This?

Installing and Uninstalling Services

Installing and Uninstalling Services.Unlike most projects you create in Visual Studio .NET, Windows Service projects cannot be run directly from the development environment by pressing F5. This is because the service in the project must be installed before the project can run.

You can quickly install your service application by using a command line utility called InstallUtil.exe.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend