Register Guidelines E-Books Search Today's Posts Mark Forums Read

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

Notices

Reply
 
Thread Tools Search this Thread
Old 01-29-2012, 02:44 AM   #1
idoit
Plus
idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.
 
idoit's Avatar
 
Posts: 356
Karma: 262144
Join Date: Jan 2012
Location: Tehran, Iran - Halifax, Canada
Device: K3.₄, iPhone 5s
Audio recorder and player for KT

Yes there is no incorporated software to use microphone in Kindle Touch but that doesn't mean we can't use it!
I wrote a very simple audio recorder and player. It might help in case you want to record something and you don't have your cellphone handy! Well this has more applications ...

O start recording
[] stop recording
> start playback
|| stop playback

Prerequisites:
- usbnetwork
- GUI Launcher

Install procedure:
0. Do you have SSH access to your Kindle?! If not, read this: USBNetwork
1. extract zip file to /mnt/us/
2. execute 'restart framework' through SSH
3. Guess what? -> Done!

Karma and happiness to all of you wonderfulz!

Details:
Spoiler:
- In the menu.json, as I didn't know how many other launchers each user has, I just set priority to 20. Feel free to change it.
- I use alsa player to play the latest created wav file. Unfortunately MP3 Player can't play this record as it's not MP3 but you can play it by mplayer or converting it using lame.
[ NOTE that all in all the quality is alright but for some reason it has such a low volume when played on the device! The volume is good when recorded wav is played on a computer. Make sure to max the volume by alsamixer. ]
Attached Thumbnails
Click image for larger version

Name:	screenshot_2012-01-29T03_14_41-0400.gif
Views:	1607
Size:	22.1 KB
ID:	81850   Click image for larger version

Name:	screenshot_2012-01-29T03_15_11-0400.gif
Views:	1417
Size:	20.7 KB
ID:	81851  
Attached Files
File Type: zip audio-recorder-player.zip (2.0 KB, 909 views)

Last edited by idoit; 06-16-2012 at 03:36 AM. Reason: Added noob-friendlier "Install procedure"
idoit is offline   Reply With Quote
Old 01-29-2012, 02:58 AM   #2
yifanlu
Kindle Dissector
yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.yifanlu can program the VCR without an owner's manual.
 
Posts: 662
Karma: 170717
Join Date: Jul 2010
Device: Amazon Kindle 3
Multiple commands requires the use of a shell script.
yifanlu is offline   Reply With Quote
Old 01-29-2012, 04:40 AM   #3
idoit
Plus
idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.
 
idoit's Avatar
 
Posts: 356
Karma: 262144
Join Date: Jan 2012
Location: Tehran, Iran - Halifax, Canada
Device: K3.₄, iPhone 5s
Quote:
Originally Posted by yifanlu View Post
Multiple commands requires the use of a shell script.
Oh silly me! Well it's 5am so ... Updated accordingly!

Edit: Ahhh damn, not gonna stay up so late anymore. Geekmaster: I forgot to update the 1st post even more, so now I did.

