DataWedge API - SET_CONFIG

Hello,

I'm programming communication between my android application and DataWedge API. Everything is fine, except one thing. I want to create new DataWedge profile using SET_CONFIG API and I'm unable to create more than one PLUGIN_CONFIG section with profile setting within one intent. If I create profile with one PLUGIN_CONFIG, profile is successfully created with my setting. If I include more than one PLUGIN_CONFIG, profile is created, but with default setting.

Code, which isn't working, is below -

bMain.putParcelableArray("PLUGIN_CONFIG", new Bundle[]{bIKeyStrokeConfig, bBarcodeConfig, bIntentConfig});

Code, which is working, is below -

bMain.putBundle("PLUGIN_CONFIG", bBarcodeConfig);

What am I doing wrong?

Thank you for your response.

Anonymous (not verified)
Hi Michal,For DataWedge 6.5

Hi Michal,

For DataWedge 6.5 and below, each plugin being set (in your case barcode, intent and keystroke) needs to be set separately, I have an example in my earlier post about using EMDK data capture profiles,   which sets both the barcode and intent plugins separately.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Michal Prikryl
Hi Darryn,thank you for your

Hi Darryn,

thank you for your response. I forgot to mention, that I am using DataWedge 6.6.50 on TC75x. For now I'm creating profile separately, like you wrote, but I think it would be better to that in single one intent, but I don't know, what am I doing wrong.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Anonymous (not verified)
I'm not sure on that one... I

I'm not sure on that one... I recommend looking at the returned status from Intent Result Codes - Zebra Technologies TechDocs  or turning on DataWedge logging and looking in logcat to see if there are any messages.  putParcelableArray sounds sensible to me but none of the examples set more than one plugin at a time.  I'm afraid it's not something I have tried to do myself... get back to me if it still does not work and I will ask internally.

Thanks.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Michal Prikryl
I check returned status, as

I check returned status, as you recommend, and returned status is SUCCESS. New profile is created, but without any plugin configuration - only default setting.

Here is my code, maybe it can help you - SET_CONFIG bundle · GitHub

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Anonymous (not verified)
I asked the internal team,

I asked the internal team, they said they are going to get back to me (hopefully with an example)

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Michal Prikryl
Thank very much.

Thank very much.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Anonymous (not verified)
Hi,I got an answer on this,

Hi,

I got an answer on this, please specify the different plugins in an ArrayList:

   ArrayList<Bundle> pluginConfig = new ArrayList<Bundle>();

   Bundle bConfig = new Bundle();

   Bundle bConfigADF = new Bundle();

//  Populate the two configs

  pluginConfig.add(bConfig);

  pluginConfig.add(bConfigADF);

  configBundle.putParcelableArrayList("PLUGIN_CONFIG", pluginConfig);

I have copy / pasted the above code from a System Test, test application, please let me know if this resolves your issue or have further questions.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Michal Prikryl
Thank you Darryn, everything

Thank you Darryn, everything works as I expect.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Log in to post comments