device

How to register a virtual card to alsa from user-space?

ⅰ亾dé卋堺 提交于 2019-12-07 22:17:29
问题 I'm developing a virtual device from the user space (using umview http://wiki.virtualsquare.org/wiki/index.php/UMview) so, i need to register my device to the system's sound cards list (I've never used alsa in a kernel module so I think that I need to call the snd_card_register() function) but I can't find a way to do that from the userspace... maybe I can write a syscall to do that? 回答1: I think you should stop bothering about overriding any particular file (i.e. stop using umview, it's not

Returned mac-address is the same for different devices

点点圈 提交于 2019-12-07 20:19:16
问题 I have to provide the unique identifier of my device to the server in a client app. Around StackOverflow it's been recommended commonly to use the device's mac address, since [[UIDevice currentDevice] uniqueIdentifier] property is deprecated started from iOS 5. So, when I make attempt to retrieve a device's mac address following the instructions, provided in the answers around SO, I get the same address for both my devices, which is obviously wrong: 02:00:00:00:00:00 . Checked the code many

Connecting to Digital Scale(Metler Toledo PS90) as HID runs OnReport only when cable is connected to computer for first time

二次信任 提交于 2019-12-07 18:57:06
问题 I am using Mike O Brien's HID Library to connect to digital scale, Device opens successfully then displays device attached & removed messages perfectly. But only runs OnReport for about 20 times initially After Inital approx 20 runs on OnReport it never runs again, unless I remove usb cable and re-connect. My code is below if (scale.IsConnected) { scale.Inserted += DeviceAttachedHandler; scale.Removed += DeviceRemovedHandler; scale.MonitorDeviceEvents = true; scale.ReadReport(OnReport);

Identify a new device in java

风格不统一 提交于 2019-12-07 18:29:53
问题 I want to know when a new device is connected. I learned that it is possible to get all the current devices in C# using: ManagementObjectSearcher searcher = new ManagementObjectSearcher("Select VolumeName, DeviceID from Win32_LogicalDisk Where Not (VolumeName is null)"); and then searcher.get() returns a collection of the devices. Is there something parallel to ManagementObjectSearcher that i can use in java? If not, is there another way to get the list of connected devices? or another way to

iOS USB HID programming

99封情书 提交于 2019-12-07 17:53:54
问题 I am trying to make some code regarding USB HID devices. I have found an article about Bluetooth programming which uses Game Kit Framework. Now I'm looking for some tutorial or maybe some code to work on connecting HID device via USB. Where should I look? Is Game Kit the right way? Is it difficult to implement communication between iOS and HID device? 回答1: You can use IOKit for USB, but it's a private framework on iOS - so it depends if you want to deploy to the App Store. Here is the USB

How to get device type from MAC or IP address?

戏子无情 提交于 2019-12-07 17:25:18
问题 I am making a Device Discovery windows application in C#. Is this possible to know the device type if I have MAC address or IP address? device type means either it is computer or router or mobile or any other device? Note: HostName entry is not useful for it because Host Name is defined by User. for example i may assign "Nokia N70" name to my computer. Thanks in anticipation. 回答1: You can get the manufacturer from the MAC address. In order to get any more information you'd need to do a port

Presentation technology for multiple devices

会有一股神秘感。 提交于 2019-12-07 13:20:21
问题 Our application is supposed to serve multiple devices, from simple to smart-phones, IPhones, touch-screens to normal browsers. Application is layered, so we can reuse the business and persistence layer. However, we would like to program single presentation layer as well. I know for example that ASP .NET generates different html output based on the browser type. http://msdn.microsoft.com/en-us/library/ms178620.aspx There are even some sites that promise to transform your site to mobile: http:/

Keyboard device in Unix

一笑奈何 提交于 2019-12-07 12:16:21
问题 This question was migrated from Unix & Linux Stack Exchange because it can be answered on Stack Overflow. Migrated 6 years ago . How to capture all the user input, reading one byte at a time? I did this coding, but it's not working if ((fd = open("/dev/char", O_RDONLY) != 1) { tty = open("/dev/tty", O_RDONLY); tcsetattr(0, TCSANOW, &orig_info); read (fd, &buf, sizeof(char)); } close(fd); I expected the terminal to wait for input, but it didn't. 回答1: The keyboard device itself is one of the

Android Studio: “Ok” button disabled in “Create new AVD” window

旧时模样 提交于 2019-12-07 12:10:53
问题 I downloaded and installed the latest Android Studio version which is 0.8.6 (beta) and I was stuck while trying to create a new Android Virtual Device. I tried to follow these steps: https://developer.android.com/training/wearables/apps/creating.html but looks like the CPU/ABI is unavailable when I pick one of the types mentioned in that document (Android Wear Square/Round) and the skins named AndroidWearRound or AndroidWearSquare are also unavailble. Here's a screenshot: 回答1: It's pretty

Android Studio - Can not open device monitor

邮差的信 提交于 2019-12-07 06:42:55
问题 I just downloaded Android Studio and it seems to import my existing Eclipse project well. However, if I try to open "Android Device Monitor" I get the message "An error has occurred" with a reference to a log file. My log file is included underneath. I am not sure why there is a reference to "Eclipse" int it? Anyhow, all in all, I have no idea where to go from here !SESSION 2015-01-05 04:00:15.329 ----------------------------------------------- eclipse.buildId=unknown java.version=1.8.0_25