Last edited by idoit; 01-29-2012 at 12:12 PM.
idoit is offline   Reply With Quote
Old 01-29-2012, 11:12 AM   #4
geekmaster
Всё гениальное просто.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 5,066
Karma: 6789001
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Quote:
Originally Posted by cscat View Post
[ NOTE that all in all the quality is alright but because microphone is covered it has such a low volume. So make sure to max the volume by alsamixer.
Covered by what? The microphone is behind the little slot between the microUSB jack and the headphone jack.
geekmaster is offline   Reply With Quote
Old 05-10-2012, 01:44 PM   #5
ixtab
(offline)
ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.
 
ixtab's Avatar
 
Posts: 2,903
Karma: 6677485
Join Date: Dec 2011
Device: K3, K4, K5, KPW, KPW2
You can use these two commands to crank up the recording volume before actually running arecord:

Code:
/usr/bin/amixer sset 'MIXINL PGA',0 100% unmute cap
/usr/bin/amixer sset 'Capture',0 100%,100% unmute cap
# then arecord
I found the mixer name by trial and error, and I'm not sure if all the parameters are really required. Anyway, this works on my device, and probably should on yours, but you never know.

The resulting files are still not over-the-top quality, but it's usable for taking spoken notes. I'm attaching a sample (recorded from a computer sitting next to the Kindle, playing at "normal" volume).
Attached Files
File Type: zip rec2.zip (986.2 KB, 198 views)
ixtab is offline   Reply With Quote
Old 05-10-2012, 03:14 PM   #6
geekmaster
Всё гениальное просто.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 5,066
Karma: 6789001
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Quote:
Originally Posted by ixtab View Post
I found the mixer name by trial and error, and I'm not sure if all the parameters are really required. Anyway, this works on my device, and probably should on yours, but you never know.
So, you didn't find the "halt and catch fire" parameter settings yet?

But that microphone will come in handy when we get Skype running on these things, right?


Last edited by geekmaster; 05-10-2012 at 03:16 PM.
geekmaster is offline   Reply With Quote
Old 05-10-2012, 03:28 PM   #7
knc1
Embedded Cheerleader
knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.knc1 ought to be getting tired of karma fortunes by now.
 
knc1's Avatar
 
Posts: 6,194
Karma: 5830426
Join Date: Feb 2012
Device: Too many.
Quote:
Originally Posted by geekmaster View Post
So, you didn't find the "halt and catch fire" parameter settings yet?

But that microphone will come in handy when we get Skype running on these things, right?

He may have to wait for v-5.2.0 for those.
knc1 is offline   Reply With Quote
Old 05-12-2012, 04:48 PM   #8
inameiname
Groupie
inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.
 
Posts: 156
Karma: 20390
Join Date: Feb 2009
Device: none
Can this be adapted for those non-touch Kindles, such as Kindle 4 and Kindle 3?
inameiname is offline   Reply With Quote
Old 05-12-2012, 05:13 PM   #9
idoit
Plus
idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.idoit ought to be getting tired of karma fortunes by now.
 
idoit's Avatar
 
Posts: 356
Karma: 262144
Join Date: Jan 2012
Location: Tehran, Iran - Halifax, Canada
Device: K3.₄, iPhone 5s
Quote:
Originally Posted by inameiname View Post
Can this be adapted for those non-touch Kindles, such as Kindle 4 and Kindle 3?
For Kindle 3 yes, but not for Kindle 4 as the latter lacks microphone. One can easily integrate arecord and aplay into launchpad (if not done yet! ). But I just have Touch, so ...
idoit is offline   Reply With Quote
Old 05-12-2012, 05:41 PM   #10
ixtab
(offline)
ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.
 
ixtab's Avatar
 
Posts: 2,903
Karma: 6677485
Join Date: Dec 2011
Device: K3, K4, K5, KPW, KPW2
Just a side note: how about updating the file attached in the first post for future readers?
ixtab is offline   Reply With Quote
Old 05-12-2012, 06:59 PM   #11
geekmaster
Всё гениальное просто.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 5,066
Karma: 6789001
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
I used aplay to play movie output piped from ffmpeg on my kindle. I will publish a script soon to play movies on with sound on your kindles (from local files or internet URLs) in various formats (including x264 for the faster kindles). The K3 is not fast enough to decode x264 in real-time, so it can only play XviD/DivX/MPEG, etc.

Thanks for pointing out this aplay program, or my tools would be stuck with only silent films.

The K4 can use aplay to output to a .WAV file, or to pipe it to another program. I think a sound server running on a host PC would be good for a K4. It could then play sound over wifi to a remote sound system (perhaps even to a wifi-enabled smart TV). The simple way would be to pipe aplay to netcat (nc), then on a host PC from netcat to a player program that can accept raw sound from netcat.

And the K3 has aplay built in too. You can test it with:

aplay /dev/urandom

cat /dev/urandom|aplay


To play "s16le" formatted output from ffmpeg, you need to add a "-f cd" to aplay:

ffmpeg ... -|aplay -f cd


I will post ffmpeg with I have scripts that set all the parameters to sync the video and sound reliably for various movie format. Just like sound is delivered to aplay here, the video is delivered to gmplay used in the current "kindle video" thread. These audio and video programs naturally belong together.



Last edited by geekmaster; 05-12-2012 at 07:12 PM.
geekmaster is offline   Reply With Quote
Old 05-13-2012, 02:33 PM   #12
geekmaster
Всё гениальное просто.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 5,066
Karma: 6789001
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
I just tested, and you can still play audio files the old way too (including piped-in network streams). For example, with wifi on, this will play BBC on a K3 or a K5:

wget -O - http://mp32.bbc.streamuk.com | gst-launch playbin uri=fd://0
geekmaster is offline   Reply With Quote
Old 05-13-2012, 04:48 PM   #13
inameiname
Groupie
inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.
 
Posts: 156
Karma: 20390
Join Date: Feb 2009
Device: none
Quote:
Originally Posted by cscat View Post
For Kindle 3 yes, but not for Kindle 4 as the latter lacks microphone. One can easily integrate arecord and aplay into launchpad (if not done yet! ). But I just have Touch, so ...
Ah, thanks for the info. I don't have a Kindle 4, and forgot it lacked a microphone. So on a Kindle 3 you can run/install it the same way as on the KT?

And there are indeed Launchpad shortcuts already to record on the Kindle 3. Actually, the very same commands are also in a Kindlet called K3MusicManager. They are a few variations to the following that use arecord, but these seem to be the best:

audio_recorder.ini
Code:
[Actions]

; Audio Recorder (stored in 'audio' folder, and playable as audiobook)
A E = !kill -15 `pidof arecord`; dbus-send --system /default com.lab126.powerd.resuming int32:1 &
A S = !RECDIR=audible; [ -d "/mnt/us/$RECDIR" ] || mkdir -p "/mnt/us/$RECDIR"; arecord -qN /mnt/us/$RECDIR/_record_$(date +'%Y-%m-%d_%H-%M-%S').wav!.mp3 &
inameiname is offline   Reply With Quote
Old 05-13-2012, 04:54 PM   #14
inameiname
Groupie
inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.inameiname can self-interpret dreams as they happen.
 
Posts: 156
Karma: 20390
Join Date: Feb 2009
Device: none
Quote:
Originally Posted by geekmaster View Post
I used aplay to play movie output piped from ffmpeg on my kindle. I will publish a script soon to play movies on with sound on your kindles (from local files or internet URLs) in various formats (including x264 for the faster kindles). The K3 is not fast enough to decode x264 in real-time, so it can only play XviD/DivX/MPEG, etc.
Already seeing those threads that have samples of videos that can play on the Kindle, this would be awesome if you can run XviD/DivX/MPEG/etc files directly on it. Look forward to seeing what you come up with. You are definitely one of the best originators of stuff on this site! Thanks!


Quote:
Originally Posted by geekmaster View Post
I just tested, and you can still play audio files the old way too (including piped-in network streams). For example, with wifi on, this will play BBC on a K3 or a K5:

wget -O - http://mp32.bbc.streamuk.com | gst-launch playbin uri=fd://0
I'll have to try that way you mentioned about how to play streaming audio. This is the usual way I do so (I'm guessing it does the same thing, just a different way):

