Getting supported character sets of an OPOS printer

It is good to return to this blog after several years of not blogging anything.
I have been working on the Dynamics AX / Retail system for sometime, particularly on the 
hardware related to Point of Sale software. You know, the cash drawers, barcode scanners, printers etc.

Recently someone has asked me, when configuring the retail module in AX, particularly the hardware profile, 
how to know exactly what character set to use for a particular OPOS device. Let me address that here. 

When speaking about OPOS, there are several layers of components. Your application uses
what is called Common Control Objects. The common control objects call the service objects.
The following picture is lifted directly from the UPOS specification document. 




Now, the service objects are the controls or "software" provided by a particular vendor of particular device.

The common control objects are vendor independent and are generally available for use at

The standard configuration of the Service Objects is through the  windows registry.

Becasue the service objects are "generally" 32 bit COM objects you need to use the 32 bit regedt32 to view the
registry configuration for service objects.

HKEY_LOCAL_MACHINE\Software there should be a key called OLEforRetail
Under that key there should be another key called  ServiceOPOS
Under that key, there are entries for individual device classes such as CashDrawer, LineDisplay, POSPrinter etc.
These are the device classes. Under each device class you will find the manufacturer specific entries

Under that you can find the COM prog id of the service object. Once you find the service object you can write
a simple script to create and call methods on the service object and even interact with that device.

You don't even need visual studio - just using note pad, you can write simple 2 or 3 line VB Script 
Set so = CreateObject("progid")
WScript.echo so.CharacterSetList

That should give you the list of character sets supported and you can 
then use the correct character set in the configuration of AX Hardware profile. 

Next, in a series of posts, I want to show you how to write a fake Printer, Cash Register 
or any OPOS fake or mock device so you can test your software with these fake
devices without having to run around finding a piece of OPOS hardware to test
your POS software. Stay tuned...