J2ME Mobile Barcode Recognition

Dear friends,
Does anyone know how to write Barcode Reader by J2ME for scanning EAN13?? Or does anyone get the source code of J2ME Barcode Reader?
Thanks a lot.
Regards,
Alan

I'm the same situation too,
I posted and found something on another topic:
http://forum.java.sun.com/thread.jspa?threadID=698351
I hope it's useful for you.

Similar Messages

  • J2me Mobile client calling method which return byte[] java.rmi.MarshalExcep

    J2me Mobile client calling method which return byte[]
    java.rmi.MarshalException: Expected Byte, received: SGVsbG8gV29ybGQ=
    WebService1_Stub ws=new WebService1_Stub();
    try {
    String s=ws.getStringHelloWorld();// works fine
    byte s[]=ws.helloWorld(); // error java.rmi.MarshalException: Expected Byte, received: SGVsbG8gV29ybGQ=
    }catch(Expception e){
    ex.printStackTrace();
    }This same ws working fine in java standalone application please guide me what can be a problem ??
    Regards
    Haroon Idrees

    clear your app. server logs ( or make copies of them if will you need them) and redo the whole process. check out the logs and you should see some reason for this. i do not know if Borland's logs will turn out helpful, but it did help me out in certain other situations.

  • How do I implement barcode recognition or how is it done?

    Hi
    Having just posted this message in the cryptography forums, I thought this might be more appropriate here and I might get a few more repsonces. However, I do appologise if I have posted this in the wrong forum, as I am a little unsure where this really belongs.
    I am currently working on a software decoder that will be able to take images similar to barcodes and decode them. I already have the encoder working and I am able to create the encrypted image, but am struggling to create a reliable decoder that can analyse the image and decode it.
    The decoder I have at present works fine if the image being decoded is EXACTLY the same image produced from the encoder (i.e. image has not been altered e.g. stretched or resized), since my decoder knows where to find pixels, but if one pixel is off by so much as one pixel location then the program will fail to decode. As you can guess this method is far from elegant, so I really want to know if anyone has any ideas or experience on algorithms or anything I should be looking at to improve my decoder. I have searched the net and found a couple of programs that does image recognition, and can pick out barcode etc and decode them. The third link below is particularly good, as it shows the program is capable of decoding a photo of a barcode - it is able to pick out the barcode and then decode it.
    Here are screenshots from 2 applications.
    http://www.pdf417kit.com/screenshot.jpg
    http://www.intelcom.ru/img/example/prngrow2.bmp
    http://www.snapfish.co.uk/slideshow/AlbumID=19811658/PictureID=430558628/t_=20428522
    Here is an image of some encoded data generated by my encoder:
    http://www.snapfish.co.uk/slideshow/AlbumID=19811658/PictureID=430558627/t_=20428522
    Anyone have any tips as to how I can make my decoder more flexible?
    I don�t know much about the Java advanced imaging stuff, so some good online tutorials as to what I should need to know to do what I want to do would be good.
    Again sorry if I am not very clear with my problem, I will try to answer any questions you may have.
    Thanks

    Did you notice the difference between your image and theirs. Their image has a coordinate grid. This coordinate grid can be used to determine size, location of pixels, etc...
    If you add a grid, when you process the image, find the grid, then find the coordinate markings, then find the pixels in relation to these coordinate marking creating an internal buffer of the image.
    ie: have 0=white 1=black 2=grid 3=coordinate marking and make an internall representation of your image
    011002300000
    001002201000
    011102300010
    323232232323
    222222222222
    001002310000
    000102200100
    010002301000
    Just an idea, but look into the coordinate grid it may be the key to why they can process their image.
    DeltaCoder

  • Persistence of data in J2ME mobile device using RMS

    Hi. Just want to ensure that RMS can let us store some values in the mobile device. I'm using emulator to try this out. Everytime i close the emulator, the data stored in the RecordStore's gone. How about in real mobile device?
    For some reasons, my jad and jar can't be installed in my Nokia 6210. It keeps giving me "Invalid Jar file" error.
    So, my main question is whether RMS really stores the value in the mobile device and can be retrieved everytime that MIDlet app's run again.
    The other question is why is it that my jar can't be installed in my Nokia 6210? I just built it with NetBean with J2ME and it could be run on the emulator perfectly.
    Thanks a lot.

    Hi. For the installation to my phone, i have solved it by changing my app's MIDP version 2.1 to 2.0.
    For the persistence of data part, i changed the Storage->"Storage Root Directory" to "\save" in Preferences of SJWTK and re-run my app on the emulator and my phone. However, it seems that the record store's data is not persisted. So, i assume it has something to do with my code. My code is as below. Can anyone give me some clues on what i have done wrong? Thanks.
    public TheConstructor(MIDlet midlet, Form form, int partnerId){
         try
          // The second parameter indicates that the record store
          // should be created if it does not exist
            rs = RecordStore.openRecordStore(REC_STORE_NAME, true );
            if (rs.getNumRecords() == 0) {
                RecordIdParam = getAdsParam();
                if (clientIdParam.length > 0) {
                    clientId = RecordIdParam;
                    writeRecord(RecordIdParam);
                    readRecords();
                    closeRecStore();  // Close record sto
            else {
                readRecords();
                closeRecStore();  // Close
         catch (Exception e)
          db(e.toString());
    private void db(String str)
        System.err.println("Msg: " + str);
      public void closeRecStore()
        try
          rs.closeRecordStore();
        catch (Exception e)
          db(e.toString());
       public void writeRecord(String str)
        byte[] rec = str.getBytes();
        try
          rs.addRecord(rec, 0, rec.length);
        catch (Exception e)
          db(e.toString());
      public void readRecords()
        try
          // Intentionally make this too small to test code below
          byte[] recData = new byte[5];
          int len;
          System.out.println("num of records is " + rs.getNumRecords());
          for (int i = 1; i <= rs.getNumRecords(); i++)
            if (rs.getRecordSize(i) > recData.length)
              recData = new byte[rs.getRecordSize(i)];
            len = rs.getRecord(i, recData, 0);
            RecordIdParam = recData;
        catch (Exception e)
          db(e.toString());
      }

  • Problems calling image on J2ME mobile phone screen

    I have an image size (160kb) of certain size and width. I am calling this image onto a mobile phone screen (j2me) and upon calling this image, I am getting OutOfMemoryException. Sometimes, I do get the partial image displayed on the phone screen.
    My requirement is either reduce the size of the image or avoid the OutOfMemoryException. Does anyone has gone through the similar situation. Any ideas on how to solve this problem is greatly appreciated.
    Thanks,
    coolers.

    Thanks for the response. I posted it there.
    Here is the link
    http://forum.java.sun.com/thread.jspa?threadID=682766
    Thanks,
    Coolers

  • How is barcode recognition done?

    Hi
    Sorry if I have posted this in the wrong forum, as I am a little unsure where this really belongs.
    I am currently working on a software decoder that will be able to take images similar to barcodes and decode them. I already have the encoder working and I am able to create the encrypted image, but am strugling to create a reliable decoder that can analyse an the image and decode it.
    The decoder I have at present works fine if the image being decoded is EXACTLY the same image produced from the encoder (i.e. image has not been altered e.g. stretched or resized), since my decoder knows where to find pixels, but if one pixel is off by so much as one pixel location then the program will fail to decode. As you can gess this method is far from elegant, so I am really wanting to know if anyone has any ideas or experience on algorithms or anything I should be looking at to improve my decoder. I have searched the net and found a couple of programs that does image recognition, and can pick out barcode etc and decode them. The third link below is particularly good, as it shows the program is capable of decoding a photo of a barcode - it is able to pick out the barcode and then decode it.
    Here are screenshots from 2 applications.
    http://www.pdf417kit.com/screenshot.jpg
    http://www.intelcom.ru/img/example/prngrow2.bmp
    http://www.snapfish.co.uk/slideshow/AlbumID=19811658/PictureID=430558628/t_=20428522
    Here is an image of some encoded data generated by my encoder:
    http://www.snapfish.co.uk/slideshow/AlbumID=19811658/PictureID=430558627/t_=20428522
    Anyone have any tips as to how I can make my decoder more flexible?
    I dont know much about the Java advanced imaging stuff, so some good online tutorials as to what I should need to know to do what I want to do would be good.
    again sorry if I am not very clear with my problem, I will try to answer any questions you may have.
    thanks

    What's a bar code? It's a rectangular striped area. So you can defocus your picture, locate a small rectangular, gray area, and you have located the bar code.
    You can try finding the small rectangle, correct scale and orientation, make its contrast better (to have a image in white and black) and draw some lines in the bar code (like a laser scanner) trying to find a pattern with stripes.
    When you find a rectangular striped area, you can try interpreting the stripes using all algorithms that your program is able to handle. When you read something that makes sense (for instance, several of the bar codes have error detection and correction codes), you have the correct bar code.

  • Web Dynpro Java: Mobile Device Recognition Problem

    Hi, all!
    I' m building an WD App with different UIs for Mobile and Desktop usage and therefore try to get a com.sap.mobile.clientinfo.ClientInfo Object via:
    ClientInfoFactory clientInfoFactory = ClientInfoFactory.newInstance();
              ClientInfo clientInfo = clientInfoFactory.newClientInfo();
              IWDProtocolAdapter protAdapter = WDProtocolAdapter.getProtocolAdapter();
              IWDRequest request = protAdapter.getRequestObject();
              clientInfo.load(request);
    For this I added DC "com.sap.mobile.clientinfo" out of SAP_JTECHS as Used DC.
    When starting the Application, I receive the following error:
    java.lang.NoClassDefFoundError: com/sap/mobile/clientinfo/ClientInfoFactory
         at at.tmobile.proj.intern.vis4.start.StartCompInterface.getClientInfo(StartCompInterface.java:156)
         at at.tmobile.proj.intern.vis4.start.StartCompInterface.wdDoInit(StartCompInterface.java:112)
         at at.tmobile.proj.intern.vis4.start.wdp.InternalStartCompInterface.wdDoInit(InternalStartCompInterface.java:112)
         at com.sap.tc.webdynpro.progmodel.generation.DelegatingCustomController.doInit(DelegatingCustomController.java:73)
         at com.sap.tc.webdynpro.progmodel.controller.Controller.initController(Controller.java:215)
         at com.sap.tc.webdynpro.progmodel.controller.Controller.init(Controller.java:200)
         at com.sap.tc.webdynpro.progmodel.controller.Component.getCustomControllerInternal(Component.java:448)
         at com.sap.tc.webdynpro.progmodel.components.ComponentUsage.createComponentInternal(ComponentUsage.java:167)
         at com.sap.tc.webdynpro.progmodel.components.ComponentUsage.createComponent(ComponentUsage.java:116)
         at com.sap.tc.webdynpro.progmodel.components.ComponentUsage.createInstanceIfDemanded(ComponentUsage.java:728)
         at com.sap.tc.webdynpro.progmodel.components.ComponentUsage.getImplementingInterfaceViewInfo(ComponentUsage.java:403)
         at com.sap.tc.webdynpro.clientserver.cal.ClientComponent.getViewManagerFor(ClientComponent.java:304)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.createUninitializedView(ViewManager.java:619)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.getView(ViewManager.java:685)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.bind(ViewManager.java:546)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.getView(ViewManager.java:715)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.bind(ViewManager.java:546)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.getView(ViewManager.java:715)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.bindRoot(ViewManager.java:570)
         at com.sap.tc.webdynpro.progmodel.view.ViewManager.init(ViewManager.java:155)
         at com.sap.tc.webdynpro.clientserver.window.WebDynproWindow.doOpen(WebDynproWindow.java:300)
         at com.sap.tc.webdynpro.clientserver.window.ApplicationWindow.open(ApplicationWindow.java:204)
         at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.init(ClientApplication.java:364)
         at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.initApplication(ApplicationSession.java:700)
         at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:269)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessingStandalone(ClientSession.java:707)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessing(ClientSession.java:661)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:229)
         at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:152)
         at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:62)
         at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doGet(DispatcherServlet.java:46)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:390)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:264)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:347)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:325)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:887)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:241)
         at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
         at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:148)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
         at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Im a referencing the wrong DC in the wrong way? Any hints more than appreciated!
    Regards,
    Thoams

    Thomas,
    In your WD project right-click on project node, open "Properties", switch to "WebDynpro References" then select "Library References". Add here library <b>com.sap.mobile.clientinfo</b>
    If you add it in wrong place before, then remove it. If you add run-time dependecy for used DC, then remove it (just left build-time dependency).
    To find corresponding library/service in future, run Visual Administrator, find your service/library in Services/Libraries tree and copy the value of <b>Service Name</b> or <b>Library Name</b> respectively.
    Valery Silaev
    SaM Solutions
    http://www.sam-solutions.net

  • J2me mobile application

    hi
    i am planning of making a client server program between pc and cellphones using internet connection(wifi), is it possible?? if so
    what are the tools needed in order to create this??

    One tool would be "enough common sense not to post pointless threads all around".

  • SSO-Logon from mobile device - create logon ticket from WebDynpro for Java

    Hi Experts,
    I'm developing WebDynpro-JAVA application for some warehouse stuff  (runs on a portal system, clients are mobile barcode-scanners with Windows mobile 5.0). JCOs from the portal system to the R/3-backend are confirgured for SSO with Logon-tickets and portal uses LDAP for authentication against a Windows-ADS.
    This works so far ... but my problem is the standard Logon-screen, which is nearly unusable on the mobile device (screen size, layout, etc.). Is there any solution to create logon-tickets directly from the WebDynpro application (using something from com.sap.engine.interfaces.security.auth or similar ?) or any chance to have a special logon screen for mobile devices (parameter sap-wd-client=Pie03Client is ignored for the logon screen).
    Thanks in advance.
    regards,
    Hendrik

    Hi Henrik,
    Did you find the solution to your problem ?
    I'm facing the same issue, so I'd be pleased to know the solution!
    Regards
    Stekam

  • BUTTON IS NOT WORKING IN MOBILE DEVICE

    Dear All,
    I DEVELOPED A MODULE POOL PROGRAM WITH 2 SCREEN.
    WHEN I CLICK NEXT BUTTON IT WILL CALL 2ND SCREEN.
    ITS WORKING FINE IN SAP.
    NOW I AM CREATING URL FOR THIS PROGRAM AND BY ITS I AM CALLING THIS PROGRAM IN MOBILE / BARCODE SCANNER  DEVICE.
    INPUT SCREEN IS COMING WHEN I CLICK NEXT BUTTON ITS NOT CALLING 2ND SCREEN.
    Pls suggest.
    moosa

    CLOSED

  • Loading j2me images

    Hi all,
    I have a web service through which i am sending a image to j2me mobile device to display on it. when i try to load the image the image doesn't display correctly.
    Please guide me on how do i load the images like jpg, gif, and png images to j2me
    Also i am receiving j2me images are in byte array form the webservice
    Abdul Khaliq

    u can try this code
    <code>
    HttpConnection c = null;
    DataInputStream is = null;
    DataOutputStream os = null;
    try
    String downloadURL = "http://a.com/a.png";
    System.out.println("download url is "+downloadURL);
    c = (HttpConnection) Connector.open(downloadURL);
    c.setRequestMethod(HttpConnection.GET);
    int resCode = c.getResponseCode(); //this will open connection and send request
    is = new DataInputStream(c.openInputStream());
    ByteArrayOutputStream baos = new ByteArrayOutputStream();
    os = new DataOutputStream(baos);
    int i=0,v;
    byte []data = new byte[2048];
    while ((v = is.read(data)) >0 && downloading)
    i += v;
    os.write(data,0,v);
    os.flush();
    is.close();
    os.close();
    baos.close();
    c.close();
    byte []pngData = baos.toByteArray();
    Image image = Image.createImage(pngData, 0, pngData.length);
    try{
    midlet.imageForm.deleteAll();/// image form is a simple form
    }catch(Exception e){}
    midlet.imageForm.append(image);
    midlet.getDisplay().setCurrent(midlet.imageForm);
    }catch(Exception ex)
    </code>

  • Playing a mp3 audio file in j2me

    Hi
    I need a code to play a mp3 file in j2me

    Hi ,
    Well, you can try going through the [The J2ME Mobile Media API.|http://developers.sun.com/mobility/midp/articles/mmapioverview/] It has all the information on how can you make your application to run audio or video files. It also have the example to understand better.
    One more example for the same you can find in WTK apps list where it gives to demo for playing media files, both audio and video.
    Edited by: hiteshrawat on Jun 12, 2009 12:14 AM

  • Database on J2ME

    Hi all . I'm student from Mongolia . I have no experience with J2ME , but have some with Java2 . And going to do project on J2ME mobile phone application (The dictionary application).
    And I am planning to manage independent database on the phone . Is this possible to use database that it worked independent , just on the phone ? If yes , how can I manage database ? Please help me !
    Please prompt me about this . Thanks in advance .
    Sabit Bazar , Mongolia .

    Hello Sabit,
    Check the tips below. They may help..
    Connecting to databases like Mysql, SQL Server or Oracle on J2ME devices
    http://www.java-tips.org/content/view/356/73/
    An example of use of RMS for storing persistent data
    http://www.java-tips.org/content/view/529/73/
    How to store/retrieve image in/from RMS
    http://www.java-tips.org/content/view/1312/73/

  • Authentication in j2me..

    Hi all,
    I would need some info on how to authenticate user while workin with j2me mobile applications...Thanks

    The bouncy castle api might help you with that: http://www.bouncycastle.org/
    Though maybe, basic base64 auth is much easyer to do..

  • The installer encountered errors before iTunes could be configured errors occurred during installation your system has not been modified please run the installer again or click finish to exit.

    I've been having trouble with my computer ever since I turned it back on after leaving for six months and now every time I try to install certain things or update things it says there's an error that occurs and it's keeping me from downloading stuff like Google Chrome and iTunes. Does anyone have any suggestions? I'm running windows xp 32 bit.

    I am having a similar problem, except I'm running Vista 32 bit. I haven't had issues with any other software but iTunes is giving me no end of trouble. The problem started when I tried updating to the .4 version of iTunes when it first came out. I could still use the program and transfer data from iTunes to my iPhone so I didn't worry too much about it. Recently though I wanted to upgrade my iPhone software but received a message saying I need to upgrade my iTunes before I can upgrade my iPhone. After a few tries iTunes won't even RECOGNIZE my iPhone.  I keep getting an error that the mobile device recognition isn't working.
    I tried uninstalling iTunes and installing the new download directly from the iTunes website. I used Chrome, Mozilla, and Internet Explorer with the same results. I think my computer may be corrupted and I need to wipe the harddrive. I really don't want to get to that point but if someone smarter then me doesn't have answer soon I think that is my only option.

Maybe you are looking for