Code:
; play streaming radio - http://www.radioio.com - VOCAL JAZZ
K R F = !cd /mnt/us/music ; ../system/kinamp http://76.76.18.101:8010 -quiet -framedrop -vo aa:reverse:contrast=50 -vf rotate=1 -monitoraspect 0.7  2>/dev/null
inameiname is offline   Reply With Quote
Old 05-13-2012, 05:20 PM   #15
geekmaster
Всё гениальное просто.
geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.geekmaster ought to be getting tired of karma fortunes by now.
 
geekmaster's Avatar
 
Posts: 5,066
Karma: 6789001
Join Date: Nov 2011
Location: Щедрость не имеет пределов.
Device: *.*
Quote:
Originally Posted by inameiname View Post
I'll have to try that way you mentioned about how to play streaming audio. This is the usual way I do so (I'm guessing it does the same thing, just a different way):

Code:
; play streaming radio - http://www.radioio.com - VOCAL JAZZ
K R F = !cd /mnt/us/music ; ../system/kinamp http://76.76.18.101:8010 -quiet -framedrop -vo aa:reverse:contrast=50 -vf rotate=1 -monitoraspect 0.7  2>/dev/null
The difference is that kinamp is an add-on program, while the way I showed only uses built-in programs.

Your kinamp parameters look like the ones I posted many months ago for using with the optware mplayer, to play streaming VIDEO using "ascii art" mode in the myts terminal. Why do you use those VIDEO parameters with kinamp? Does kinamp support video now too? If so, we should be able to pipe that to my raw2gmv and gmplay programs (using different "better" video parameters). If not, then why are those video parameters on your command line?



Last edited by geekmaster; 07-02-2012 at 02:14 AM.
geekmaster is offline   Reply With Quote
Reply

Tags
launcher, launcher add-ons

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
GETTING AT the audio "file" I recorded (with Audio Recorder) Last_of_the_PEs enTourage eDGe 0 07-13-2011 01:30 AM
audio recorder Careermama enTourage Archive 5 02-17-2011 02:59 PM
How to Stop Audio Player? kenjennings enTourage Archive 0 04-19-2010 04:54 PM
Classic Audio Player ssbkt Barnes & Noble NOOK 1 12-18-2009 11:00 AM
Audio Player rfw Sony Reader 5 01-13-2007 01:25 PM


All times are GMT -4. The time now is 02:27 AM.


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