Search Results

Search found 280 results on 12 pages for 'emulation'.

Page 2/12 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Card emulation via software NFC

    - by user85030
    After reading a lot of questions, i decided to post this one. I read that stock version of android does not support API's for card emulation. Also, we cannot write custom applications to secure element embedded in nfc controllers due to keys managed by google/samsung. I need to emulate a card (mifare or desfire etc). The option i can see is doing it via software. I have a ACR122U reader and i've tested that NFC P2P mode works fine with the Nexus-S that i have. 1) I came across a site that said that nexus s's NFC controller (pn532) can emulate a mifare 4k card. If this is true, can i write/read apdu commands to this emulated card? (Probably if i use a modded rom like cyanogenmod) 2) Can i write a android application that reads apdu commands sent from the reader and generate appropriate responses (if not fully, then upto some extent only). To do so, i searched that we need to patch nexus s with cynagenmod. Has someone tried emulating card via this method? I see that this is possible since we have products from access control companies offering mobile applications via which one can open doors e.g. http://www.assaabloy.com/en/com/Products/seos-mobile-access/

    Read the article

  • How to use pipes for nonblocking IPC (UART emulation)

    - by codebauer
    I would like to write some test/emulation code that emulates a serial port connection. The real code looks like this: DUT <- UART - testtool.exe My plan is to use create a test application (CodeUnderTest.out) on linux that forks to launch testool.out with two (read & write) named pipes as arguments. But I cannot figure out how to make all the pipe IO non-blocking! The setup would look like this:. CodeUnderTest.out <- named pipes - testTool.out (lauched from CodeUnderTest.out) I have tried opening the pipes as following: open(wpipe,O_WRONLY|O_NONBLOCK); open(rpipe,O_RDONLY|O_NONBLOCK); But the write blocks until the reader opens the wpipe. Next I tried the following: open(wpipe,O_RDWR|O_NONBLOCK); open(rpipe,O_RDONLY|O_NONBLOCK); But then the reader of the first message never gets any data (doesn't block though) I also tried adding open and close calls around each message, but that didn't work either... Here is some test code: #include <stdio.h> #include <sys/types.h> #include <unistd.h> #include <fcntl.h> pid_t pid; char* rpipe, *wpipe,*x; FILE *rh,*wh; int rfd,wfd; void openrpipe( void ) { rfd = open(rpipe,O_RDONLY|O_NONBLOCK); rh = fdopen(rfd,"rb"); printf("%sopeningr %x\n",x,rh); } void openwpipe( void ) { //Fails when reader not already opened //wfd = open(wpipe,O_WRONLY|O_NONBLOCK); wfd = open(wpipe,O_RDWR|O_NONBLOCK); wh = fdopen(wfd,"wb"); printf("%sopeningw %x\n",x,wh); } void closerpipe( void ) { int i; i = fclose(rh); printf("%sclosingr %d\n",x,i); } void closewpipe( void ) { int i; i = fclose(wh); printf("%sclosingw %d\n",x,i); } void readpipe( char* expect, int len) { char buf[1024]; int i=0; printf("%sreading\n",x); while(i==0) { //printf("."); i = fread(buf,1,len,rh); } printf("%sread (%d) %s\n",x,i,buf); } void writepipe( char* data, int len) { int i,j; printf("%swriting\n",x); i = fwrite(data,1,len,rh); j = fflush(rh); //No help! printf("%sflush %d\n",x,j); printf("%swrite (%d) %s\n",x,i,data); } int main(int argc, char **argv) { rpipe = "readfifo"; wpipe = "writefifo"; x = ""; pid = fork(); if( pid == 0) { wpipe = "readfifo"; rpipe = "writefifo"; x = " "; openrpipe(); openwpipe(); writepipe("paul",4); readpipe("was",3); writepipe("here",4); closerpipe(); closewpipe(); exit(0); } openrpipe(); openwpipe(); readpipe("paul",4); writepipe("was",3); readpipe("here",4); closerpipe(); closewpipe(); return( -1 ); } BTW: To use the testocd above you need to pipes in the cwd: mkfifo ./readfifo mkfifo ./writefifo

    Read the article

  • Preventing mouse emulation events (ie click) from touch events in Mobile Safari / iPhone using Javas

    - by Jaime Cham
    In doing a single page Javascript app with interactive DOM elements I've found that the "mouseover-mousemove-mousedown-mouseup-click" sequence happens all in a bunch after the "touchstart-touchmove-touchend" sequence of events. I've also found that it is possible to prevent the "mouse*-click" events from happening by doing an "event.preventDefault()" during the touchstart event, but only then, and not during the touchmove and touchend. This is a strange design, because because it is not possible to know during the touchstart yet whether the user intents to drag or swipe or just tap/click on the item. I ended up setting up a "ignore_next_click" flag somewhere tied to a timestamp, but this is obviously not very clean. Does anybody know of a better way of doing this, or are we missing something? Note that while a "click" can be recognized as a "touchstart-touchend" sequence (ie no "touchmove"), there are certain things, such as keyboard input focus, that can only happen during a proper click event.

    Read the article

  • Excel MAXIF function or emulation?

    - by Andre Boos
    I have a moderately sized dataset in Excel from which I wish to extract the maximum value of the values in Column B, but those that correspond only to cells in Column A that satisfy certain criteria. The desired functionality is similar to that of SUMIF or COUNTIF, but neither of those return data that is necessary. There isn't a MAXIF function, so I ask the SO community: how do I emulate one?

    Read the article

  • target="_top" emulation using JavaScript

    - by abovesun
    Suppose we have frameset of with 2 frames, one frame is kind a tiny horizontal header and second is kind of "content" frame with 3rd-party html page inside. When user clicks on some link inside "content" frame, the whole page (frameset) should be reloaded with this link, the same behavior if "content" frame has "target=_top" attribute. How to do this using JS?

    Read the article

  • Issue getting camera emulation to work with Tom G's HttpCamera

    - by user591524
    I am trying to use the android emulator to preview video from webcam. I have used the tom gibara sample code, minus the webbroadcaster (i am instead using VLC streaming via http). So, I have modified the SDK's "CameraPreview" app to use the HttpCamera, but the stream never appears. Debugging through doesn't give me any clues either. I wonder if anything obvious is clear to others? The preview app launches and remains black. Notes: 1) I have updated the original CameraPreview class as described here: http://www.inter-fuser.com/2009/09/live-camera-preview-in-android-emulator.html, but referencing httpCamera instead of socketcamera. 2) I updated Tom's original example to reference "Camera" type instead of deprecated "CameraDevice" type. 3) Below is my CameraPreview.java. 4) THANK YOU package com.example.android.apis.graphics; import android.app.Activity; import android.content.Context; import android.hardware.Camera; import android.os.Bundle; import android.view.SurfaceHolder; import android.view.SurfaceView; import android.view.Window; import java.io.IOException; import android.graphics.Canvas; // ---------------------------------------------------------------------- public class CameraPreview extends Activity { private Preview mPreview; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // Hide the window title. requestWindowFeature(Window.FEATURE_NO_TITLE); // Create our Preview view and set it as the content of our activity. mPreview = new Preview(this); setContentView(mPreview); } } // ---------------------------------------------------------------------- class Preview extends SurfaceView implements SurfaceHolder.Callback { SurfaceHolder mHolder; //Camera mCamera; HttpCamera mCamera;//changed Preview(Context context) { super(context); // Install a SurfaceHolder.Callback so we get notified when the // underlying surface is created and destroyed. mHolder = getHolder(); mHolder.addCallback(this); //mHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS); mHolder.setType(SurfaceHolder.SURFACE_TYPE_NORMAL);//changed } public void surfaceCreated(SurfaceHolder holder) { // The Surface has been created, acquire the camera and tell it where // to draw. //mCamera = Camera.open(); this.StartCameraPreview(holder); } public void surfaceDestroyed(SurfaceHolder holder) { // Surface will be destroyed when we return, so stop the preview. // Because the CameraDevice object is not a shared resource, it's very // important to release it when the activity is paused. //mCamera.stopPreview();//changed mCamera = null; } public void surfaceChanged(SurfaceHolder holder, int format, int w, int h) { // Now that the size is known, set up the camera parameters and begin // the preview. //Camera.Parameters parameters = mCamera.getParameters(); //parameters.setPreviewSize(w, h); //mCamera.setParameters(parameters); //mCamera.startPreview(); this.StartCameraPreview(holder); } private void StartCameraPreview(SurfaceHolder sh) { mCamera = new HttpCamera("10.213.74.247:443", 640, 480, true);//changed try { //mCamera.setPreviewDisplay(holder); Canvas c = sh.lockCanvas(null); mCamera.capture(c); sh.unlockCanvasAndPost(c); } catch (Exception exception) { //mCamera.release(); mCamera = null; // TODO: add more exception handling logic here } } }

    Read the article

  • Dice Emulation - ImageView

    - by Michelle Harris
    I am trying to emulate dice using ImageView. When I click the button, nothing seems to happen. I have hard coded this example to replace the image with imageView4 for debugging purposes (I was making sure the random wasn't fail). Can anyone point out what I am doing wrong? I am new to Java, Eclipse and Android so I'm sure I've probably made more than one mistake. Java: import java.util.Random; import android.app.Activity; import android.os.Bundle; import android.view.View; import android.widget.ArrayAdapter; import android.widget.ImageView; import android.widget.Spinner; import android.widget.Toast; public class Yahtzee4Activity extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); Spinner s = (Spinner) findViewById(R.id.spinner); ArrayAdapter adapter = ArrayAdapter.createFromResource( this, R.array.score_types, android.R.layout.simple_spinner_dropdown_item); adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item); s.setAdapter(adapter); } public void onMyButtonClick(View view) { ImageView imageView1 = new ImageView(this); Random rand = new Random(); int rndInt = 4; //rand.nextInt(6) + 1; // n = the number of images, that start at index 1 String imgName = "die" + rndInt; int id = getResources().getIdentifier(imgName, "drawable", getPackageName()); imageView1.setImageResource(id); } } XML for the button: <Button android:id="@+id/button_roll" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/roll" android:onClick="onMyButtonClick" />

    Read the article

  • Unobstrusive pseudo-classes and attribute selectors emulation in IE

    - by Álvaro G. Vicario
    I'm trying to emulate some pseudo-classes and attribute selectors in Internet Explorer 6 and 7, such as :focus, :hover or [type=text]. So far, I've managed to add a class name to the affected elements: $("input, textarea, select") .hover(function(){ $(this).addClass("hover"); }, function(){ $(this).removeClass("hover"); }) .focus(function(){ $(this).addClass("focus"); }) .blur(function(){ $(this).removeClass("focus"); }); $("input[type=text]").each(function(){ $(this).addClass("text"); }); However, I'm still forced to duplicate selector in my style sheets: textarea:focus, textarea.focus{ } And, to make things worse, IE6 seems to ignore all the selectors when it finds an attribute: input[type=text], input.text{ /* IE6 ignores this */ } And, of course, IE6 ignores selectors with multiple classes: input.text.focus{ /* IE6 ignores this */ } So I'm likely to end up with this mess: input[type=text]{ /* Rules here */ } input.text{ /* Same rules again */ } input[type=text]:focus{ } input.text_and_focus{ } input.text_and_hover{ } input.text_and_focus_and_hover{ } My question: is there any way to read the rules or computed style defined for a CSS selector and apply it to certain elements, so I only need to maintain one set of standard CSS?

    Read the article

  • Deeper function profiling/emulation

    - by Syntax_Error
    Hello everyone Merry Christmas I need an advice I have the following code: int main() { int k=5000000; int p; int sum=0; for (p=0;p<k;p++) { sum+=p; } return 0; } When I assemble it I get main: pushl %ebp movl %esp, %ebp subl $16, %esp movl $5000000, -4(%ebp) movl $0, -12(%ebp) movl $0, -8(%ebp) jmp .L2 .L3: movl -8(%ebp), %eax addl %eax, -12(%ebp) addl $1, -8(%ebp) .L2: movl -8(%ebp), %eax cmpl -4(%ebp), %eax jl .L3 movl $0, %eax leave ret If I run it through gprof I get that main executed the most, which is quite obvious! Yet I want to go a step further and be able to know if L2, or L3 executed the most. here it is obvious that L3 executed the most. yet is there some kind of profiler, emulator that can give me that data for an entire code?

    Read the article

  • HP-UX (PA-RISC|Itanium) virtualisation on (x86-64|x86)

    - by Oleksandr Bolotov
    I'm looking for a way to run HP-UX (for educational purposes), but I don't have HP hardware right now. These options are not very suitable for me: HP TestDrive program - Looks like it was discontinued 2 years ago. Ski - looks like only CPU emulator. Is it worth trying? HPPAQEMU - Patch for old Qemu for HPPA-Linux guest-OS only. Is it worth trying? hp-ux Aires - I don't need to visualize HP-PA on HP-Itanium. That question is about using HP-UX without HP hardware.

    Read the article

  • Remapping the Windows key in Parallels

    - by Kaji
    I'm running XP on Parallels 4 for Mac, and it's working well enough, however one thing that's bothering me more and more as I go along is the way it constantly assumes every press of the command key means I want the start menu to come up. I've tried to remap it in the Parallels preferences, but all that does is allow me to create additional ways to call the start menu. Is there a setting either within XP or somewhere outside that I can set to discourage this behavior?

    Read the article

  • Parallel Desktops: installing Parallel Tools on Ubuntu

    - by Patrick
    hi, I get the following error when I try to install Parallel Tools on my Ubuntu in Parallel Desktop. I follow the istructions, running sh install from terminal: I follow the UI istructions and then the installation stops with this error message: E: Couldn't find package dkms Fri May 7 14:34:20 PDT 2010 Start installation or upgrade of Guest Tools Installed Guest Tools were not found Perform installation into the /usr/lib/parallels-tools directory cat: /usr/lib/parallels-tools/kmods/../version: No such file or directory Start installation of prl_eth kernel module make: Entering directory `/usr/lib/parallels-tools/kmods' cd prl_eth/pvmnet && make make[1]: Entering directory `/usr/lib/parallels-tools/kmods/prl_eth/pvmnet' make -C /lib/modules/2.6.32-21-generic/build M=/usr/lib/parallels-tools/kmods/prl_eth/pvmnet make[2]: Entering directory `/usr/src/linux-headers-2.6.32-21-generic' LD /usr/lib/parallels-tools/kmods/prl_eth/pvmnet/built-in.o CC [M] /usr/lib/parallels-tools/kmods/prl_eth/pvmnet/pvmnet.o LD [M] /usr/lib/parallels-tools/kmods/prl_eth/pvmnet/prl_eth.o Building modules, stage 2. MODPOST 1 modules WARNING: modpost: missing MODULE_LICENSE() in /usr/lib/parallels-tools/kmods/prl_eth/pvmnet/prl_eth.o thanks

    Read the article

  • USB to USB CD ROM emulator

    - by JohnnyLambada
    I'm wondering if anyone knows of a CDROM emulator that runs on Linux. I want to emulate this configuration: [CDROM DRIVE]----USB CABLE----[COMPUTER UNDER TEST] Where [COMPUTER UNDER TEST] is a computer that boots from a physical CD inserted into the [CDROM DRIVE]. Only instead of the [CDROM DRIVE] I want the following configuration: [CD IMAGE BUILD MACHINE]-----USB CABLE-----[COMPUTER UNDER TEST]. I want to build an ISO image on the [CD IMAGE BUILD MACHINE] and have some sort of USB CDROM emulator running on it to serve up the ISO image to the [COMPUTER UNDER TEST] as though it was talking to the [CDROM DRIVE]. Does this exist? If it does, I can't find it. I want to do this so I can test out bootable CDs without burning a lot of coasters.

    Read the article

  • Smartphone Emulator for checking emails are readable

    - by celenius
    Is there an emulator that would enable me to test the appearance of an email as it is being read on a smartphone (without specifying the phone type)? What I would like to be able to do, is to send an email to this emulator, and then scroll down through the email using the emulator. Ive searched online, and any emulators I found are for testing software rather than exploring the visual appearance of email. I'm using Mac OSX - thanks in advance.

    Read the article

  • emulate fake monitor on windows 7?

    - by Claudiu
    Is there any way to emulate a monitor on Windows 7? I have one physical monitor, and I want Windows to think I have two. I actually don't care whether the second monitor is visible anywhere, or if I can see it - everything rendered there may as well go to the equivalent of /dev/null - but I need Windows to think there is one there. The reason is that I want to run a virtual machine with two monitors with VirtualBox in seamless mode, and it doesn't let me go to seamless mode if there are more virtual monitors than physical ones. I don't need to see the second virtual monitor, but VirtualBox won't just stop displaying it like it did in earlier versions.

    Read the article

  • PS3 controller -> PC -> emulators -> TV

    - by abrereton
    I'm researching a media PC for the living room. Playing videos, audio and streaming Internet is straightforward enough. I would also like to run a gaming console system. I was wondering if anyone has any thoughts on this. So far I've discovered that a PS3 controller (thankfully it uses USB and Bluetooth) can be connected to a PC. I've also found that MAME, MESS and PCSX2 are all the emulators I need (I can even emulate a TI-83 calculator with MESS). These emulators can re-map keys, so for example I can make the Nintendo's A button to the PS3 X button, or the SNES key pad could be the PS3 keypad or the analog stick. There are also front-ends to these emulators which can do fancy things like image scaling, anti-aliasing and double-buffering to improve the image quality of an 8-bit Mario on a 50 inch plasma. My set up would be this: PS3 controller connecting over Bluetooth to the PC, PC with Windows, PS3 controller drivers, all my emulators, Network drive with all my ROMs, PC connected to TV via HDMI TV playing Super Mario Kart Does this sound feasible? Does anyone have experience of doing anything like this? Is this a good idea or should I grow up and stop living in the past?

    Read the article

  • What emulator / VM software can I use to create a Win32-portable Linux Guest?

    - by Jotham
    Hi, I want to create a portable VM setup so that I can boot a Linux install regardless of which Windows XP / Windows 7 host machine I am on. I was looking at Qemu but it doesn't appear to have a relatively safe win32 build. Other things like VirtualBox require complete install on the host OS for performance reasons. I'm not so concerned about performance, I just want to run a few curses based applications. My ideal end goal would be a a memory stick of some size with a VM/Emulator I can boot on most WinXP/Windows 7 machines and access my own curses based applications (probably archlinux or debian). Any help would be appreciated. Regards,

    Read the article

  • Peer to Peer solution for LAN over Internet

    - by Coyote
    I need to emulate a LAN between some machines over the internet to play some LAN only games. I remember that there was software that could do this, but don't remember what it was called. Anyone heard of this, or know of similar solutions that won't require a lot of work? The game is fun, but not fun enough to bother with setting up a VPN server. ;-)

    Read the article

  • Is there a way to automate testing for a GNS3 network topology?

    - by Chedy2149
    I'm working on an MPLS backbone topology using GNS3, this topology includes configuration of several networking technologies such as IPv6, BGP, OSPF, IPv6 to IPv4 dynamic tunneling, MPLS based VPNs, MPLS based traffic engineering... So I'm a beginner with basic knowledge in networking (Ipv4 addressing, basic routing and switching) and I can't just easly test if my topology works or not, moreover fiddling with configuration I've noticed that sometimes when getting MPLS config right and missing BGP config all my topology is messed up. Given that I use Cisco 7200 series routers, is there any way to build a test harness for my topology in order to guarentee correctness with a single push button automated process?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >