Affichage des articles dont le libellé est commands. Afficher tous les articles
Affichage des articles dont le libellé est commands. Afficher tous les articles

vendredi 7 mars 2014

Android App For Testing Linux Commands topic




I've started to really enjoy learning Linux. Can you guys recommend a good app that tests my terminal knowledge?

http://forum.xda-developers.com/show....php?t=2543618

I've seen this one. What else is there?





lundi 10 février 2014

Send commands to USB device in Python topic




Hi fellows,
I am facing difficulties in order to send USB commands to an RFID reader.
This is the command reference of the device: https://github.com/mti-rfid/RFID_Explorer

I am working with the MTI RU-824 model.

The manufacturer of the device only provide a driver for Windows (using .Net), but we need to run the device on Linux. That's why I need to write few lines of code in Python as a new "driver".

I am using PyUSB for accessing the device, and this is few lines of my code:

================================================== ==========================

import usb.core
import usb.util
import sys

VENDOR_ID = 0x24e9
PRODUCT_ID = 0x0824

device = usb.core.find(idVendor=VENDOR_ID, idProduct=PRODUCT_ID)

if device is None:
sys.exit("Could not find Id System Barcode Reader.")
else:
print 'Device detected'

device.set_configuration()

cfg = device.get_active_configuration()
interface_number = cfg[(0, 0)].bInterfaceNumber
alternate_setting = usb.control.get_interface(device, interface_number)
usb_interface = usb.util.find_descriptor(
cfg, bInterfaceNumber=interface_number,
bAlternateSetting=alternate_setting
)

endpoint_out = usb.util.find_descriptor(
usb_interface,
# match the first OUT endpoint
custom_match=lambda e: usb.util.endpoint_direction(e.bEndpointAddress) == usb.util.ENDPOINT_OUT
)

endpoint_in = usb.util.find_descriptor(
usb_interface,
# match the first IN endpoint
custom_match=lambda e: usb.util.endpoint_direction(e.bEndpointAddress) == usb.util.ENDPOINT_IN
)

endpoint_out.write('0x01')
print endpoint_in.read(len('0x01'), 1000)

================================================== ===========================
My question is on the last 2 lines.
I am using endpoint_out to send a command and endpoint_in to read data from the reader. Am I correct?

The problem is, when I run the code, there is an error message like this:
usb.core.USBError: [Errno 110] Operation timed out

Anyone can give a clue?
Thank you.






mercredi 29 janvier 2014

[Q] Running multiple 'adb shell' commands through 'CreateProcess' on Windows PC topic




Hi All,

This query is about running 'multiple adb commands' on 'single adb shell' opened using CreateProcess.

Currently we are able to run single command on adb shell which is created using CreateProcess API. This works fine.

But our requirement is, opening up of single adb shell and executes set of adb commands on that same shell. (ie., reusing of already opened adb shell for executing further adb commands on it)

Kindly let me know if anyone has an idea on this.

Thanks and Regards,
Sridevi.





vendredi 24 janvier 2014

[Q]Cannot connect my HTC LEGEND to my PC with adb commands ! topic




Hello !

Recently i flashed CM9.1 Unofficial Beta 8 rom and it was working fine ! I forgot to flash the Gapps for it so i decided to do so . When i open Rom Manager on my phone , it crashes !! I tried connecting my phone to my PC and pushing in the recovery image from r4-legend root to go to recovery mode to flash the rom ! But when i try connecting using the command "adb devices" , its not getting connected ! NO SERIAL number is displayed ! Any fix/help ??

Thanks in Advance

Cheers !





jeudi 23 janvier 2014

Voice commands produce prompt to: Download high quality voice file topic




The prompt message is:

A high quality voice file will be downloaded for the English (United States) language. To hear a high quality TTS voice, download a high quality voice file.

Upon clicking OK, I'm redirected to the Samsung store.

The thing is, to circumvent this, I've installed Google TTS engine. So I'm no longer using the Samsung's one. So why am I still being harassed to update the voice file for Samsung's TTS engine?

Update: I turned on Talkback, tried again, turned it off, and now... it sort of works. When I say "call home" it no longer echos "Calling home..." but just calls. Same for "Open Gmail". Right at the start it'd say "Calling home..." and "Opening Gmail..." before getting interrupted by the prompt. How do I get it to the original state but without the prompt?