Jump to content

Barnes & Noble Nook Color (barnesnoble-encore)

From postmarketOS Wiki
Barnes & Noble Nook Color
Front of Nook Color
Front of Nook Color
Manufacturer Barnes & Noble
Name Nook Color
Codename barnesnoble-encore
Model BNRV200
Released 2010
Type tablet
Hardware
Chipset TI OMAP 3621
CPU 800 MHz Cortex-A8
GPU PowerVR SGX530
Display 1024x600
Storage 8 GB
Memory 512 MB
Architecture armv7
Software
Original software
The software and version the device was shipped with.
Android 2.2
Extended version
The most recent supported version from the manufacturer.
Android
FOSS bootloader partial
postmarketOS
Category testing
Mainline
Instead of a Linux kernel fork, it is possible to run (Close to) Mainline.
yes
pmOS kernel
The kernel version that runs on the device's port.
6.13.0
Unixbench score
Unixbench Whetstone/Dhrystone score. See Unixbench.
0.0
Device package device-barnesnoble-encore
Kernel package linux-postmarketos-omap
Features
Flashing
It is possible to flash the device with pmbootstrap flasher.
Untested
USB Networking
After connecting the device with USB to your PC, you can connect to it via telnet (initramfs) or SSH (booted system).
Works
Internal storage
eMMC, SD cards, UFS, ...
Works
SD card
Also includes other external storage cards
Works
Battery
Charging and battery level reporting works
Partial
Screen
Display works. Ideally with sleep mode and brightness control.
Partial
Touchscreen
Broken
Multimedia
3D Acceleration
Broken
Audio
Audio playback, microphone, headset and buttons.
Untested
Connectivity
WiFi
Broken
Bluetooth
Untested
Ethernet
Untested
Miscellaneous
USB OTG
USB On-The-Go or USB-C Role switching
Untested
Sensors
Accelerometer
Auto screen rotation works in desktops e.g. Phosh or Plasma Mobile
Partial
Haptics
Untested
Power Sensor
Sensor to monitor current, voltage and power. Not fuel gauge!
Untested


The Nook Color was released in 2010 with a restricted interface on top of Android intended for use as an e-reader with the Barnes & Noble ecosystem. It was fairly quickly discovered that the software could be modified and several versions of CyanogenMod (now LineageOS) were produced, allowing use of the device as a tablet.

Current Status

The device can be booted from a microSD card with the OMAP mainline kernel. A specific kernel config flag must be set and the kernel built to avoid fifo underflow errors. The display turns on on the first boot, but the touchscreen is not yet fully working/ configured correctly.

Most other components on the device are either working or seemingly close to working as there are drivers for most things.

Contributors

  • Scottc_vt

Users owning this device

  • Scottc vt (Notes: I am able to boot postmarketOS on it, working on pushing to postmarketOS and building out wiki page.)


Building Kernel

To avoid FIFO underflow errors when the display turns back on (after turning off), the mainline kernel currently needs to be built with the CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK flag set as shown below.

CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK=4

This can be found here in kernel configuration:

'Device Drivers'
 -> 'Graphics support' 
   -> 'Direct Rendering Manager'
     -> 'OMAP DRM'
       -> 'Minimum FCK/PCK ratio (for scaling)'

How to enter flash mode

Installation to microSD Card

Pre-Requisites

  • MLO - Secondary Program Loader, basically bootloader for bootloader
  • uboot.bin - bootloader
  • Script from the 'Background' section, below - save as 'mkcard.sh' or so

Using pmbootstrap

Follow Installation/Using pmbootstrap. When asked for the device's vendor/codename, select barnesnoble as the vendor and encore as the codename.

$ pmbootstrap install

$ pmbootstrap export

SD Card Setup Steps

Mount the generated postmarketOS image(s)

This can also be done with gnome-disks, etc if you prefer.

$ sudo kpartx -a -v /tmp/postmarketOS-export/barnesnoble-encore.img

<make note of "UUID" of fat32 boot partition - need to set same value with mkfs.vfat, below>

