[#GADGETS] How to control USB Email Notifier with C# (I)

image

Buenas,

showed yesterday on the talk of robotics at the University such as connecting a USB device and start playing with it to see if we can do something using C#. For the demo used a gadget like this USB Email Notifier (link) which sold over the internet to only us$ s:8, 68 (including shipment costs).

image

This USB HUB comes with a special software that makes the envelope to change color from certain events. For example: check our mailbox and when a new mail arrives because it turns a red led inside the same.

The goal of this post is to show how to create a class C# to turn off the light to our liking. The first thing we need to do is identify the device HID as explained in this post. To do this use theSimpleHIDWrite tool (download from here). With it we can see information relating to all USB devices that we have connected to our computer. For example:

image

Our device is called “DDD Mail Notifier”. If we accede to the information of the device we will see a few important details:

  • Vendor name: “DDD Mail Notifier”
  • Product name: “DDD Mail Notifier”
  • Input Buffer: 9 Bytes
  • Input Buffer: 6 Bytes

image

If we return to the main form, we will see the 6-byte buffer is rendered dynamically with 6 boxes of text in the form. So now we have to see that data are that we need to send to be able to turn on the light.

If we introduce the following information

{00, 00, 00, 00, 00, 00}

and click on the Write button

image

We will see that the LED is still off.

image

If on the other hand to introduce the following information

{01, 00, 00, 00, 00, 00}

and click on the Write button

image

We will see that the red LED illuminates.

image

If you re-enter the following information

{00, 00, 00, 00, 00, 00}

We will see that the LED goes out.

At this point already have made it clear that

  • {00, 00, 00, 00, 00, 00} > = Turn OFF
  • {01, 00, 00, 00, 00, 00} > = Turn ON

In the next post to see how to do the same with C#.

See you later!

Saludos @ Home

El Bruno

image image image

One thought on “[#GADGETS] How to control USB Email Notifier with C# (I)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.