How to access hardware?

Hi there,
Could someone please tell me if it is possible to access hardware ports with java (i.e. like inport() and outport() in c)?
Is there any separate API available? (-> NOT the COMM API!!!)
If not, do i have to use JNI?
Concluding, is there any commercial library that allows you to do this in java?
Thanks in advance,
John

Hi again!
I choosed to go on and use the JNI ability of java.
I downloaded Borland c++ 5.5.1 which is a free 32-bit command line compiler for c++. I tried the "hello world" example in the JNI tutorial page and it worked great. However, when i tried to compile some code that contained the functions 'inportb' and 'outportb' (i.e. which is the reason of why i am using JNI) it tells me that these are undefined even if i imported the correct header files!
After some search i find out that borland removed these functions for security reasons with windows! (WHAT!?)
To conclude, my question is:
Does anyone know any free c++ compiler that is able to generate .dll files and also supports the functions 'inportb' and 'outportb'
Thanks a million times!
John

Similar Messages

  • Imac mid 2011 os10.7.5 can't access hardware test.  could months ago, now no.

    using alt+D can get (wifi only) connection to page with world map in circle, below "connecting internet recovery" and statement the "this may take a while".
    Gives no option for ethernet , showing only wifi accounts even when wifi is turned off on compu.
    After waiting quite a while an exclamation point covers circle with world and below says:  apple.com/support -2002d - going there find nothing applicable to case.
    I was able to access with no problem several times up til last couple of months.  Can any one please advise how to access hardware test?????
    Many thanks.
    Carmenoax

    using alt+D can get (wifi only) connection to page with world map in circle, below "connecting internet recovery" and statement the "this may take a while".
    Gives no option for ethernet , showing only wifi accounts even when wifi is turned off on compu.
    After waiting quite a while an exclamation point covers circle with world and below says:  apple.com/support -2002d - going there find nothing applicable to case.
    I was able to access with no problem several times up til last couple of months.  Can any one please advise how to access hardware test?????
    Many thanks.
    Carmenoax

  • How to access performance counter directly?

    What I am going to do is programming with hardware performace counters of UltraSPARC T2+ processors in Solaris 10. I programmed a loadable syscall to invoke the hv_niagara_getperf or ultra_getpic, trying to get the counters' data. But there just comes a panic, unresponsive without any text notice, and then reset. I don't know what's the real causes because I am not very familiar with SUN servers.
    I did some experiments both in primary domain and logical domain. In primary domain, both hv_niagara_getperf and ultra_getpic lead to panic, and in logical domain, hv_niagara_getperf return the ENOACCESS status and ultra_getpic lead to panic.
    My question are:
    1, If there is some initialization works or privilege settings to do to prevent panic?
    2, If Logical Domain can be set privileges to access hardware performace counters? (I read the Hypervisor api manuals and it says only one domain can access performance counters. But vcpus is divided and allocated to different domains, every vcpu has its performace counters, how can I do to access their own performace counters in different domains?)
    3, I know there are methods such as libcpc, cpc module, and pcbe module for users or develpers to get performace data. What I am working at is to make some threads performance tuning on UltraSPARC T2+, Is the overhead acceptable to use these library or modules supported by the OS architecture.
    Please help me, indicate my fault and give me some advice or instruction. Thank you very much.

    What I am going to do is programming with hardware performace counters of UltraSPARC T2+ processors in Solaris 10. I programmed a loadable syscall to invoke the hv_niagara_getperf or ultra_getpic, trying to get the counters' data. But there just comes a panic, unresponsive without any text notice, and then reset. I don't know what's the real causes because I am not very familiar with SUN servers.
    I did some experiments both in primary domain and logical domain. In primary domain, both hv_niagara_getperf and ultra_getpic lead to panic, and in logical domain, hv_niagara_getperf return the ENOACCESS status and ultra_getpic lead to panic.
    My question are:
    1, If there is some initialization works or privilege settings to do to prevent panic?
    2, If Logical Domain can be set privileges to access hardware performace counters? (I read the Hypervisor api manuals and it says only one domain can access performance counters. But vcpus is divided and allocated to different domains, every vcpu has its performace counters, how can I do to access their own performace counters in different domains?)
    3, I know there are methods such as libcpc, cpc module, and pcbe module for users or develpers to get performace data. What I am working at is to make some threads performance tuning on UltraSPARC T2+, Is the overhead acceptable to use these library or modules supported by the OS architecture.
    Please help me, indicate my fault and give me some advice or instruction. Thank you very much.

  • For Experts: Why does LabView cause System reboot while accessing hardware with driver?

    Hello NI Developers!
    I use LabView 7.1 under Windows XP
    I have a programm console application which accesses through Jungo Windriver PCI-E board.
    This program works fine - and performs DMA data transfer between PC and Board's memory.
    In order to implement this console application work together with LabView I did following:
    1) Added this function inside the source:
     _declspec(dllexport) void LVMainFunction(uInt32 *IntValue);
    _declspec(dllexport) void LVMainFunction(uInt32 *IntValue)
        AllocConsole();                   //Open new console window
        SetConsoleTitle(L"Debug Window"); //Set a title for console window
        freopen("CONOUT$","a+",stdout); //redirec standard output stream to current window so
                                        // so we are able to see "printf" outputs
       freopen("CONIN$","a+",stdin);    //redirec standard input stream to current window so
                                        // so we are able pass inputs from keyboard
       main();                          //Call applications main function which does all the work
    2) Compiled this new source as DLL library
    3) Call  LVMainFunction(...) function from LabView using Call Library Node
    In the result: Executing VI - opens new console window, shows debug outputs and receives keyboard inputs.
    It works fine till the last function, which perform DMA data transfer - and reboots PC.
    1) Why does this happen?
    2) I understand that opening console from Call Library Node, attaches together this console window and running VI. So If I close one of them - both windows closes.
         So does LabView have somekind of restrictions of accessing Hardware's functions? 
    I can read Board's resource information and view size of memory on board, interrupt functions and other information about device, but when I try to reach
    DMA my system reboots. And I understand that this should be some kind of LabView problem, cause I tried different implementations, even without use of
    console window - and the result is the same.
    3) Should I split the program in to two separate processes and perform data exchange using Sockets or Pipes techology?
    Thank you in advance!
    ACiDUser
    Message Edited by ACiDuser on 11-13-2008 09:37 AM

    Hello!
    At LAST!!!
    I solved this problem!
    From the beginning I was following National Instruments manual on how to build DLL with external IDE:
      http://zone.ni.com/reference/en-XX/help/371361A-01​/lvhowto/building_library_project/
    Set the Struct member alignment control to 1 Byte.
    Now this option caused my PC to reboot!
    So could someone explain  why this happened? and If it is a bad tip, so it's better to remove from manual. Then other people will not have such problems as I did
    - wasting 2 monthes of time determining the problem. 
    I changed it to  Set the Struct member alignment control to DEFAULT.
    and now everything works fine.
    Regards
    Message Edited by ACiDuser on 11-13-2008 11:14 AM

  • How to access .asmx Web Service using JAVA? Newbie

    Hello Experts,
    Currently, I have a project where in I have to access a ,NET web service. It is made of C#. I just want to ask how will I start the accessing process? I made this simple equation on how my project is.
    Java Project + C#.Net Web Service = Integration
    1. Do i need to create a Web Service too for the Java Project? If yes, What are the necessary tools needed for the creation of this Java Web Service?
    2. The .NET Web Service is available online. (It is made by other people).
    3. Based on the equation, what is the equivalent technology for the + sign?
    4. Can you site a concrete example for accessing a web service?
    5. I'm new here. Totally I have no idea where to start.
    6. Thank you experts.
    Edited by: Benedict.Aluan on 05 30, 08 1:38 PM
    Edited by: Benedict.Aluan on 05 30, 08 1:39 PM

    Hello
    Thanks a lot for your help ...
    I am developing simple J2EE based web service client using IBM WSAD 5.1. I have used the following code to call .asmx web service in Java
    String url = "http://www.w3schools.com/webservices/tempconvert.asmx?wsdl";
         String namespace = "http://tempuri.org/";
         name = request.getParameter("txtName");
         try
              System.out.println("In Internet Service");
              ServiceFactory factory = ServiceFactory.newInstance();
              Service serv = factory.createService(new URL(url),new QName(namespace,"TempConvert"));
              System.out.println("Got Service......");
              Call obj = (Call)serv.createCall();
              System.out.println("Got Call......");
              obj.setProperty(Call.ENCODINGSTYLE_URI_PROPERTY,"");
              obj.setProperty(Call.OPERATION_STYLE_PROPERTY,"wrapped");
              obj.setTargetEndpointAddress(url);
              obj.setPortTypeName(new QName(namespace,"TempConvertSoap"));
              obj.setOperationName(new QName(namespace,"FahrenheitToCelsius"));
              obj.addParameter("param1",XMLType.XSD_STRING,String.class,ParameterMode.IN);
              obj.setReturnType(XMLType.XSD_STRING);
              System.out.println("Parameters Set.....");
              Object[] params = new Object[]{name};
              k = (String)obj.invoke(params);
              System.out.println("Result: "+k);
         catch(Exception e)
            System.out.println("Exception is : "+e);
        }But this code is throwing exception that
    Invalid Address "http://www.w3schools.com/webservices/tempconvert.asmx?wsdl"I have also tried this URL with Java Proxy. But it showing the same error.
    Plz can u tell me how to access .asmx web service ?
    Waiting 4 reply.

  • How to access a  web service(.wsdl) from portal component.

    Hi ,
    Is there any document/tutorial available on how to access a webservice from portal component ?
    I have found this linkhttps://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/ep/g-i/how to access a web service.htm...
    but the urls in the link are not working...
    i want  to know the steps to access webs service and sample code if some body has already done that..
    Thanks for the help.
    Lakshmi

    Hi Lakshmi,
    See the links below:
    http://help.sap.com/saphelp_nw04/helpdata/en/f0/581140d72dc442e10000000a1550b0/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/a3/918340d990ce62e10000000a155106/content.htm
    Hope this helps.
    Regards,
    Pooja.

  • How To Access HTTPS Web Service  in Application Module

    I need to know how to access HTTPS web service in application module.
    If you can provide the tutorial or guidance to achieve this really appreciate.
    Thanks
    Sameera

    Use the Web Service Proxy wizard in JDeveloper to create a class that calls your Web service, and then call this class from code in your AM.
    http://docs.oracle.com/cd/E16340_01/web.1111/b31974/web_services.htm#CJAHGIEF

  • How to access a web service from a XLet

    Hello,
    I am new in software development to ITV and I dint find too many usefull information teaching how to access a web service from a XLet running in a STB. Are there anybody who can give me some help, maybe sample or tutorial?
    Gratefull
    David

    hi,
    you can "borrow" the source code from [Yambo a free soft open source presentation engine (AKA XML microbrowser Xlet )|http://www.cineca.tv/labs/mhplab/index-en.html] both local and on a http remote connection.
    hope it helps..
    bye
    andrea

  • Memory Problem on 790fx-gd70 - how to access DDR Voltage in BIOS?

    I have been getting memory related problems on a 6 month old system. I could only boot from one stick of RAM (Corsair TW3X4G1333C9A) but even then system was not stable for gameplay or stability test though this stick did pass overnight memtest. I returned the board, cpu and memory for them to test. They diagnosed faulty RAM and replaced. Well it worked OK for 24 hours then I started getting BSOD "PFN_List_Corrupt" and "Memory_Management" crashes.
    I tested the new sticks and one fails memtest after a few seconds with 2378 errors and the other, although it passes memtest with 20 passes, crashes out straight away on Prime95 Blend Test (i.e. the one that stresses RAM).
    They suggested I enter DDR Voltage manually rather than relying on Auto but no matter what I seem to enable this option is greyed out. Does anyone know which settings need changing from defaults so I can get at the voltage section?
    I have tried swapping around the dimms but they are all the same regardless so not a slot problem. Now of course, I don't see it as a RAM problem either unless I am the unluckiest person to keep getting bad sticks. So now I think maybe something on the board or CPU is causing damage to the RAM or at least causing it to mis-report. Could a fault in the memory controller be doing this and if so how can I test for this?
    At my wit's end here. Hope someone has some ideas - either on how to access DDR Voltage in the BIOS or get to the cause of my problem.
    Many thanks.

    OK thanks for explaining a bit more  .  This power unit did get some very good reviews in the sub $100 from many sites and from these I thought it would suit my needs. I have arranged to try a friend's 650w next week.
    I think I am maybe not being clear.  I have had the system running OK for six months. I had had no need to test the ram and didn't bother with stability tests at that stage.  I am not a gamer and use my machine more for video and graphics work.  One thing I did notice from the start was the couple of games I do have on (Call of Duty and Fallout3) would give occasional freezes.  I put it down to my now rather old hot GPU which I would get around to replacing in due course.
    Now the real problems started recently when I got round to replacing the stock cooler with a Titan Fenrir.  Trouble with this is it overhangs Dimm1 but in moving around the memory sticks I seem to have opened a real can of worms.  I could only get it to boot from one of the sticks.  This stick passed memtest but would crash out of prime95 and games would freeze within a couple of minutes. 
    Now, the retailers here in the UK told me to send back board, cpu and RAM.  They tested all 3 but they only replaced the memory and as you can see from my first post the memory related problems have continued.  The memory by the way is in Corsair's list as "100% tested compatibility".  Is it possible that something about the CPU/Board that is damaging the RAM?  If a stick is failing memtest (it failed another test too called Windiag) is that definitive?  It is bad for sure or board/cpu misreporting?  Am I right in thinking memtest86 does cannot distinguish faulty RAM from faulty memory controller?  Is there a test I can do to check if the CPU alone is faulty?
    I don't know if this means anything to you guys but when I ran the prime95 (Blend) recently with both sticks in it failed straight away on 2 cores but went on running on the other 2. 
    One of my other frustrations is I don't know anyone else with am3 board or memory so swap things around.
    Any suggestions for pinning this down would be much appreciated.  Just don't assume my knowledge is as great as yours  .  But I do learn.  I never knew v x a=w for example. And I now know how to change DDR Voltage in the BIOS - I had been expecting a sub-menu where Auto was greyed out and in fact it was just sitting there waiting for me to press + and -.  Very embarassing that I spent hours trying to change this when the instructions on what to do were right there in the help column!

  • How to access a value from "List of Values" by giving a name?

    I have a "List Of Values" defined in my BI Report. It comprises list of label-value pairs.
    I have defined a parameter :p_Value for the above "List Of Values" defnition. this parameter is used in datasource sql defnition to filter the query results. I configured a template which has a table that shows all the parameters used for filtering query results. If I give <?$p_Value?> in the template then the parameter value is rendered on it. But I want the "name" of the parameter and not the value. Can anybody tell me how to access name of the parameter which refers to one of value in "List of Value" defnition?

    option 1:
    Can you get the value from the DB in the report sql ?
    You have the code, inside the report query, if you can get the decoded value form that
    option2:
    create another paramater, LOV and query, and make it as hidden, and use the first :param_1_value in the lov query in the second param and decode the value.
    Now , you can refer the :PARAM_2_value in template which will have decoded value.

  • How to access my macbook pro from a windows pc?

    how to access my macbook pro from a windows pc?

    Depending on what you mean by "access" the following may help:
    File sharing: How to connect with File Sharing on your Mac - Apple Support
    One way (and there are others) for remote control and remote access between Mac and Windows: http://www.teamviewer.com/en/index.aspx

  • In VB Programming code -- How to access the formula for suppressing a field

    In VB Programming code -- How to access the formula for suppressing a field
    I am using Crystal Reports 2008 v1
    Using VB code, I am attempting to modify a Crystal Report before exporting it into a PDF format and then displaying it on the Web.
    My problem is that I am unable to access the formula used to dynamically suppress a field.
    The following code is working:
    mySections = rd.ReportDefinition.Sections
    For Each mySection As CrystalDecisions.CrystalReports.Engine.Section In mySections
       ' myFieldToChange is a String set to the text of the field I need to adjust the Suppression
       iloop = 0
       For Each RecObj As CrystalDecisions.CrystalReports.Engine.ReportObject In mySection.ReportObjects
               If mySection.ReportObjects.Item(iloop).Name.ToLower = myFieldToChange Then
                   myTextObject = CType(mySection.ReportObjects.Item(iloop), CrystalDecisions.CrystalReports.Engine.TextObject)
                   myTextObject.Text = "new field text goes here"
                   mySection.SectionFormat.EnableSuppress = True
                   '  Here is where I want to change the formula for the Suppression
                End if
                iloop = iloop + 1
        Next
    Next
    I can not find any reference to the actual suppression formula in the SDK help file.
    Note, the EnableSuppress can be set to True for False, but if there is a formula for dynamic suppression, the True or False value is overwritten.  The results of the formula determine the suppression.
    Is there a way to reference this formula.  I know that I can put on in using the Crystal Report Designer software, I need to modify this formula using VB code and the SDK.

    Hello, Mark;
    If you are using the ReportDocument object you do not have access to the Conditional Suppression formula. You can get around it by using a formula field in the report for the supression and then using the FormulaField code to change it at runtime.
    If you want to change the supression condition directly at runtime you need to use RAS and the ReportClientDocument.
    Elaine

  • How to access and display a Web Service from a WSDL in JSP or JSTL ?

    Dear All,
    We need to access a Web Service which is hosted as WSDL How to access a WSDL file from JSP or JSTL, parse and display the SOAP response in JSP page.
    Any simple example or URL as reference to an example will be useful for me.
    It seems io tags of jakarta is able to send soap message, but how to display it in JSP.
    Yours,
    Sankar.B

    Dear Sir,
    Yes. I would like to know more about the Forte and how to consume WSDL file from JSTL. The following are my querirs.
    1. How to connect the declared JNDI from a JSP page. i.e: the Datasource - ex: booksDS
    2. We connect the Tomcat server using JNDI as jdbc/scott. But, if I give jdbc/scott in JSTL as datasource={jdbc/scott}, we could not able to connect. We use the following code in a JSP page to connect the DB from a JSP page. (Its quite easy to modify, so we use the connection in a JSP page.)
    3. How to Consume a WSDL url from JSTL. Ex: If there is a URL : http://localhost/ws/MathService.asmx?wsdl OR http://www.xmethods.com/test/BabelFish
    4. How to display the result. We tried via SOAP from io taglib of Jakarta, but gives us an SOAP (it also looks like xml) response. But, how to use the value from that soap response in IE client thru JSTL/JSP.
    5. Whether this JSTL tool will be available with Forte Enterprise/Community Edition. If so EE, whats the price.
    Please Reply Immediatly. We tried, trying, going to try to display a wsdl response, but not able to display in IE thru JSP/JSTL. But, weve tested the www.gotdotnet.com examples of asp.net web services, we are thru. Its quite easy it seems in .NET. But, we feel whether even there is not even one example in JSTL/ Java Web Services Dev. Pack to utilise a web service in full cycle. The example which uve given is thru servlets. We dont use servlets. Cos, its very easy to edit JSP pages, instead of compiling the serv. and using it.
    I hope ull reply for all the above queries, since ur from SUN.
    Expecting your fav. reply.
    Yours,
    Sankar.B

  • I have an old i tunes library but i dont know how to access it, when i plug my ipod into the new computer it will let me sync but then i lose all my music i have on my ipod. how can i transfer music from my ipod to my new itunes library?

    I have an old i tunes library but i don t know how to access it. im trying to sync my ipod with my new itunes library but it wont let me. how can i copy the songs off my ipod to my new library.

    You can transfer itunes purchases:
    File>Transfer Purchases

  • HT4436 Is there a way to connect my iCloud acct. so that my regular email address is my user name instead of the .me email address? I don't even know how to access my very old .me address.

    Anyone know if you can replace your .me email address for your regular email address? I'm trying to set up my iCloud acct. on my iPhone but the default email adddress is my .me email which I never used and do not know the password for. When I use the Forgot Password link, it sends to my .me email address
    and I never used it and don't know how to access that address. Arg. Anyway to clean slate and permanently eliminate the .me thing?

    I copied the iTunes file from the external drive and it's in both places.  I thought all I would need is the iTunes program (which I downloaded to new computer) and my iTunes library file.  There must be something else that's missing.  My iTunes library looks the same on the new computer as it does when I open it on the external drive.  If I click on an iTunes library song from my new computer, it will only play if I have the external drive plugged in.
    My back-up drive is a mess.  I have multiple copies of music, video, photo, and document files and I don't know how that happened. ={  Obviously, I don't know how to back up stuff properly and there are back-up files extending over a 6- to 8-year period.  I think all I did was just drag and drop the main folders from the back-up drive to the same main folders on the C: drive.  Also (and I'm kind of fuzzy on this) Windows used to automatically save music files in a folder within my document files (which makes no sense to me).  As my Jewish friends would say, "Oy Vey!" 

Maybe you are looking for