Highly Appreciated : Image into SIM ( Java Card )

Hi Everybody ,
We would appreciate if anybody could tell us how to insert an image ( ICON ) into SIM. Otherwise reply to the following set of questions.
1) Inserting an image into SIM is possible ?
2) If yes , What is the work around for this ?
thanks in advance ,

There are a few steps you have to do....
The icons are stored in files. There is an example in Gemplus Developer tool. Under the directory Graphics in the SIMs file system, there is a file EF_IMG. This file contains a reference to another file which holds the icon in hex format. There are tools on the web for converting bitmaps to hex format.
If you want to add an icon to Display text you have to append a tlv.
proHdlr.initDisplayText((byte)0x00, DCS_8_BIT_DATA, strings, offset
length);
// Append icon TLV
proHdlr.appendTLV(TAG_ICON_IDENTIFIER, iconQualifier, iconId);
proHdlr.send();
The icon qualifer refers to whether the icon replaces the string or appears with the text.
iconID refers to the record no. in EF_IMG.
I hope this helps.

Similar Messages

  • How to add images into a java application (not applet)

    Hello,
    I am new in java programming. I would like to know how to add images into a java application (not an applet). If i could get an standard example about how to add a image to a java application, I would apreciated it. Any help will be greatly apreciated.
    Thank you,
    Oscar

    Your' better off looking in the java 2d forum.
    package images;
    import java.awt.*;
    import java.awt.image.*;
    import java.io.FileInputStream;
    import javax.imageio.ImageIO;
    import javax.swing.*;
    /** * LogoImage is a class that is used to load images into the program */
    public class LogoImage extends JPanel {
         private BufferedImage image;
         private int factor = 1; /** Creates a new instance of ImagePanel */
         public LogoImage() {
              this(new Dimension(600, 50));
         public LogoImage(Dimension sz) {
              //setBackground(Color.green);      
              setPreferredSize(sz);
         public void setImage(BufferedImage im) {
              image = im;
              if (im != null) {
                   setPreferredSize(
                        new Dimension(image.getWidth(), image.getHeight()));
              } else {
                   setPreferredSize(new Dimension(200, 200));
         public void setImageSizeFactor(int factor) {
              this.factor = factor;
         public void paintComponent(Graphics g) {
              super.paintComponent(g);
              //paint background 
              Graphics2D g2D = (Graphics2D) g;
              //Draw image at its natural size first. 
              if (image != null) {
                   g2D.drawImage(image, null, 0, 0);
         public static LogoImage createImage(String filename) { /* Stream the logo gif file into an image object */
              LogoImage logoImage = new LogoImage();
              BufferedImage image;
              try {
                   FileInputStream fileInput =
                        new FileInputStream("images/" + filename);
                   image = ImageIO.read(fileInput);
                   logoImage =
                        new LogoImage(
                             new Dimension(image.getWidth(), image.getHeight()));
                   fileInput.close();
                   logoImage.setImage(image);
              } catch (Exception e) {
                   System.err.println(e);
              return logoImage;
         public static void main(String[] args) {
              JFrame jf = new JFrame("testImage");
              Container cp = jf.getContentPane();
              cp.add(LogoImage.createImage("logo.gif"), BorderLayout.CENTER);
              jf.setVisible(true);
              jf.pack();
    }Now you can use this class anywhere in your pgram to add a JPanel

  • How to load a java card applet into a java card

    Dear All,
    I am a novice to java card technology..
    I have done some search on how to load a java card applet into a smart card but haven't found a satisfactory answer. I have read about installer.jar and scriptgen tool but I want to load the applet from a java program and not from command line. It would be of great help if somebody can help me out.
    If somebody can share a sample program which load a javacard applet(.CAP file) into a smart card, I will be very thankful.
    I am able to find some client applications which help us send APDU commands and recieve response APDU's to interact with an applet loaded on to the smart card but not application which actually load the applet.
    I have heard of OCF and GP.. some say that OCF technology is outdated and no longer in use.. can somebosy throw some light on this too..
    cheers,
    ganesh

    hi siavash,
    thanks for the quick response.. i checked out GPShell as suggested, it looked like a tool by which one can load an applet on to card and send some sample apdu commands... but I want to load the applet from the code.
    My application should look something like this.. it will be a swing applicaton where I have a drop down with a list of readers, I select the one desired and then click on "LOAD" after inserting a blank java card, at this point my applet which is stored in my DB should get loaded on to the java card. The next step should be to personalize it where I enter the values for the static variables of my applet and click "PERSONALIZE", at this point all these values should be embedded into APDU commands and sent to the java card for processing.
    For achieving this I am yet to find a comprehensive sample or documentation on the net.
    Please help...
    regards,
    ganesh

  • Loading a jpg image into my java 3d scene

    public class Example3D extends JApplet {
        public BranchGroup createSceneGraph() {
         // creating the universe
         BoundingSphere bounds = new BoundingSphere(new Point3d(0.0,0.0,0.0), 100.0);
         BranchGroup objRoot = new BranchGroup();
         TransformGroup mainTG = new TransformGroup();          
         mainTG.setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
         mainTG.setCapability(TransformGroup.ALLOW_TRANSFORM_READ);
         // Now you can add new elements to the mainTG
         ColorCube c2 = new ColorCube(.1);
         mainTG.addChild(c2);
         objRoot.addChild(mainTG);
         // Create the rotate behavior node
         MouseRotate behavior = new MouseRotate();
         behavior.setTransformGroup(mainTG);
         objRoot.addChild(behavior);
         behavior.setSchedulingBounds(bounds);
         // Create the zoom behavior node
         MouseZoom behavior2 = new MouseZoom();
         behavior2.setTransformGroup(mainTG);
         objRoot.addChild(behavior2);
         behavior2.setSchedulingBounds(bounds);
         // Create the translate behavior node
          MouseTranslate behavior3 = new MouseTranslate();
         behavior3.setTransformGroup(mainTG);
         objRoot.addChild(behavior3);
         behavior3.setSchedulingBounds(bounds);
         objRoot.compile();
         return objRoot;
        public Example3D() {
         Container cp = getContentPane();
         cp.setLayout(new BorderLayout());
         Canvas3D c = new Canvas3D(SimpleUniverse.
                          getPreferredConfiguration() );
         cp.add("Center", c);
         BranchGroup scene = createSceneGraph();
         SimpleUniverse u = new SimpleUniverse(c);
         u.getViewingPlatform().setNominalViewingTransform();
         u.addBranchGraph(scene);
        public static void main(String[] args) {       
         new MainFrame(new Example3D(), 512, 512);
    }as a test, i added a cube into the scene and it works fine. but i also want to add a 2d jpg image into the scene too, its called flatTable.jpg
    i hope someone can help me, thanks guys.

    Check out this link:
    http://java3d.j3d.org/tutorials/raw_j3d/chapter1/textures.html
    It should give you enough information about loading textures with java3d.

  • How to save image into blob:java.sql.SQLException: ORA-01465:nvalid hex

    hi all,
    I am trying to save an image (blob) into oracle. When i try this i am getting following error.
                      java.sql.SQLException: ORA-01465: invalid hex number
                             BLOB blob = BLOB.createTemporary(con , false, BLOB.DURATION_SESSION);
                       String dir = "C:\\opt\\temp";
                       File binaryFile = new File(dir+"/"+filename);
                                FileInputStream instream = new FileInputStream(binaryFile);
                          OutputStream outstream = blob.setBinaryStream(1L);
                          int size = blob.getBufferSize();
                          byte[] buffer = new byte[size];
                          int length = -1;
                          while ((length = instream.read(buffer)) != -1)
                            outstream.write(buffer, 0, length);
                          instream.close();
                          outstream.close();
                                  System.out.println("blob:>>>>>>"+blob);
                    String sqlText =
                              "INSERT INTO test_fileupload (filename, blobfile) " +
                              "   VALUES('" + filename + "','" + outstream  + "')";
                          st.executeUpdate(sqlText);
                          con.commit();In the above Insert statement i tried with "blob" insted of "outstream" still same but when i try with the string "3s34se"
    it is inserting into database..
    I am new to blob can any one explain me why is like that.
    Thanq in adv.
    Edited by: Ajayuppalapati on Nov 21, 2008 4:40 PM

    ORA-01465: invalid hex number
    [http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=3&t=012434]
    [http://forums.sun.com/thread.jspa?threadID=261091&forumID=31]

  • Java card simulation

    i have to simulate the java card applet which is doing all crypto functions and
    then i will communicate to it by WTK SATSA using eeprom image of the java card applet..
    i don't have to install it on card, i hv to simulate everything..
    is there a way to do it... or we need a licensed tool for it..
    does WTK 2.5 cref and java card 2.2.2 cref will be able to communicate..
    please help, i need this info. urgently

    Are you referring to a Floppy diskette drive ?

  • How to embed the Images in the java sourse

    How to embed the Images in the java sourse
    The size of the file will be too large while I put the binary code of the image into the java sourse!
    thanks

    You could encrypt them with a private key and then
    decrypt them with a public key.
    Almost had it... public key encryption works the other
    way around... otherwise what's the point of
    encrypting... if the decryption key is public?Spinoza's right. Public key encryption works both ways, but it would be useless in this case to encrypt with the private key. The problem is, how do you package your private key with the application in a way that doesn't allow the user to get it? Encrypt it? :-) I agree that there's no point to this exercize. If users want to screw up the application by editing its image files, let 'em.

  • Does the JCVM comes inside a java card when I buy a java card?

    I am sorry again, but I already understand about card operating system. thanks. could I load JCVM into a java card in the same way I load an applet ?

    How did you create it ? There are instructions on this page for creating a new account (the instructions won't work with existing existing account) without giving credt card details : http://support.apple.com/kb/HT2534
    e.g. if currently logged into an account then log of it, then find a free app in the store, click on its free 'price', and you should then be able to create a new account during the 'buying' process and get 'none' as an option on the payments screen

  • Load file to java card?

    Hi
    Is there any way to load jks file to javacard?
    Please helpme

    How to send a certificate file(.p12 file) into the java card?
    I am trying to send a p12 - certificate file to the smart card using javacard. Is it possible to send a file directly to java card or not? Thanks....

  • Zoom into high resolution image

    Hi,
    Before starting to learn Muse, I've one big need: zooming into high-resolution images.
    I want to show how high the resolution is by letting the viewer zoom in with a loupe (or just scrolling with mouse wheel). I'm not talking about of a slideshow through some crops of the main image, but of an shrink- or grow effect of the image.
    Is this possible to achieve?
    Thanks for your insight,
    Dominique

    Could this be the solution, you are looking for?
    https://creative.adobe.com/addons/products/2406#.U8Jp1mIaySM

  • I want to combine 9 images into one so I can get them printed on a card any help or do I need an inexpensive app?

    I would like to combine 9 images into one so that I can print them on a card. Can I do this in i-photo or do I need an inexpensive app?

    No, iPhoto can't do it.  If you have Pages it can be done there very easily.  Drag all of the photos into a Pages page, resize and arrange as necessary.
    Otherwise you'll need a 3rd party image editor that supports layers.
    Some Image Editors That Support layers:
    Photoshop Elements 11 for Mac - $79
    GraphicConverter - $40
    Rainbow Painter - $30
    Imagerie - $38
    Acorn - $50
    Pixelmator - $60
    Seashore - Free
    GIMP for Mac - Free
    Xee 2.1 - free

  • I cannot seem to load raw images into LR 2.5.  I've been using this for years.  I always load from memory card, but it gives me an unknown error message.  I tried to load from camera, hard drive, & external drive and still will not work.  I checked import

    I cannot seem to load raw images into LR 2.5.  I've been using this for years.  I always load from memory card, but it gives me an unknown error message.  I tried to load from camera, hard drive, & external drive and still will not work.  I checked import menu and nothing has changed.  I loaded the photos onto my tablet and images are fine, so do not feel it is the memory card.  Any thoughts?

    The error message probably said "unsupported or damaged"
    The T3 requires Lightroom 3.4.1 or later. You can either upgrade to a more current version of Lightroom (version 5.6 is the most recent) or you can use the free Adobe DNG Converter to convert the RAWs to DNG, which should import into Lightroom properly.

  • Cut an image into A4 format pages from java

    I have a large image.
    I want to cut it in several A4 format pages.
    How can I cut the image into parts from java?
    Edited by: SnScreen on Apr 30, 2008 2:55 PM

    Then get whatever-you-want-to-have's resolution and calculate the rectangles.
    Don't you think you need to determine the size of a pixel before you can determine the size of a pixelized image?
    This is soooo nonsense. A4 is a paper format, so to get something in A4 you need to print it. Or at least consider printing it. And thus you need to know the printer's resolution. Even if you determine A4 to be say 800x600 pixels, in printer A and printer B with different resolutions, at least one if not both of them will still print it in something different than A4.

  • Writing into file in java card

    hi
    i am new to java card. What i need to do is to write a value in a particular file and read it everytime the mobile is switched on. Can anyone please guide me how do i create this file and read and write into it
    regds
    silverline

    Not really a SQL Developer question. You would be better over in the SQL and PL/SQL forum.
    You don't say what DBMS version you are using but if it is 10g or later, you don't need to restart the database to enable directories to write to.
    The utl_file_dir initialisation setting should no longer be used. Use CREATE DIRECTORY instead.

  • Problem in loading applet into java card.

    Hi all,
    I have developed an applet using java card development kit 2.2.2 and JDK1.5. The cap file is generated successfully. Am using gpshell to load applet into the card but am getting an error saying "Error : load_applet() returns 0x80206A80 (6A80: Wrong data / Incorrect values in command data.)" . Can anyone please tell me where am wrong. My install file contains :
    mode_211
    enable_trace
    establish_context
    card_connect
    select -AID a0000000030000
    open_sc -security 1 -keyind 0 -keyver 0 -mac_key 404142434445464748494a4b4c4d4e4f -enc_key 404142434445464748494a4b4c4d4e4f // Open secure channel
    delete -AID a00000006203010c0101
    delete -AID a00000006203010c01
    delete -AID a00000006203010c0101
    install -file wallet.cap -nvCodeLimit 28500 -nvDataLimit 28500 -instParam 00 -priv 2
    card_disconnect
    release_context
    and when i execute gpshell install.txt, i get error like :
    mode_211
    enable_trace
    establish_context
    card_connect
    select -AID a0000000030000
    Command --> 00A4040007A0000000030000
    Wrapped command --> 00A4040007A0000000030000
    Response <-- 6F658408A000000003000000A5599F6501FF9F6E06405163452900734A06072A864886FC6B01600C060A2A864886FC6B02020101630906072A864886FC6B03640B06092A864886FC6B040215650B06092B8510864864020103660C060A2B060104012A026E01029000
    open_sc -security 1 -keyind 0 -keyver 0 -mac_key 404142434445464748494a4b4c4d4e4f -enc_key 404142434445464748494a4b4c4d4e4f // Open secure channel
    Command --> 80CA006600
    Wrapped command --> 80CA006600
    Response <-- 664C734A06072A864886FC6B01600C060A2A864886FC6B02020101630906072A864886FC6B03640B06092A864886FC6B040215650B06092B8510864864020103660C060A2B060104012A026E01029000
    Command --> 8050000008F156D9048BF4FB6800
    Wrapped command --> 8050000008F156D9048BF4FB6800
    Response <-- 00008247040433914208FF020052DF76EF50F6457F4F16E031638B009000
    Command --> 84820100109D59E7CE033B4A5B70115EB7CA3F523C
    Wrapped command --> 84820100109D59E7CE033B4A5B70115EB7CA3F523C
    Response <-- 9000
    delete -AID a00000006203010c0101
    Command --> 80E400800C4F0AA00000006203010C010100
    Wrapped command --> 84E40080144F0AA00000006203010C01011C9450FF5E3DCB3800
    Response <-- 6A88
    delete_applet() returns 0x80206A88 (6A88: Referenced data not found.)
    delete -AID a00000006203010c01
    Command --> 80E400800B4F09A00000006203010C0100
    Wrapped command --> 84E40080134F09A00000006203010C013421B120E65613F100
    Response <-- 009000
    delete -AID a00000006203010c0101
    Command --> 80E400800C4F0AA00000006203010C010100
    Wrapped command --> 84E40080144F0AA00000006203010C010136D28BC08D59D9FA00
    Response <-- 6A88
    delete_applet() returns 0x80206A88 (6A88: Referenced data not found.)
    install -file wallet.cap -nvCodeLimit 28500 -nvDataLimit 28500 -instParam 00 -priv 2
    Command --> 80E602002009A00000006203010C0608A000000003000000000AEF08C6026F60C7026F540000
    Wrapped command --> 84E602002809A00000006203010C0608A000000003000000000AEF08C6026F60C7026F54005A411C50F04D651900
    Response <-- 009000
    Command --> 80E80000EFC48203BD010013DECAFFED010202000109A00000006203010C0602001F0013001F000000150062001201CB000A003C000700D600000000000002000004001502030107A0000000620101000107A000000062000106001200800302000104040000005CFFFF004F00640701CB000543188C0003188F00133D0610088C00028700191E2529041E160441044131191E2529051E160541044131191E252906AD00191E044116068B0004188B00057A05308F00063D181D1E8C00073B7A0110AD008B00086104037804780110AD008B00097A0221198B000A2D198B000B60101A042510A46B037A116E008D000C1A032510
    Wrapped command --> 84E80000F7C48203BD010013DECAFFED010202000109A00000006203010C0602001F0013001F000000150062001201CB000A003C000700D600000000000002000004001502030107A0000000620101000107A000000062000106001200800302000104040000005CFFFF004F00640701CB000543188C0003188F00133D0610088C00028700191E2529041E160441044131191E2529051E160541044131191E252906AD00191E044116068B0004188B00057A05308F00063D181D1E8C00073B7A0110AD008B00086104037804780110AD008B00097A0221198B000A2D198B000B60101A042510A46B037A116E008D000C1A032510CCBBB987BED1F686
    Response <-- 6A80
    load_applet() returns 0x80206A80 (6A80: Wrong data / Incorrect values in command data.)
    Thanks in advance

    Hi all,
    Sorry above i forgot to mention the java card am using. It is JCOP21 and in its datasheet its mentioned that it specification needed are javacard development kit 2.2.1, is that may be the reason for this error?
    Thanks in advance

Maybe you are looking for

  • How do i sync my contacts and calendar to PC? what program do I use??

    i am a new iphone 4 user.  what FREE software should i use to sync contacts and calendar?

  • How to attach XML file in the response of Web Services

    Hi I am new to the WEB SERVICE. this my requirement. I need to make a class file a web service. and i need to get data from the data base and attach it in the response. I need to use SOAP MEssaging for this. so how to call the service from the JSP an

  • Problems with a Powermac G4 and OS9

    Hi I'm new to the forum and new to Macs so please excuse me if my questions seem a little dumb. I've just obtained a PowerMac G4 with OS9 that used to belong to a school. The school wiped out all their work but I'm wondering if they've also wiped off

  • SQL Developer 2.1.0.63.73 exports DATE as TIMESTAMP

    I believe this is a bug. When I export a table to an XLS file, the values contained in DATE columns are saved as if they were TIMESTAMP: eg. 31-DEC-09 12:00:00 AM would export as 31-DEC-09 12.00.00.000000000 AM Not really a huge deal until you try to

  • Limit the filesize upload and resize a blob image in a report

    I'd like to know how to do both.. I have a file browse that uploads images to my application. It's called P34_IMG1. I would like to limit the file dimensions to a maximum of 200 x 300 px (but it can be less) and have a limit of 1MB in filesize. As we