$ lsblk -o UUID /dev/mapper/loop0p1

Prep the SD Card

Ensure all existing partitions on card not mounted

$ ./mkcard.sh /dev/sdx

$ partprobe /dev/sdx

Copy postmarketOS to card

Set up boot partition - pmOS_boot
$ mkfs.vfat -F 32 -n pmOS_boot -i <uuid from above> /dev/sdx1

NOTE: uuid should not contain a dash in above command, ie -i 1234ABCD

Now, mount the new fat partition from /dev/sdx1.

Copy Bootloader files: MLO and u-boot.bin
$ cp <dir containing bootloader files>/MLO /../pmOS_boot/

$ cp <dir containing bootloader files>/u-boot.bin.edited /../pmOS_boot/u-boot.bin
Copy kernel and initramfs to pmOS_boot partition

Mount /dev/mapper/loop0p1, or other location where above kpartx command established device.

$ cp /<dir of mounted loop part1>/pmOS_boot1/uImage /../pmOS_boot/

$ cp /<dir of mounted loop part1>/pmOS_boot1/uInitrd /../pmOS_boot/uRamdisk

pmOS_boot partition should now look like this:

$ ls -1 /../pmOS_boot/
MLO
u-boot.bin
uImage
uRamdisk

Unmount /dev/mapper/loop0p1 (exported image) and/or copy more files if desired.

Copy pmOS_root partition
$ partclone.ext4 -b -d -s /dev/mapper/loop0p2 -o /dev/sdx2

Boot!

Insert microSD card into Nook Color and power on.


Background

SD Card Partitioning/ Formatting Requirements

  • Requires using fdisk and running it with two legacy flags in particular; -c=dos and -u=cylinders
  • Process previously laid out in detail here: omappedia.com: SD_Configuration

In short, steps are as follows:

  1. Unmount/ ensure card not mounted
  2. Zero first sector with dd
  3. Run sudo fdisk -l <sd card device> and find size of card in bytes, usually in first line of output
  4. Calculate number of cylinders
  5. Set number of heads, sectors and cylinders
  6. Create two partitions, the first one being fat, starting at cylinder 1, and being active

Script to partition card:

#! /bin/sh
# mkcard.sh v0.5
# Updated by Scott C based on script below
# (c) Copyright 2009 Graeme Gregory <dp@xora.org.uk>
# Licensed under terms of GPLv2
#
# Parts of the procedure base on the work of Denys Dmytriyenko
# http://wiki.omap.com/index.php/MMC_Boot_Format

export LC_ALL=C

if [ $# -ne 1 ]; then
        echo "Usage: $0 <drive>"
        exit 1;
fi

DRIVE=$1

dd if=/dev/zero of=$DRIVE bs=1024 count=1

SIZE=`fdisk -l $DRIVE | grep Disk | grep bytes | awk '{print $5}'`

echo DISK SIZE - $SIZE bytes

CYLINDERS=`echo $SIZE/255/63/512 | bc`

echo CYLINDERS - $CYLINDERS

fdisk -c=dos -u=cylinders $DRIVE <<< $'p\no\nx\nh\n255\ns\n63\nc\n'${CYLINDERS}$'\nr\nn\np\n1\n1\n+200M\nn\np\n2\n\n\nt\n1\nc\na\n1\nw\n'

Code and Development Resources

Board files located at: arch/arm/mach-omap2/board-encore{,-peripherals,display}.c

Display driver at: drivers/video/omap2/displays/panel-boxer.c

CyanogenMod

The CyanogenMod kernel is here: github - android_kernel_bn_encore

Original Kernel

This device was originally released using a circa 2.6.29 - 2.6.32.9 kernel which is available at the locations below:

Previous page on building original software: nookdevs.com Build the Original Kernel

zip package with Barnes & Noble source code

Resources With Nook Color Information

Most of these pages were created quite a while ago, but are still accessible and contain interesting information.

See also

External Resources and Earlier/Other Projects