Barcode Problem with JAVA

Barcode Problem with JAVA

Hello,
I've done this program:

private static BarcodeReader barcodeReader;

barcodeReader = new BarcodeReader();
barcodeReader.reserveDevice(14000);
BarcodeType type = BarcodeType.Code128;
BarcodeTypes types = new BarcodeTypes();
types.add(type);
barcodeReader.setScanTypes(types);
barcodeReader.startScan();
barcodeReader.waitForBarcode(10000);
Barcodes barcodes = barcodeReader.getBarcodes();
Iterator iterator = barcodes.iterator();
while (iterator.hasNext()) {
Barcode barcode = (Barcode) iterator.next();
//Get the value of current barcode
String value = barcode.getValue();
System.out.println(" Scanned value : " + value);
}

barcodeReader.releaseDevice();

But my barcode doesn't work. The red light doesn't appear (same with the BarCodeDemoJava) and I have a return value 0128. If I use an oser barcode type I have a timeout.
When I press the barcode physical button it's the same. I've done an update of the SDK (2.0.1) and now the barcode doesn't shine...

Can you give me some helps please.
Thanks
Ludo

I 've find the problem
The 2.0.1 SDK version is not compatible with the Motion C5. With the 2.0 SDK version it works

publicaciones de 2 / 0 nuevos
Último envío
Para obtener más información sobre las optimizaciones del compilador, consulte el aviso sobre la optimización.

Quoting - ludofrommars
Hello,
I've done this program:

private static BarcodeReader barcodeReader;

barcodeReader = new BarcodeReader();
barcodeReader.reserveDevice(14000);
BarcodeType type = BarcodeType.Code128;
BarcodeTypes types = new BarcodeTypes();
types.add(type);
barcodeReader.setScanTypes(types);
barcodeReader.startScan();
barcodeReader.waitForBarcode(10000);
Barcodes barcodes = barcodeReader.getBarcodes();
Iterator iterator = barcodes.iterator();
while (iterator.hasNext()) {
Barcode barcode = (Barcode) iterator.next();
//Get the value of current barcode
String value = barcode.getValue();
System.out.println(" Scanned value : " + value);
}

barcodeReader.releaseDevice();

But my barcode doesn't work. The red light doesn't appear (same with the BarCodeDemoJava) and I have a return value 0128. If I use an oser barcode type I have a timeout.
When I press the barcode physical button it's the same. I've done an update of the SDK (2.0.1) and now the barcode doesn't shine...

Can you give me some helps please.
Thanks
Ludo

I 've find the problem
The 2.0.1 SDK version is not compatible with the Motion C5. With the 2.0 SDK version it works

Ludo,

Sorry but I am not clear on you question.

You should not be installing the SDK on the C5 is should be used only on a development machine.

Your SDK version and the PD version (installed on the C5) need to be the same rev. If you are using a 2.01 SDK on your development machine you need to have a 2.01 version PD installed on the C5.

If you have installed the SDK on the C5 please remove it using add remove programs in control pannel.

Then install the PD that matches the SDK that you are using.

If this is not your question please let me know how I can help.

John C

Inicie sesión para dejar un comentario.