PC SOFT

PROFESSIONAL NEWSGROUPS
WINDEVWEBDEV and WINDEV Mobile

Home → WINDEV 2024 → WD20 connect to USB magnetic card reader
WD20 connect to USB magnetic card reader
Started by Bruce Lee, Jan., 25 2016 9:09 PM - 14 replies
Posted on January, 25 2016 - 9:09 PM
Hello Everyone,

I am working on a magnetic card reader (by USB). It has usb-to-serial converter.

But when I insert it to my computer, the device manager in Windows system only showed it as HID(human interface device)-compliant device, it doesn't show the port number.

The card reader also comes with a programmer manual and DLL. From the programmer manual, it seems that we can send escape code to card reader to write/read card.

However, if I don't have port number, how can I send code to the card reader? (sopen() needs port number. iEscape() looks like doesn't work in this case).

any advice/experience would be highly appreciated!

Thanks!

Bruce
Posted on January, 25 2016 - 9:19 PM
I would first try another computer to see if a virtual serial port does show up there.
I've seen cheap usb-serial converters which don't work on all computers, like my laptop for instance!
Posted on January, 25 2016 - 10:30 PM
Hi Arie,

Sorry about the confusion. The usb-serial converter is software driver, no a cable.

This card reader comes with a software, when I plugged in, and run the software, the software works well. It can do read/write to card. (Even the device manager treats it as HID-compliant device.)

I also tried other computers, it does the same thing.

Also, I am thinking, is there anyway to treat it as a printer? So we can use iEscape() to send command.
Thank you.

Bruce
Posted on January, 26 2016 - 7:57 AM
Hi, Bruce.

The following may or may not be of help in solving your problem but it refers to
trying to control a GPS device designed for serial ports through USB.

You seem to have installed the driver successfully so this is what the article suggests:
1. Open the Device Manager
2. In the displayed list of devices look for "Ports (COM and LPT)"
3. Below that you should see an entry for the virtual COM port created by the USB driver
something like this: Prolific USB to Serial Comm Port (COM4).
I guess "Prolific" is the brand of the device using COM port # 4.

Hope this helps.

- Mike H.
Posted on January, 26 2016 - 10:27 PM
Hi, Mike,

Thank you for your reply.

I did what you said, the device manager didn't find my device.

BTW, could you send the link of "control of a GPS device designed for serial ports through USB"? Maybe I can get some useful information from there.

Thank you.

Bruce
Posted on January, 27 2016 - 3:05 AM
Hi Bruce

Sorry my post didn't help your problem. Interfacing serial devices through USB has been
of interest to me but not urgently.

Anyway, here's the link to the information I posted:
https://tnp.uservoice.com/knowledgebase/articles/172101-determining-the-com-port-of-a-usb-to-serial-adapte
(That's right - there is no "r" at the end)

Here's another link that describes how the interface works
http://plugable.com/2011/07/04/how-to-change-the-com-port-for-a-usb-serial-adapter-on-windows-7

Hope you get some ideas that I might have missed.

- Mike H.
Posted on January, 27 2016 - 11:03 AM
Hi Bruce

What model card reader do you have.

ISO
Posted on January, 27 2016 - 3:44 PM
Thank you!

Bruce
Posted on January, 27 2016 - 3:47 PM
Hi iso,

I am using MSR605 and MSR606.
Thank you.

Bruce
Posted on January, 27 2016 - 9:12 PM
I use Magtek sureswipe readers in HID mode and prefer HID over keyboard wedge as you don't have to manage control focus prior to card swipe. Magtek publishes an ActiveX control to trap events in HID mode from their readers. Pretty easy to setup. Not sure about the MSRs if they have an ActiveX or like facility to trap swipe events. If you can, I would recommend HID over keyboard wedge..
Posted on January, 29 2016 - 12:27 AM
Hi Mr Black,

Thank you for your reply.

Could you tell me what model of Magtek you were using?
Can it write to swipe card?

I don't see the documentation of MSR mention about ActiveX.

Bruce
Posted on January, 29 2016 - 2:53 PM
Right.. Didn't realize you also wanted to write card data..

Here is a link to the readers we use: http://www.newegg.ca/Product/Product.aspx…

For writing, we use Zebra Q3 series card printer with encoder because we also need to print on the card name and ID numbers along with branding graphics.. These things aren't cheap but they work well in the field and are a synch to get working in WD.
Posted on January, 29 2016 - 3:43 PM
Hi Mr Black,

How does Zebra Q3 series work? Does it work like normal printer? Do we send escape code command to it and let it write/print card?

Thank you very much. Your information is very helpful!

Bruce
Posted on January, 29 2016 - 3:54 PM
It works like a normal printer. In the driver, you have the option of using default escape sequences or custom to write track data. We create a report in WD with a static control that has the track data escaped by the same sequences as specified in driver. The static control can be overlaid right on top of the report and the Zebra will omit it as it sees it as track data. Pretty easy... No custom DLL stuff or Zebra SDK needed, unless you need to get the responses back from the printer on success or failure etc, then you would need the SDK.
Posted on March, 02 2023 - 9:57 AM
International, an organization with a vision of making every best study abroad education dream possible, has been in the industry for 15 years now. What started as baby steps in abroad education consulting industry has managed to emerge as a giant leap in Gateway shaping careers for all those deserving and enthusiastic aspirants of all ages, who want to transform themselves into thorough professional in their fields.
https://gateway-international.in/