device-driver

Link between low level drivers and tty drivers

二次信任 提交于 2019-12-23 15:19:37
问题 I was writing a console driver for linux and I came across the tty interface that I need to set up for this driver. I got confused as to how tty drivers are bound with low-level drivers. Many times the root file system already contains a lot of tty devices. I am wondering how low-level devices can bind to one of the existing tty nodes on the root file system. For example, /dev/tty7 : Node on the root file system. How does a low-level device driver connect with this node? Or should that low

How to use the matrix_keypad.h file for a custom keypad driver?

▼魔方 西西 提交于 2019-12-23 05:10:48
问题 can i emulate a custom keypad with input_dev (from input.h) //an example with just one key. button_dev = input_allocate_device(); if (!button_dev) { printk(KERN_ERR "button.c: Not enough memory\n"); error = -ENOMEM; goto err_free_irq; } button_dev->evbit[0] = BIT_MASK(EV_KEY); button_dev->keybit[BIT_WORD(BTN_0)] = BIT_MASK(BTN_0); or i will have to use matrix_keypad header file?If yes then How? 来源: https://stackoverflow.com/questions/45382982/how-to-use-the-matrix-keypad-h-file-for-a-custom

How to use the matrix_keypad.h file for a custom keypad driver?

我只是一个虾纸丫 提交于 2019-12-23 05:10:03
问题 can i emulate a custom keypad with input_dev (from input.h) //an example with just one key. button_dev = input_allocate_device(); if (!button_dev) { printk(KERN_ERR "button.c: Not enough memory\n"); error = -ENOMEM; goto err_free_irq; } button_dev->evbit[0] = BIT_MASK(EV_KEY); button_dev->keybit[BIT_WORD(BTN_0)] = BIT_MASK(BTN_0); or i will have to use matrix_keypad header file?If yes then How? 来源: https://stackoverflow.com/questions/45382982/how-to-use-the-matrix-keypad-h-file-for-a-custom

CreateFile not returning a proper Handle - devices in Delphi

泪湿孤枕 提交于 2019-12-23 04:38:16
问题 Hoping to find somebody that has experience with services in windows. I am trying to use the NdisProt driver for ethernet adapters in Delphi my_Handle := CreateFile(PChar('\\.\NdisProt'), GENERIC_WRITE or GENERIC_READ, 0, nil, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); (have tried with \\.\\NdisProt too) After execution my_Handle always has the value '4008' decimal and GetLastError always returns 0 If I try to read or write to the file I get acces violation, anybody knows why I'm getting this

How to pass a bitfield (by reference) to a function?

扶醉桌前 提交于 2019-12-23 02:45:38
问题 My question is how to pass a bitfield instance by reference to a function. I have performed this as shown below, but when i eneter the function DAC_set_gain_code, the processor throws an interupt fault. Is what i am doing correct as far as passing the bitfield goes? I have created a bitfield (see below) which represents a 24bit register on an DAC chip, which i want to write into and lives in the .h file. typedef struct { uint8_t rdwr_u8: 1; uint8_t not_used_u8: 3; uint8_t address_u8: 4; uint8

VS 2013 Multi Device Hybrid App Failed to deploy to device, no devices found

為{幸葍}努か 提交于 2019-12-22 16:41:21
问题 I use the new VS 2013 phonegap/cordova template to create hybrid apps. It all works fine using emulators and the ripple media emulators but when i connect my phone to it . I get a error saying that ( See screenshot ) ERROR: Failed to launch application on device: ERROR: Failed to install apk to device: ERROR: Failed to deploy to device, no devices found. BlankCordovaApp1 Below were the steps i tried to resolve http://blog.falafel.com/running-cordova-multi-device-hybrid-app-from-visual-studio

Linux device driver unsafe FXSAVE/FXRSTOR bug — any precedents?

你离开我真会死。 提交于 2019-12-21 20:34:59
问题 There's a nasty problem that has temporarily stumped a number of engineers at my company trying to debug it. The C++ program is normally run on a cluster of multicore computers with MPI. It will run for a very long time -- perhaps days -- and then suddenly fail. Most of engineers working on it have eliminated any reasonable possibility of a bug in the program itself, so they're starting to assign blame to a possible hardware problem, but I suspect there must be a software problem in either a

Setting up eclipse for windows driver development

岁酱吖の 提交于 2019-12-21 20:01:33
问题 I am trying to write a user-mode windows(XP, Vista & 7) virtual printer driver using WDK 7.1.0 . I plan to use eclipse IDE for development, so wanted to know if I can set it up for the same. I am looking to do following:- 1) Eclipse to recognize win32 apis (C and C++) and hence provide features like autocompletion for its function names 2) Eclipse to use compiler provided with WDK 3) Debug the code through eclipse (Not sure if this is possible or not) OR would you suggest some other

Paged pool memory or Nonpaged pool memory ?? (windows driver development)

杀马特。学长 韩版系。学妹 提交于 2019-12-21 04:57:20
问题 I am newbie in windows driver development. I just want to know , a global variable in a driver will use paged pool memory or non paged pool memory ? Thanks and Regards Navaneeth 回答1: Depends. The Non paged pool should be reserved for memory that must stay in RAM so if you are doing something critical that would affected by a memory page from disk operation then use non paged. See here for more info. Looking at this (though it discusses c++ as opposed to C) it would seem that by default the

micromax a111 is not detected by adb

牧云@^-^@ 提交于 2019-12-21 02:43:15
问题 Recently i've purchased micromax a111 android device. I am android developer. So tried this device for debugging option. But the adb is not able to detect the device. I have change the settings also, but not working out. If any one have the solution please help me regarding this. 回答1: micromax doesn't have official PC-Suite, so you need to download a third party PC-Suite like Moborobo or Mobogenie, after installation you can restart the system, now your mobile will be detected. 回答2: Add the