0 Replies Latest reply on Mar 29, 2016 5:58 PM by Rosalyn Manrique

    Print and Align images on Datamax-Android

    Rosalyn Manrique

      Hi everyone!

       

      Hope someone could help me with this issue:

       

      I'm trying to print with a Datamax O'Neil printer, microflash 4te model through an Android application. I finally could print an image but it only does for 4 inches and I cannot center it. The code is:

       

      BitmapFactory.Options options = new BitmapFactory.Options();
      options.inScaled = true;
      options.inDither = false;
      Bitmap anImage = BitmapFactory.decodeResource(getResources(), R.drawable.logo, options);

      And the other issue is that It doesn't print spanish characters, even though I specified it to use the Spain set:

       

      DocumentLP docLP = new DocumentLP(“!”);

      byte[] printData = new byte[]{0};

      docLP.setCharacterRemap(DocumentLP.CharacterSet.Spain);
      docLP.writeText("Español sí es");
      printData = docLP.getDocumentData();
      printerConnection.write(printData);

       

      Thank you in advance.