In windows explorer locate the netcomm.ocx file on your computer and copy this file into the c: windows system directory if the file is not already there. Visual Basic for Applications may not find this file if it is not in this directory. The NETcomm driver is a direct replacement for the mscomm32.ocx driver except for data input. Oct 15, 2010 Download NetComm source (VB.NET) - 47.06 KB (Examples) Download HostClientExamples (VB.NET) - 112.63 KB; Download HostClientExamples (C#) - 87.42 KB; An example of the NetComm library usage in my robot-battle school project, this is a screenshot of the server, 4 clients are connected to it. The NetComm library allows you to.
Visual Basic for Applications NETcomm Serial Port Driver Example
We will continue our serial port control demonstration using the NETcomm.ocx driver. After downloading the NETcommocx.zip file, you will need to unpack the file in a blank temporary directory. Click on setup.exe to install and register the files. In windows explorer locate the netcomm.ocx file on your computer and copy this file into the c:windowssystem directory if the file is not already there. Visual Basic for Applications may not find this file if it is not in this directory.
The NETcomm driver is a direct replacement for the mscomm32.ocx driver except for data input. The mscomm32.ocx driver uses the command 'input' to capture input data where NETcomm.ocx driver uses 'inputdata' to capture the same data.
Note: as stated before, this example is tailored to the first time Visual Basic for applications user, but the information is useful for the advanced user that is unfamiliar with serial port control. If you're familiar with VBA and want to skip this demo, you may jump directly to the code segment.
Our screen should show a blank user form as shown below where we had left off.
Now we are going to add the serial port control to the control box so that we may use it in our application.
Right click in the controls box and select >> Additional Controls… Scroll down until you see the NETcommOCX.NETcomm Control, and click on the check box on the left, as shown below.
Click OK to continue. The control box will now have an additional icon displayed in the controls window as shown below.
Select this control and place your cursor on the user form, click the left button and the control will be placed on the screen.
Click on the command button icon in the tool box (rectangular box) and place two buttons on the user form. Click on CommandButton1 and the options will appear in the properties window. Click to the right of the Caption in the properties window and change commandButton1 to 'All Relays ON'. Click on the commandButton2 or select this name from the pull down at the top of the properties window, and change this to read 'All Relays OFF' as shown in the picture below.
Click on the NETcomm icon or use the properties pull down menu to view the properties for this control as shown below.
Click on the property labeled RThreshold, change this value from a '0' to a '1'. Do the same for the SThreshold property. Everything else in this window can remain the same for this example.
Note: If you need to read the port status on the board (which is not shown in this example) you need to change the InputMode property to '1-comInputModeBinary' by selecting the right pull down.
We are now finished with the configuration of the serial port and command buttons. The default settings are already set for com port 1, 9600 baud, 8 bits, no parity, and one stop bit.
From the menu at the top of the Visual Basic for Applications screen select View >> Code or press F7, and a code window will be displayed where the form currently resides. Click in the following box and select the contents of the box by holding the left mouse button and dragging down over the contents. Hold the Ctrl Button down and press 'C' to copy the contents to the clipboard.
Switch to Visual Basic for Applications and click inside the code window and highlight any information in this window -- press Ctrl 'V' to paste the contents into the code window. The window should now look like the following picture.
That's all the code that is required to turn all the relays ON and OFF on our relay boards, it will work on the 1, 2 & 8 Channel relay boards. Select File >> Save Book1 from the pull down menu to save your project before you attempt to run the program.
All that's left to do is run our program, but first make sure the relay board is connected.
On the RS232 versions:
Connect the board to com1 on the back of your computer using the 9 pin serial to modular cable adapter. Connect the modular cable from the adapter to the input of the relay board. Plug the AC adapter cable into the board and plug the AC adapter into the wall receptacle or apply power to the board if your using the internal transformer version.
On USB versions:
If you have not done this already - install the USB driver
Connect the board to your computer with the USB cable. Plug the AC adapter cable into the board and plug the AC adapter into the wall receptacle or apply power to the board if your using the internal transformer version. The USB driver will recognize the board and install a virtual serial port (com port) To determine what port the board is connected to - open the device manager. Enter 'devmgmt.msc' in the run dialog box in windows, select ports and the device should be displayed as 'USB serial port (number)' Change the port number in the program you just created to match this port.
Assuming that everything is connected up properly, press the blue right arrow at the top of the screen and our program will run. To stop the program click the box on the top right of the user form, DO NOT close the program using the blue square box in the VBA editor. If you would close the program using the blue box the serial port will not be closed properly, and it may not operate properly if you would restart the program.
The running program is shown below:
Click the 'All Relays ON' button and you will hear an audible click from the relays or the LED indicator will light - this is activating all the relays on the board and pressing the 'All Relays OFF' button will turn all them OFF.
Congratulations on your first Visual Basic For Applications control program using the Netcomm OCX driver and relays boards manufactured by Pencom Design, Inc.
We're sure you will find many practical applications for using your RS232 or USB serial controlled relay board.
Return to the previous page
Netcomm MyZone-3G24W routers include a very basic firewall that helps protect your home network form unwanted access from the internet. Since this firewall blocks incoming connections you may need open a port through it for certain games and applications. This process of opening a port is frequently called a port forward, since you are forwarding a port from the internet to your home network.
The basic process to open a port is:
- Setup a static IP address on either your computer or device that you want to forward a port to.
- Login to your Netcomm MyZone 3G24W router.
- Navigate to the port forwarding section.
- Click the Switch to Advanced View link.
- Click the Service link.
- Click on Routing.
- Click on NAT.
- Create a port forward entry.
While these steps might seem difficult at first, we will walk you through each step for your Netcomm MyZone-3G24W router.
We think that forwarding a port should be easy. That's why we created Network Utilities.Our software does everything that you need to forward a port.
When you use Network Utilities you get your port forwarded right now!
It is important to setup a static ip address in the device that you are forwarding a port to. This ensures that your ports will remain open even after your device reboots.
- Recommended - Our free program will setup a static IP address for you.
- → Download Network Utilities today!
- Or follow our Static IP Address guides to setup a static IP address.
Download Netcomm Network App
After setting up a static ip address on your devices you need to login to your router.
Now we are going to login to your Netcomm MyZone-3G24W router. Your router has a web interface, so you will login to it using your web browser.This can be either Chrome, Firefox, Internet Explorer, or Edge. It usually does not matter which browser you choose to use.
Open up your web browser and find the address bar. It should look something like this:
In the picture above the address bar has 192.168.10.50 in it. Just replace all of that with the IP address of your Netcomm MyZone-3G24W router.Your router's IP address can also be refered to as your computer's default gateway.
By default the IP address is set to: 192.168.10.50
After entering the IP address of your router you can simply press enter. If all goes well you will see the following screen:
Download Netcomm Network Connect
Click the Switch to Advanced View link near the bottom of the page.
You should see a box prompting you for your username and password.
- The Default Netcomm MyZone 3G24W Router Username is: admin
- The Default Netcomm MyZone 3G24W Router Password is: blank
Enter your username and password, and then click the Login button to log in to your Netcomm MyZone-3G24W router.
Netcomm Usernames and Passwords
If your username and password do not work then please visit our Default Netcomm Router Passwords page.
If you still can't login to your router because you forgot your Netcomm MyZone-3G24W router username and password, use our How to Reset a Router Password guide to set your Netcomm MyZone-3G24W router back to its factory settings.
Now we need to find the port forwarding section in your router. Here's how you do it. Starting from the first page in your router:
Click the Service link near the top of the page.
You should now see a new menu. In this new menu, click Routing.
You should now see a new menu. In this new menu, click NAT.
Here are the ports to forward for Xbox Live:
If you are looking for the ports for a different application you can find it by either:
- Browsing our List of Games
- Check out our our List of Games by Genre
- See our List of all Applications
Select the protocol type of the ports you are forwarding from the Protocol box.
If you are forwarding a range of ports, enter the lowest number of that range into the left hand Incoming Port Range and Destination Port Range boxes. Then enter the highest number of that range into the right hand Incoming Port Range and Destination Port Range boxes.
If you are forwarding a single port, enter that port number into both of the Incoming Port Range and both of the Destination Port Range boxes.
You need to enter the IP address that you are forwarding ports to in the Destination IP Address box. It's possible for this to be either the IP address of your computer or any other IP address on your network that you want ports forwarded to.
Click the Save NAT button when you are all done.
Your ports should now be open. It is time to test them.
Test if Your Ports are Open
Now that you have forwarded ports on the Netcomm MyZone-3G24W you should test to see if your ports are forwarded correctly.
To test if your port has been properly forwarded, you can use our Network Utilities tool, which includes a free Open Port Checker.Our Open Port Check tool is the only online port checking tool with Guaranteed Results.
Netcomm MyZone-3G24W Router Screenshots
We also have the Internets largest collection of Router Screenshots.