Click here to Skip to main content
15,610,007 members
Home / Discussions / Linux Programming
   

Linux Programming

 
QuestionPARTIALLY SOLVED hcitool scan with grep pipe Pin
Vaclav_17-May-19 14:14
Vaclav_17-May-19 14:14 
AnswerRe: analyze "grep" pipe Pin
Richard MacCutchan17-May-19 21:18
mveRichard MacCutchan17-May-19 21:18 
QuestionHow to retrieve "terminal" output? Pin
Vaclav_17-May-19 7:26
Vaclav_17-May-19 7:26 
I have pretty much given up on using bluez hci functions.
Instead I am looking at bluetoothctl and hcitools.
At this point I can visually identify both local and "nearby" bluetooth devices using "system" calls in my C++ code.
I am not sure how to use these scripts for actual transfer of data.

For now I like to retrieve the received text for further processing - using redirection . See bellow example when using terminal. My C++ code provides similar output to console.

I understand that some command require "sudo" (user) but do not understand why the redirection is failing.
Perhaps I need to provide detailed path to the "test" file ?

Appreciate any help.


<pre>pi@pi:/ $ sudo hcitool scan --info  --class 
Scanning ...

BD Address:	00:50:B6:80:4D:5D [mode 1, clkoffset 0x4dae]
Device class:	Computer, Desktop workstation (0x000104)
Manufacturer:	Broadcom Corporation (15)
LMP version:	2.0 (0x3) [subver 0x430e]
LMP features:	0xff 0xff 0x8d 0xfe 0x9b 0xf9 0x00 0x80
		<3-slot packets> <5-slot packets> <encryption> <slot offset> 
		<timing accuracy> <role switch> <hold mode> <sniff mode> 
		<park state> <RSSI> <channel quality> <SCO link> <HV2 packets> 
		<HV3 packets> <u-law log> <A-law log> <CVSD> <power control> 
		<transparent SCO> <broadcast encrypt> <EDR ACL 2 Mbps> 
		<EDR ACL 3 Mbps> <enhanced iscan> <interlaced iscan> 
		<interlaced pscan> <inquiry with RSSI> <extended SCO> 
		<EV4 packets> <EV5 packets> <AFH cap. slave> 
		<AFH class. slave> <3-slot EDR ACL> <5-slot EDR ACL> 
		<AFH cap. master> <AFH class. master> <EDR eSCO 2 Mbps> 
		<EDR eSCO 3 Mbps> <3-slot EDR eSCO> <extended features> 

pi@pi:/ $ sudo hcitool scan --info  --class 2>test.txt
-bash: test.txt: Permission denied


AnswerRe: How to retrieve "terminal" output? Pin
Richard MacCutchan17-May-19 9:27
mveRichard MacCutchan17-May-19 9:27 
QuestionTheoretical server/site setup Pin
pyango58-May-19 12:00
pyango58-May-19 12:00 
QuestionSOLVED "configure" script option PKG_CONFIG_DEBUG_SPEW fails to run on X86 Pin
Vaclav_4-May-19 3:51
Vaclav_4-May-19 3:51 
GeneralRe: "configure" script option PKG_CONFIG_DEBUG_SPEW fails to run on X86 Pin
Richard MacCutchan4-May-19 4:56
mveRichard MacCutchan4-May-19 4:56 
Questionmissing mount.pc Pin
Vaclav_12-Apr-19 3:49
Vaclav_12-Apr-19 3:49 
AnswerRe: missing mount.pc Pin
Gerry Schmitz12-Apr-19 4:53
mveGerry Schmitz12-Apr-19 4:53 
GeneralRe: missing mount.pc Pin
Vaclav_12-Apr-19 7:53
Vaclav_12-Apr-19 7:53 
QuestionBad UDP length 736 > IP payload length Len = 728 packet drop Pin
sarali8-Apr-19 18:35
sarali8-Apr-19 18:35 
AnswerRe: Bad UDP length 736 > IP payload length Len = 728 packet drop Pin
Gerry Schmitz9-Apr-19 6:22
mveGerry Schmitz9-Apr-19 6:22 
AnswerRe: Bad UDP length 736 > IP payload length Len = 728 packet drop Pin
Randor 10-Apr-19 21:26
professional Randor 10-Apr-19 21:26 
GeneralRe: Bad UDP length 736 > IP payload length Len = 728 packet drop Pin
sarali12-Apr-19 20:43
sarali12-Apr-19 20:43 
GeneralRe: Bad UDP length 736 > IP payload length Len = 728 packet drop Pin
Randor 28-Apr-19 12:50
professional Randor 28-Apr-19 12:50 
GeneralRe: Bad UDP length 736 > IP payload length Len = 728 packet drop Pin
sarali10-May-19 2:55
sarali10-May-19 2:55 
PraiseRe: Bad UDP length 736 > IP payload length Len = 728 packet drop Pin
Randor 10-May-19 11:18
professional Randor 10-May-19 11:18 
QuestionActive PID Pin
Mohibur Rashid4-Apr-19 15:05
professionalMohibur Rashid4-Apr-19 15:05 
AnswerRe: Active PID Pin
Randor 4-Apr-19 15:57
professional Randor 4-Apr-19 15:57 
GeneralRe: Active PID Pin
Mohibur Rashid4-Apr-19 16:12
professionalMohibur Rashid4-Apr-19 16:12 
GeneralRe: Active PID Pin
Randor 4-Apr-19 16:23
professional Randor 4-Apr-19 16:23 
AnswerRe: Active PID Pin
k50544-Apr-19 16:29
mvek50544-Apr-19 16:29 
GeneralRe: Active PID Pin
Mohibur Rashid4-Apr-19 18:17
professionalMohibur Rashid4-Apr-19 18:17 
QuestionUsing "R CMD INSTALL ..." to install package Pin
Vaclav_1-Apr-19 14:41
Vaclav_1-Apr-19 14:41 
RantRe: Using "R CMD INSTALL ..." to install package Pin
k50542-Apr-19 4:50
mvek50542-Apr-19 4:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.