Wednesday, May 7, 2014
Amazon Kindle 3.3 Sound Output FFMPEG
The following command is great for creating sound files for the Kindle:
ffmpeg -i 8bp027-04-nullsleep-playful_panda.mp3 -ar 8000 -ac 1 -acodec pcm_u8 panda.wav
Play the sound with the following:
aplay /tmp/panda.wav
Sunday, May 4, 2014
Compiling Linux kindle 2.6.26-rt-lab126 armv6l for Kindle 3
Device Supported
These instructions are specifically for the Kindle 3, the kernel version on the original device must be exactly: Linux kindle 2.6.26-rt-lab126 after the 3.3 firmware update from Amazon.ARM x64 Cross Compile Toolchain
I found and extracted the arm-2008q3 code sorcery tool-chain. (This one is older and most certainly compatible with the kernel verison)Linux Kernel Source
Get and Extract the linux-2.6.26-lab126.tar.bz2 from Amazon sources (under Kindle 3) Kindle_src_3.3_611680021.tar.gzApply kindle-3.3-kernel-buildfix.patch
patch -p1 < ./kindle-3.3-kernel-buildfix.patch
Generate .config file
make imx35_luigi_defconfig
Modify the following config setting to the following
CONFIG_INITRAMFS_SOURCE=""
Setup Build ENV
export ARCH=arm export CROSS_COMPILE=/home/thomas/workspace/arm-2008q3/bin/arm-none-linux-gnueabi-
Build Script
#!/bin/sh echo "=============Making make" make echo "=============Making uImage" make uImage echo "=============Making modules" make modules echo "=============Making modules tar at linux-2.6.26-rt-lab126.tar.gz" make targz-pkg echo "=============Making modules.dep" depmod -ae -F System.map -b tar-install -r 2.6.26-rt-lab126 -n > modules.dep # replace /kernel with /lib/modules/2.6.26-rt-lab126/kernel/ echo "=============Applying /kernel directory remapping" perl -pi -e 's/kernel\//\/lib\/modules\/2.6.26-rt-lab126\/kernel\//g' modules.dep echo "=============Outputing uImage, modules.dep and tared modules into ./export directory" mkdir ./export cp arch/arm/boot/uImage ./export/. cp modules.dep ./export/. cp linux-2.6.26-rt-lab126.tar.gz ./export/.
Flashing Kernel on Kindle
SCP the ./export folder contents to /tmp/. on your kindleExtract linux-2.6.26-rt-lab126.tar.gz to /lib/modules
Extract modules.dep to /lib/modules/2.6.26-rt-lab126
chmod 644 /lib/modules/2.6.26-rt-lab126/modules.dep /test/flashtools/luigi/update /tmp/uImage
Friday, March 21, 2014
How to Setup Perforce Merge p4merge with git in OSX
1. Download P4V.dmg (Perforce Client)
2. Copy the p4merge.app to your /Applications directory
3. Then run the following commands:
2. Copy the p4merge.app to your /Applications directory
3. Then run the following commands:
git config --global merge.tool p4merge
git config --global mergetool.p4merge.path /Applications/p4merge.app/Contents/Resources/launchp4merge
Sunday, October 27, 2013
Linux Mount OSX NFS Share
OSX
/etc/nfsd.conf
nfs.server.nfsd_threads = 20
nfs.server.tcp = 1
nfs.server.mount.require_resv_port=0
/etc/exports
/MYVOLUME -alldirs -32bitclients -maproot=root:wheel
LINUX
/etc/fstab
192.168.0.100:/MYVOLUME /MNTPOINT nfs sync,noresvport 0 0
LINUX
/etc/fstab
192.168.0.100:/MYVOLUME /MNTPOINT nfs sync,noresvport 0 0
Thursday, September 26, 2013
Hackintosh OSX for GA-Z77X-UDH3H
Note: I am using an ATI6850 -- an Nvidia card will have different installation instructions.
Creating the Mountain Lion OSX Boot USB
- Download OSX Mountain Lion 10.8.3
- Partition Drive as MBR with case in-sensitive journaling HFS+
- Install on 8GB+ USB drive with unibeast-1.7.0-gold.pkg (removes DMOS image checks)
- Rename /System/Library/Extensions/ATI6000Controller.kext to ATI6000Controller.bak
- Disable Virtualization in bios
- Boot with no additional boot flags
Fixing OSX after installation
- Boot with -x -f -v
- Run Multi-beast
- Chimera Bootloader v2.2
- Atheros ALXEthernet v1.0.2
- 10.8.3+ TRIM Patch
- Unzip Kexts OSX10.8.3.zip (from OSX folder in dropbox)
- Install all of the kexts (ATI, AppleHDA, USBXHCI) with kext utility
- Unzip Extra.tgz (from OSX folder in dropbox)
- Copy custom.aml to /Extra
- Copy org.chamelon.Boot.plist to /Extra
BAM PERFECT HACKINTOSH!
Note: If anyone is interested in obtained any of the files mentioned about, please make a post in the comments or send me an email.
Sunday, December 2, 2012
nRF24L01 2.4GHz RF Linux-Joystick Controlled Arduino Based Plane
How Transmitter Works:
Joystick -> Linux OS -> ardjoy Program -> Arduino 1 with TX code -> Transmits Joystick Info
How Receiver Works:
Receives Joystick Info -> Arduino 2 with RX code -> Controls Plane Servos and ESC
What you need:- 2 Arduino's
- 2 nRF24L01 2.4Ghz RF devices
- IDE cable (optional, to connect nRF24L01 to Arduino)
- Linux OS with joystick support
- USB/Serial Joystick that works with Linux
Downloading and Compiling Code
mkdir -p ~/workspace
cd ~/workspace
git clone https://github.com/thomas41546/rc_plane_arduino_joystick.git
make
NOTE: the ardjoy code may need to be modified for joystick other than a ps2 controller.
Connect each nRF24L01 to each Arduino
Here is a goodlink to help you do that:
http://arduino-info.wikispaces.com/Nrf24L01-2.4GHz-HowTo
Upload Arduino Code (Arduino Sketch files are found in the git repository above)
- Install NRF arduino libraries (https://github.com/thomas41546/RF24.git)
- Upload sketch ardJoyRX.ino on Arduino 1
- Upload sketch ardJoyTX.ino on Arduino 2
Setting up the transmitter
- Connect Joystick to Linux OS
- Verify that you have a /dev/input/js0 joystick device file
- Connect the Arduino 1 to the Linux OS
- Verify that you have a /dev/ttyUSB0 arduino device file
- Run the following command "./ardjoy /dev/input/js0 /dev/ttyUSB0 115200"
- Your Arduino should now be transmitting joystick information
Setting up the receiver (TODO, THIS IS INCOMPLETE)
- Connect the Arduino 2 to the RC plane
- Power the Arduino 2
- You should now have the servo and ESC move in response to joystick inputs.
Monday, November 19, 2012
Compiling Nook Color Kernel
Setup and Building Nook Kernel
Setup working directory
mkdir ~/nc
cd ~/nc
Grab kernel and arm-toolkit
git clone https://github.com/CyanogenMod/android_kernel_bn_encore.git
git clone https://android.googlesource.com/platform/prebuilt
Copy config file from nook device to our kernel directory.
Make sure you nook is plugged into the computer via USB with ADB enabled.
cd ~/nc/android_kernel_bn_encore adb pull /proc/config.gz . gunzip config.gz mv config .config
Setup environmental variable to for our ARM toolchain
export ARMTOOLCHAIN=~/nc/prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/arm-linux-androideabi-
Run menuconfig and select your kernel options
make ARCH=arm CROSS_COMPILE=$ARMTOOLCHAIN menuconfig
Build the kernel to uImage format (replace -jX where X is the number of CPU's you have)
make ARCH=arm CROSS_COMPILE=$ARMTOOLCHAIN -j4 uImage
You will now have built a kernel, the uImage is located at ~/nc/android_kernel_bn_encore/arch/arm/boot/uImage
Installing Kernel uImage
Grab a kernel-update zip file, such as the 1.2GHZ overclock kernel update zip below.
You can use a nightly update zip as well, it doesn't really matter as long as there is a ./kernel file to replace in the zip archive.
mkdir -p ~/nc/update
Download update zip from here: https://docs.google.com/open?id=0B471Nt_V1052eHpuS05oWTIzZ3M and place it into ~/nc/update
unzip *.zip rm kernel cp ~/nc/android_kernel_bn_encore/arch/arm/boot/uImage kernel
zip -r update.zip kernel MLO ramdisk.img u-boot.bin META-INF/
adb push ./update.zip /sdcard/update.zip
Installing Update
Boot into recovery mode and install the /sdcard/update.zip
Conclusion
You should now be running a custom compiled kernel, you now have complete control of your device.
Other repositories:
https://github.com/thomas41546/android_kernel_bn_encore - Here is the github of my over-clocked and stable 1.2ghz kernel, a note of caution I used 1.4v overvolt -- which should be fine but I am not liable for any damages.
https://github.com/dalingrin/nook_kernel/commits/encore-32 - Here is the github of the dalingrin kernel for CM7, you can use this information to port features in your kernel.
Subscribe to:
Posts (Atom)