Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > PocketBook > PocketBook Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 03-22-2011, 02:12 PM   #1
yuryfdr
Connoisseur
yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.
 
Posts: 61
Karma: 29446
Join Date: Apr 2010
Device: pocketbook 301, pocketbook 603
Command line sound apps trouble

Hi. I try use timidity++ for midi in pocketbook pro 603.
no problem to build, but...

I see a strange behavior when i only touch screen with stilus misic is played. It seams that PB go to sleep with no events.
Does anyone know solution?

I use wrapper timidity.app and freepats
---timidity.app------
#!/bin/sh
/mnt/ext1/system/bin/timidity $1 >/dev/null 2>&1 &
-----------------------
yuryfdr is offline   Reply With Quote
Old 03-25-2011, 03:29 AM   #2
rkomar
Wizard
rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.
 
Posts: 2,986
Karma: 18343081
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
I have no idea if this will work on the PB device, but android devices can use a wake_lock to keep from going into suspend mode. Try bracketing your call to timidity with:

echo test > /sys/power/wake_lock
timidity ...
echo test > /sys/power/wake_unlock

and see if that keeps the system from suspending.

Last edited by rkomar; 03-25-2011 at 03:35 AM. Reason: cat -> echo
rkomar is online now   Reply With Quote
Old 03-29-2011, 03:56 PM   #3
yuryfdr
Connoisseur
yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.
 
Posts: 61
Karma: 29446
Join Date: Apr 2010
Device: pocketbook 301, pocketbook 603
Quote:
Originally Posted by rkomar View Post
....
echo test > /sys/power/wake_lock
timidity ...
echo test > /sys/power/wake_unlock

and see if that keeps the system from suspending.
it helps me, in this case I lost probability to run timidity in background, but i can patch timidity.

P.S. it's pity but I have another trouble midi files with guitar bands (and some other effects) are played with unacceptable quality :-(.
(tracks with Bass,Drums and PhythmGuitar seems plays ok)
is this gcc options enough for PB 603?
gcc -O2 -march=armv6j
or maybe reason is low speed filesystem?
yuryfdr is offline   Reply With Quote
Old 03-31-2011, 02:35 AM   #4
rkomar
Wizard
rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.
 
Posts: 2,986
Karma: 18343081
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
Quote:
Originally Posted by yuryfdr View Post
it helps me, in this case I lost probability to run timidity in background, but i can patch timidity.

P.S. it's pity but I have another trouble midi files with guitar bands (and some other effects) are played with unacceptable quality :-(.
(tracks with Bass,Drums and PhythmGuitar seems plays ok)
is this gcc options enough for PB 603?
gcc -O2 -march=armv6j
or maybe reason is low speed filesystem?
MIDI files are tiny compared to mp3 files, so I doubt that it is the filesystem slowing down timidity. But if it is, maybe the '-B' option of timidity can help you. What is the problem that makes it unacceptable? There are many timidity options that you can play with. Try setting the output to ALSA (-Os). You can reduce CPU usage by setting a low sampling frequency ( say "-s 11025") and even mono output (--output-mono) to see if it is really the CPU that is limiting things. It would be good to know what is really causing the problem before trying to find the solution.
rkomar is online now   Reply With Quote
Old 04-02-2011, 12:57 PM   #5
yuryfdr
Connoisseur
yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.yuryfdr is faster than slow light.
 
Posts: 61
Karma: 29446
Join Date: Apr 2010
Device: pocketbook 301, pocketbook 603
Quote:
Originally Posted by rkomar View Post
You can reduce CPU usage by setting a low sampling frequency ( say "-s 11025") and even mono output (--output-mono)
Thanks it helps me - to use low sampling frequency.
yuryfdr is offline   Reply With Quote
Old 04-02-2011, 04:11 PM   #6
rkomar
Wizard
rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.
 
Posts: 2,986
Karma: 18343081
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
Quote:
Originally Posted by yuryfdr View Post
Thanks it helps me - to use low sampling frequency.
I see. That does look like CPU usage is a big factor. I'm not sure, but I think the floating-point arithmetic is emulated on these devices. The timidity INSTALL file describes some of the compile-time settings that can be configured in timidity.h for reduced CPU usage. Things like FLOAT_T, LOOKUP_HACK, LOOKUP_INTERPOLATION and LOOKUP_SINE can be defined to reduce some of the floating-point calculations. Also, you can disable many CPU-intensive effects on the command-line, and that may sound better than just reducing the sampling frequency.
rkomar is online now   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
exit codes for command line apps nharrison66 Calibre 0 02-11-2011 12:53 AM
Where are the command line tools? PaulChernoch Calibre 17 10-23-2009 12:08 PM
Why use the command line? slantybard Calibre 6 07-22-2009 12:17 PM
Going completely command-line? ewiplayer Calibre 2 11-24-2008 05:15 AM


All times are GMT -4. The time now is 10:54 AM.


MobileRead.com is a privately owned, operated and funded community.