{
    "ok": true,
    "data": {
        "title": "DR-0001",
        "rev_id": 16576,
        "updated_at": "2026-08-21T06:17:30+00:00",
        "chunk_count": 54,
        "chunks": [
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "",
                "chunk_index": 0,
                "content": "# DR-0001",
                "char_count": 9,
                "token_estimate": 3
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "1U Rackmount for Raspberry Pi 5",
                "chunk_index": 1,
                "content": "- Purchase URL: [ https:\/\/52pi.com ] or [ https:\/\/deskpi.com ]\n[right|320px](\/docs\/File:DR-0001-1.jpg)",
                "char_count": 102,
                "token_estimate": 26
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Description",
                "chunk_index": 2,
                "content": "This is an upgraded version of a 1U Rackmount designed for compatibility with both Raspberry Pi 5 . It features a motherboard that supports PCIe expansion, allowing the PCIe interface of the Raspberry Pi 5 to be extended to accommodate an M.2 NVMe SSD in 2230\/2242\/2260\/2280 form factors. The expansion board also routes the Raspberry Pi's 5V and GND, SDA, and SCL pins to the rear through PogoPin connectors, providing I2C interface peripherals in a Grove format. Additionally, a red LED is included on the board for the Raspberry Pi ID signal pin, which can be programmed to indicate the current device by controlling the GPIO4 pin's high or low level, acting as a programmable device ID signal light.",
                "char_count": 703,
                "token_estimate": 176
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Description",
                "chunk_index": 3,
                "content": "The Rackmount supports the connection of up to five Raspberry Pi devices and can also be configured with an OLED display frame in place of one of the Raspberry Pi slots. These components can be easily adjusted and removed due to the use of hand-tightened screws. The OLED display features a 0.91-inch screen and communicates with the Raspberry Pi via I2C protocol, displaying real-time information such as CPU status, memory status, IP information, and serial numbers. The content displayed on the OLED can be fully customized.",
                "char_count": 527,
                "token_estimate": 132
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Features",
                "chunk_index": 4,
                "content": "- <strong>Compatibility:<\/strong> Designed to work with both Raspberry Pi 5.\n- <strong>PCIe Expansion Support:<\/strong>  Includes a motherboard that enables PCIe expansion, allowing the connection of M.2 NVMe SSDs in various form factors (2230\/2242\/2260\/2280).\n- <strong>I2C Interface: <\/strong> The board routes the Raspberry Pi's 5V, GND, SDA, and SCL pins to the rear through PogoPin connectors, offering I2C interface peripherals in a Grove format.\n- <strong>Programmable LED Indicator: <\/strong> A red LED on the board serves as a programmable device ID signal, controllable via the GPIO4 pin to indicate the status or identity of the device.\n- <strong>Modular Design:<\/strong>  Supports the integration of up to five Raspberry Pi devices, with the option to replace one slot with an OLED display frame.\n- <strong>OLED Display Integration:<\/strong>  The option to include a 0.91-inch OLED screen that communicates with the Raspberry Pi via I2C, displaying customizable information such as CPU usage, memory status, IP address, and serial numbers.",
                "char_count": 1051,
                "token_estimate": 263
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Features",
                "chunk_index": 5,
                "content": "- <strong>Easy Assembly and Disassembly:<\/strong>  Components are secured with hand-tightened screws, allowing for convenient adjustments and removal.\n- <strong>Customizable Display Content: <\/strong> The information displayed on the OLED screen can be fully customized to meet specific needs or preferences.\n- <strong>Rackmount Form Factor: <\/strong> Designed to fit into a 1U rack space, making it suitable for data centers or other environments where space is at a premium.\n- <strong>Versatility:<\/strong>  The Rackmount can be configured in various ways to suit different use cases, whether for development, testing, or deployment in a production environment.",
                "char_count": 663,
                "token_estimate": 166
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Features > Specifications",
                "chunk_index": 6,
                "content": "- Form Factor: 1U Rackmount design suitable for standard 19-inch racks.\n- Raspberry Pi Compatibility: Specifically designed for Raspberry Pi 5.\n- PCIe Expansion:Supports M.2 NVMe SSDs in 2230, 2242, 2260, and 2280 form factors. Provides a PCIe interface for high-speed data transfer.\n- I\/O Connectivity: Rear I2C interface via PogoPin connectors for external peripherals.\n- GPIO4 pin for programmable LED control.\n- LED Indicator:Red LED for device identification or status indication. Programmable through software to show different statuses.\n- Modular Bays: Five bays for Raspberry Pi devices. One bay can be replaced with an OLED display module.\n- OLED Display Specifications:0.91-inch screen size, 128x32 pixels. I2C communication protocol.\n- Customizable display for system information.\n- Physical Security:Hand-tightened screws for secure mounting of Raspberry Pi devices and OLED display.\n- Ensures stability and ease of maintenance.\n- Power Requirements: Compatibility with Raspberry Pi's standard power supply.\n- Material and Construction: Durable metal construction for the rackmount chassis. High-quality components for reliable performance.",
                "char_count": 1152,
                "token_estimate": 288
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Features > Specifications",
                "chunk_index": 7,
                "content": "- Mounting Options: Standard rackmount holes for easy installation into a rack.\n- Includes additional mounting accessories for different setups.\n- Software Compatibility: Compatible with Raspberry Pi's operating system and software ecosystem.\n- Support for GPIO programming for custom LED and device control.",
                "char_count": 308,
                "token_estimate": 77
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Gallery",
                "chunk_index": 8,
                "content": "- Product outlook\n[left|800px](\/docs\/ File:DR-0001-6.jpg )\n<br style=\"clear:both\":>\n\n- Application Senario\n[left|800px](\/docs\/ File:DR-0001-2.jpg )\n<br style=\"clear:both\":>\n NOTE: Raspberry Pis are not included in the package, additional purchase required!\n\n- Easy to assemble and maintain\n[left|800px](\/docs\/ File:DR-0001-3.jpg )\n<br style=\"clear:both\":>\n[left|800px](\/docs\/File:DR-0001-12.jpg)\n<br style=\"clear:both\":>\n\n- Customizable OLED display screen, with a size of 0.91 inches\n[left|800px](\/docs\/ File:DR-0001-4.jpg )\n<br style=\"clear:both\":>\n\n- Ports Definitions and Featrues\nProgrammable I\/O controlled UID indicator light, which can be programmed to control the LED blinking to indicate the device's location, facilitating faster troubleshooting and easier maintenance operations.\n[left|800px](\/docs\/ File:DR-0001-5.jpg )\n<br style=\"clear:both\":>",
                "char_count": 857,
                "token_estimate": 215
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Gallery > How to connect OLED display to Raspberry Pi on GPIO pins",
                "chunk_index": 9,
                "content": "- Please refer to following figure to connect OLED display to Raspberry Pi on GPIO.\nNOTE: OLED's VCC should be connected to 3.3V power rail, Do not connect it to 5V power rail!!!\n\n[left|800px](\/docs\/ File:DR-0001-7.jpg )\n<br style=\"clear:both\":>\n\n- Grove Connector Support I2C and Uart\n[left|800px](\/docs\/ File:DR-0001-8.jpg )\n<br style=\"clear:both\":>\n\n- Accessories Dimension\n[left|800px](\/docs\/ File:DR-0001-9.jpg )\n<br style=\"clear:both\":>\n\n- OLED assemble details\nPlease remove the protection film from acrylic panel and use the washer between OLED PCB board and acrylic panel.\n[left|800px](\/docs\/ File:DR-0001-10.jpg )\n<br style=\"clear:both\":>\n\n- PCIe Expansion board for Raspberry Pi 5 only\nThe expansion board supports M.2 NVMe M-key SSD 2230\/2242\/2260\/2280, and the board will be powered by Raspberry Pi 5 via PogoPin on the PCB board, please make sure the board's pogoins are contact well with the soldering point on back of the Raspberry Pi 5 on GPIO pins.\n[left|800px](\/docs\/File:DR-0001-11.jpg)\n<br style=\"clear:both\":>",
                "char_count": 1031,
                "token_estimate": 258
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to assemble it?",
                "chunk_index": 10,
                "content": "- Please note that there are several details you need to pay attention, plesae check out following figure.\n[left|800px](\/docs\/ File:DR-0001-安装.jpg)\n<br style=\"clear:both\";>",
                "char_count": 172,
                "token_estimate": 46
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Package Includes",
                "chunk_index": 11,
                "content": "- Following figure shows the details of the product:\n[left|800px](\/docs\/ File:DR-0001-清单.jpg)\n<br style=\"clear:both\";>",
                "char_count": 118,
                "token_estimate": 32
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable I2C OLED display?",
                "chunk_index": 12,
                "content": "- We assume that you are using Raspberry Pi OS 64bit(bookworm, the latest official image)\nTo enable I2C and UART on your Raspberry Pi, you can follow these detailed steps:",
                "char_count": 171,
                "token_estimate": 43
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable I2C OLED display? > Enabling I2C",
                "chunk_index": 13,
                "content": "- Method 1. Using the Raspberry Pi Configuration Tool:\n<pre>\nsudo raspi-config\n<\/pre>\nto open the configuration tool. Navigate to `Interface Options`, Select `I2C` and enable it.\n\n- Method  2. Using the Command Line:\nYou can also enable I2C by editing the `\/boot\/firmware\/config.txt` file and adding `dtparam=i2c_arm=on` if it's not already present, After making changes, reboot your Pi.",
                "char_count": 387,
                "token_estimate": 97
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable I2C OLED display? > Verifying I2C",
                "chunk_index": 14,
                "content": "- Install I2C tools using `sudo apt-get install -y i2c-tools`.\n- Use\n<pre>\ni2cdetect -y 1\n<\/pre>\nto scan for I2C devices, if you see `3c` means that the OLED display has been recognized by your Raspberry Pi.",
                "char_count": 207,
                "token_estimate": 52
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable I2C OLED display? > Enabling UART",
                "chunk_index": 15,
                "content": "- Method 1. Using the Raspberry Pi Configuration Tool:\n<pre>\nsudo raspi-config\n<\/pre>\nGo to `Interface Options`, Select `Serial` and enable it.\n<pre> Note: This will also enable the login shell on the serial port. <\/pre>\n\n- Method 2. Using the Command Line:\nEdit `\/boot\/config.txt` and add `enable_uart=1`, save it and then reboot your Pi.",
                "char_count": 339,
                "token_estimate": 85
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable I2C OLED display? > Accessing UART",
                "chunk_index": 16,
                "content": "- Connect your Pi to a USB-to-TTL converter, On Windows, you may need to install drivers for the converter. on Linux just use a terminal program like `minicom`, `putty`, or `screen` to access the UART interface.\n\nRemember to check the documentation for your specific Raspberry Pi model, as the steps might vary slightly. If you need more detailed instructions or encounter any issues, refer to the [ https:\/\/www.raspberrypi.org\/documentation\/ ]  or community forums for additional support.",
                "char_count": 489,
                "token_estimate": 123
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable I2C OLED display? > How to display customized information on OLED display?",
                "chunk_index": 17,
                "content": "- Final result\n[left|800px](\/docs\/File:DR-0001 applications-01.jpg)\n<br style=\"clear:both\";>",
                "char_count": 92,
                "token_estimate": 23
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ?",
                "chunk_index": 18,
                "content": "- For example: If you want to display current IP address of wlan interface and the serial number of your Raspberry Pi 5, please follow next steps to configure it.",
                "char_count": 162,
                "token_estimate": 41
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ? > Install Virtal environment package",
                "chunk_index": 19,
                "content": "- Open a terminal and typing following commands:\n<pre>\nsudo apt update\nsudo apt upgrade -y\nsudo apt -y install virtualenv\nsudo usermod -a -G i2c,spi,gpio pi\nsudo apt install python3-dev python3-pip python3-numpy libfreetype6-dev libjpeg-dev build-essential\nsudo apt install libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-ttf-dev libportmidi-dev\n<\/pre>\n[left|800px](\/docs\/File:Install pre-insistpackages.png)\n<br style=\"clear:both\";>\n[left|800px](\/docs\/File:Install-pre-insistpackage-02.png)\n<br style=\"clear:both\";>",
                "char_count": 524,
                "token_estimate": 131
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ? > Create virtual environment",
                "chunk_index": 20,
                "content": "<pre>\nvirtualenv -p python3 venv\ncd venv\/\nsource bin\/activate\n<\/pre>",
                "char_count": 68,
                "token_estimate": 17
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ? > Install SSD1306 driver and library for OLED 0.91",
                "chunk_index": 21,
                "content": "<pre>\npip install luma.oled\npip install psutil\n<\/pre>",
                "char_count": 53,
                "token_estimate": 14
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ? > Clone luma.examples repository",
                "chunk_index": 22,
                "content": "Log out and in again and clone this repository:\n<pre>\ngit clone https:\/\/github.com\/rm-hull\/luma.examples.git\ncd luma.examples\/\n<\/pre>",
                "char_count": 133,
                "token_estimate": 34
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ? > Install luma libraries",
                "chunk_index": 23,
                "content": "<pre>\nsudo -H pip install -e . --break-system-packages\n<\/pre>\n[left|800px](\/docs\/File:Install luma libraries.png)\n<br style=\"clear:both\";>",
                "char_count": 138,
                "token_estimate": 35
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to customize content on OLED ? > Test the demo",
                "chunk_index": 24,
                "content": "<pre>\ncd examples\/\nsudo python 3d_box.py --width=128 --height=32 -r 2\n<\/pre>\n\n<p>NOTE:\n\n --width=128 and --height=32 should be added to declear the OLED's resolution information.\n\n -r 2  means --rotate 2 , Allowed values are: 0, 1, 2, 3  (default:0)\n<\/p>\n\nIf you see a 3D-box rotating animation is in the middle of screen means that you have installed the OLED driver successfully!\n[left|800px](\/docs\/File:Test demo 3dbox.png)\n<br style=\"clear:both\";>\n[left|800px](\/docs\/File:Test demo 3dbox-2.png)\n<br style=\"clear:both\";>\nand then press \"Ctrol+C\" abort the demo.",
                "char_count": 564,
                "token_estimate": 141
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code",
                "chunk_index": 25,
                "content": "- There are a lot of demo codes in the examples folder, you can test it as you want.\nfor example:\n<pre>\nsudo python carousel.py --width=128 --height=32 -r 2\n<\/pre>\nIt will display all information of your Raspberry Pi 5 and scrolling display.",
                "char_count": 241,
                "token_estimate": 61
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Customize the display on screen",
                "chunk_index": 26,
                "content": "Modify the sys_info.py python file and adding your own function to show the information you want, do remember backup the origin file.\n<pre>\ncp sys_info.py sys_info.py.bak\nvim.tiny sys_info.py\n<\/pre>\nPress 'i' to insert mode, and paste following lines into it. you can modify this file by other text editor what you like.\n<pre>\n#!\/usr\/bin\/env python\n1. -*- coding: utf-8 -*-\n1. Copyright (c) 2014-2022 Richard Hull and contributors\n1. See LICENSE.rst for details.\n1. PYTHON_ARGCOMPLETE_OK\n\n\"\"\"\nDisplay basic system information.\n\nNeeds psutil (+ dependencies) installed::\n\n$ sudo apt-get install python-dev\n  $ sudo -H pip install psutil\n\"\"\"\n\nimport os\nimport sys\nimport time\nfrom pathlib import Path\nfrom datetime import datetime\nimport subprocess as sp\n\nif os.name != 'posix':\n    sys.exit(f'{os.name} platform is not supported')\n\nfrom demo_opts import get_device\nfrom luma.core.render import canvas\nfrom PIL import ImageFont\n\ntry:\n    import psutil\nexcept ImportError:\n    print(\"The psutil library was not found. Run 'sudo -H pip install psutil' to install it.\")\n    sys.exit()\n\n1. TODO: custom font bitmaps for up\/down arrows\n1. TODO: Load histogram",
                "char_count": 1152,
                "token_estimate": 288
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Customize the display on screen",
                "chunk_index": 27,
                "content": "def bytes2human(n):\n    \"\"\"\n    >>> bytes2human(10000)\n    '9K'\n    >>> bytes2human(100001221)\n    '95M'\n    \"\"\"\n    symbols = ('K', 'M', 'G', 'T', 'P', 'E', 'Z', 'Y')\n    prefix = {}\n    for i, s in enumerate(symbols):\n        prefix[s] = 1 << (i + 1) * 10\n    for s in reversed(symbols):\n        if n >= prefix[s]:\n            value = int(float(n) \/ prefix[s])\n            return '%s%s' % (value, s)\n    return f\"{n}B\"\n\ndef cpu_usage():\n    # load average, uptime\n\nuptime = datetime.now() - datetime.fromtimestamp(psutil.boot_time())\n    #av1, av2, av3 = os.getloadavg()\n    #return \"Ld:%.1f %.1f %.1f Up: %s\" \\\n    #    % (av1, av2, av3, str(uptime).split('.')[0])\n\nreturn \"Up: %s\" % (str(uptime).split('.')[0])\n\ndef mem_usage():\n    usage = psutil.virtual_memory()\n    return \"Mem: %s %.0f%%\" \\\n        % (bytes2human(usage.used), 100 - usage.percent)\n\ndef disk_usage(dir):\n    usage = psutil.disk_usage(dir)\n    return \"SD:  %s %.0f%%\" \\\n        % (bytes2human(usage.used), usage.percent)\n\ndef network(iface):\n    stat = psutil.net_io_counters(pernic=True)[iface]\n    return \"%s: Tx%s, Rx%s\" % \\\n           (iface, bytes2human(stat.bytes_sent), bytes2human(stat.bytes_recv))",
                "char_count": 1179,
                "token_estimate": 295
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Customize the display on screen",
                "chunk_index": 28,
                "content": "def mem_usage():\n    usage = psutil.virtual_memory()\n    return \"Mem: %s %.0f%%\" \\\n        % (bytes2human(usage.used), 100 - usage.percent)\n\ndef disk_usage(dir):\n    usage = psutil.disk_usage(dir)\n    return \"SD:  %s %.0f%%\" \\\n        % (bytes2human(usage.used), usage.percent)\n\ndef network(iface):\n    stat = psutil.net_io_counters(pernic=True)[iface]\n    return \"%s: Tx%s, Rx%s\" % \\\n           (iface, bytes2human(stat.bytes_sent), bytes2human(stat.bytes_recv))\n\ndef get_ip_address():\n    ip = sp.getoutput('hostname -I')\n    return \"IP: %s\" % ip\n\ndef get_id():\n    id_of_pi = sp.getoutput(\"cat \/proc\/cpuinfo | grep -i serial| awk -F: '{print $2}'|xargs\")\n    return \"%s\" % id_of_pi\n\ndef stats(device):\n    # use custom font\n\nfont_path = str(Path().resolve().parent.joinpath('fonts', 'C&C Red Alert [INET].ttf'))\n    #font_path = str(Path().resolve().parent.joinpath('fonts', 'DejaVuSansMono.ttf'))\n    font2 = ImageFont.truetype(font_path, 15)\n\nwith canvas(device) as draw:\n        # draw.text((0, 0), cpu_usage(), font=font2, fill=\"white\")",
                "char_count": 1043,
                "token_estimate": 261
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Customize the display on screen",
                "chunk_index": 29,
                "content": "draw.text((0, 0), get_id(), font=font2, fill=\"white\")\n        if device.height >= 32:\n            #draw.text((0, 11), mem_usage(), font=font2, fill=\"white\")\n            #draw.text((0, 16), disk_usage('\/'), font=font2, fill=\"white\")\n            draw.text((0, 16), get_ip_address(), font=font2, fill=\"white\")\n\nif device.height >= 64:\n            draw.text((0, 26), disk_usage('\/'), font=font2, fill=\"white\")\n            try:\n                draw.text((0, 38), network('wlan0'), font=font2, fill=\"white\")\n            except KeyError:\n                # no wifi enabled\/available\n\npass\n\ndef main():\n    while True:\n        stats(device)\n        time.sleep(5)\n\nif  == \"\":\n    try:\n        device = get_device()\n        main()\n    except KeyboardInterrupt:\n        pass\n<\/pre>\nHere let me explain to you what i did.\n- adding \" import subprocess as sp\", this will help me to execute some shell command in OS.\n- adding following parts:\n<pre>\ndef get_ip_address():\n    ip = sp.getoutput('hostname -I')\n    return \"IP: %s\" % ip",
                "char_count": 1016,
                "token_estimate": 254
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Customize the display on screen",
                "chunk_index": 30,
                "content": "def get_id():\n    id_of_pi = sp.getoutput(\"cat \/proc\/cpuinfo | grep -i serial| awk -F: '{print $2}'|xargs\")\n    return \"%s\" % id_of_pi\n<\/pre>\n- get_ip_address will execute the command \"hostname -I\" in system and grab the IP address and return it to main process.\n- get_id is to read \/proc\/cpuinfo file and grab the serial number and return to main process.",
                "char_count": 356,
                "token_estimate": 89
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Use custom font",
                "chunk_index": 31,
                "content": "<pre>\n   font_path = str(Path().resolve().parent.joinpath('fonts', 'C&C Red Alert [INET].ttf'))\n   font2 = ImageFont.truetype(font_path, 15)   # change font size to 15.\n\n<\/pre>",
                "char_count": 176,
                "token_estimate": 44
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Use the demo code > Modify the draw function",
                "chunk_index": 32,
                "content": "<pre>\n  with canvas(device) as draw:\n        # draw.text((0, 0), cpu_usage(), font=font2, fill=\"white\")\n\n        draw.text((0, 0), get_id(), font=font2, fill=\"white\")         #####　draw id on screen at (0,0) position, (x,y)\n        if device.height >= 32:\n            #draw.text((0, 11), mem_usage(), font=font2, fill=\"white\")\n            #draw.text((0, 16), disk_usage('\/'), font=font2, fill=\"white\")\n            draw.text((0, 16), get_ip_address(), font=font2, fill=\"white\")   ####　draw text on (0,16) with IP address.\n<\/pre>",
                "char_count": 527,
                "token_estimate": 132
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to create a systemd file to make it automatically start at boot up",
                "chunk_index": 33,
                "content": "- Step1. create a shell script called it 'start_led.sh'\n<pre>\n#!\/bin\/bash\n1. cd \/home\/pi\/venv\/ && source \/home\/pi\/venv\/bin\/activate\n\/usr\/bin\/python3 \/home\/pi\/luma.examples\/examples\/sys_info.py --width=128 --height=32 -r 2\n<\/pre>\nsave it and grant executable permission and test it.\n<pre>\nchmod +x start_led.sh\n.\/start_led.sh\n<\/pre>\nIf if works properly, just press \"ctrol+c\" to abort the test.\n- Step2. create a systemd file and enable it.\n<pre>\nsudo vim.tiny \/etc\/systemd\/system\/rackmount_oled.service\n<\/pre>\nAnd then, adding following lines:\n<pre>\n[Unit]\nDescription=Rackmount OLED service on RPi5\nDefaultDependencies=no\nStartLimitIntervalSec=60\nStartLimitBurst=5\n\n[Service]\nType=simple\nExecStart=\/bin\/bash \/home\/pi\/start_led.sh\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n<\/pre>\nSave it and quit.",
                "char_count": 813,
                "token_estimate": 204
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to create a systemd file to make it automatically start at boot up > Enable rackmount_oled.service",
                "chunk_index": 34,
                "content": "- reload daemon\n<pre>\nsudo systemctl daemon-reload\n<\/pre>\n\n- Enable service\n<pre>\nsudo systemctl enable rackmount_oled.service\n<\/pre>\n- Start service\n<pre>\nsudo systemctl start rackmount_oled.service\n<\/pre>\n- Restart service\n<pre>\nsudo systemctl restart rackmount_oled.service\n<\/pre>\n- Stop service\n<pre>\nsudo systemctl stop rackmount_oled.service\n<\/pre>\n- Disable service\n<pre>\nsudo systemctl disable rackmount_oled.service\n<\/pre>",
                "char_count": 431,
                "token_estimate": 108
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable PCIe function on Raspberry Pi 5?",
                "chunk_index": 35,
                "content": "- To enable PCIe functionality on the Raspberry Pi 5, follow these steps:",
                "char_count": 73,
                "token_estimate": 19
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable PCIe function on Raspberry Pi 5? > 1. Enable the PCIe External Connector:",
                "chunk_index": 36,
                "content": "By default, the PCIe connector on the Raspberry Pi 5 is not enabled. To enable it, you need to add a configuration parameter to the `config.txt` file located in the `\/boot\/firmware` directory. You can use either of these lines:\n<pre>\ndtparam=pciex1\n<\/pre>\nAfter adding the line, reboot your Raspberry Pi for the changes to take effect.",
                "char_count": 335,
                "token_estimate": 84
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable PCIe function on Raspberry Pi 5? > 2.Enable PCIe Gen 3.0 (Optional):",
                "chunk_index": 37,
                "content": "The Raspberry Pi 5's PCIe connection is certified for Gen 2.0 speeds. However, if you want to attempt using Gen 3.0 speeds, add the following line to the `config.txt` file as well:\n<pre>\ndtparam=pciex1_gen=3\n<\/pre>\n Be aware that the Raspberry Pi 5 is not certified for Gen 3.0 speeds, and using this setting may result in instability .",
                "char_count": 336,
                "token_estimate": 84
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable PCIe function on Raspberry Pi 5? > 3.Booting from PCIe:",
                "chunk_index": 38,
                "content": "If you intend to boot from a device connected via PCIe, such as an NVMe SSD, you will need to modify the boot order in the EEPROM. Use the following command to edit the EEPROM configuration:\n<pre>\nsudo apt update\nsudo apt upgrade -y\nsudo rpi-eeprom-config --edit\n<\/pre>\nThen, change the `BOOT_ORDER` line to include NVMe in the boot order:\n<pre>\nBOOT_ORDER=0xf416\n<\/pre>\nThis setting will make the Raspberry Pi attempt to boot from an NVMe device connected to the PCIe port .",
                "char_count": 475,
                "token_estimate": 119
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to enable PCIe function on Raspberry Pi 5? > 4. Kernel Compilation (Advanced):",
                "chunk_index": 39,
                "content": "If you need to compile the kernel to add support for specific PCIe devices, you can follow the steps outlined in the Raspberry Pi documentation. This involves cloning the Raspberry Pi kernel repository, configuring the kernel with `make menuconfig`, and enabling the necessary modules for your devices .\nRemember to always check the compatibility of the devices you intend to use with the Raspberry Pi 5's PCIe interface, as not all devices may be supported out of the box.",
                "char_count": 473,
                "token_estimate": 119
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to light up identical LED?",
                "chunk_index": 40,
                "content": "To light up UID LED indicator on a Raspberry Pi 5, you'll make sure the GPIO Pin of the UID LED connected to.\n<pre>\nGPIO (General Purpose Input\/Output) pins on the Raspberry Pi.\n<\/pre>",
                "char_count": 184,
                "token_estimate": 46
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to light up identical LED? > Steps",
                "chunk_index": 41,
                "content": "- 1. Identify GPIO Pins: GPIO4\n\n- 2. Power On:\nMake sure your Raspberry Pi is powered off before connecting the LED. Once everything is connected, you can power on your Raspberry Pi.\n\n- 3. Software Setup:\nYou'll need to write a small program to turn the GPIO pin on and off to control the LED. You can use Python with the `gpiozero` library or `RPi.GPIO` library to control the GPIO pins.",
                "char_count": 388,
                "token_estimate": 97
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to light up identical LED? > Example Python Code with gpiozero:",
                "chunk_index": 42,
                "content": "<pre>\nfrom gpiozero import LED\nfrom time import sleep\n\nled = LED('GPIO4')\n\nwhile True:\n    led.on()\n    sleep(1)\n    led.off()\n    sleep(1)\n<\/pre>",
                "char_count": 146,
                "token_estimate": 37
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to light up identical LED? > Example Python Code with RPi.GPIO:",
                "chunk_index": 43,
                "content": "<pre>\nimport RPi.GPIO as GPIO\nimport time\n\n1. Set the GPIO mode\nGPIO.setmode(GPIO.BCM)\n\nGPIO_PIN = 4\n\n1. Set up the GPIO pin as an output channel\nGPIO.setup(GPIO_PIN, GPIO.OUT)\n\nwhile True:\n    GPIO.output(GPIO_PIN, GPIO.HIGH)  # Turn on the LED\n\n    time.sleep(1)\n    GPIO.output(GPIO_PIN, GPIO.LOW)   # Turn off the LED\n\n    time.sleep(1)\n\n1. Clean up the GPIO pins before exiting the program\nGPIO.cleanup()\n<\/pre>",
                "char_count": 416,
                "token_estimate": 104
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "How to light up identical LED? > Safety Tips:",
                "chunk_index": 44,
                "content": "- Be careful not to short any pins on the Raspberry Pi.",
                "char_count": 55,
                "token_estimate": 14
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > SSD1306 OLED Black-Screen Debugging Report & Operation Guide",
                "chunk_index": 45,
                "content": "<strong>Target hardware:<\/strong> 0.91\" OLED, 128×32 px, SSD1306, I2C, address 0x3C, Raspberry Pi 5\n<strong>Software:<\/strong> luma.oled 3.15.0, luma.core 2.6.0, Python 3.13, smbus2",
                "char_count": 181,
                "token_estimate": 46
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > 1. Executive Summary — What Was Actually Wrong",
                "chunk_index": 46,
                "content": "<strong>Nothing was wrong with the code, the luma library, or the SSD1306 register configuration.<\/strong>\nNo library or example source code was modified. The failures came from hardware and\nconfiguration, in one layers:\n\n<strong>A parameter mismatch in the examples.<\/strong>  The examples in this directory default to\n  `ssd1305 \/ 128×64`; this panel is `ssd1306 \/ 128×32`. Running without parameters\n  produces a black or garbled screen. The fix is to pass the correct display, interface,\n  geometry and address — done via the config file `ssd1306_128x32.conf`.\n\n- ssd1306_128x32.conf contents:\n<pre>\n--display=ssd1306\n--interface=i2c\n--i2c-port=1\n--i2c-address=0x3c\n--width=128\n--height=32\n<\/pre>\nPut this configuration file to your demo code location:\n[left| 800px ](\/docs\/ File:Democodeconfig.png)\n<br style=\"clear:both;\">\n- How to execute with config file\n<pre>\nsudo python3 demo.py -f ssd1306_128x32.conf\n<\/pre>",
                "char_count": 919,
                "token_estimate": 230
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > 2. What Was Done, Step by Step (Method and Basis)",
                "chunk_index": 47,
                "content": "{| class=\"wikitable\"\n     |+ Diagnosis — locating the fault\n     ! Method !! Basis \/ Reasoning\n     |-\n     | Bus scan with <code>i2cdetect<\/code> || An ACK at 0x3C proves all four wires\n   (VCC\/GND\/SDA\/SCL) are connected and the driver IC is powered\n     |-\n     | Source inspection of ssd1306 in luma.oled 3.15.0 || The 128×32 init sequence\n   (multiplex 0x1F, compins 0x02, charge pump 0x14) matches the datasheet standard — a\n   register-level bug was ruled out on evidence\n     |-\n     | Raw-register write of 0xA5 (force all-on) || This command bypasses GDDRAM; a\n   healthy panel must glow. No light = fault in the high-voltage path (charge pump \/\n   panel \/ flex cable)\n     |-\n     | Status-register read before\/after DISPLAY ON\/OFF commands || Per the SSD1306\n   datasheet, bit 6 is the display ON\/OFF flag. It flipped correctly, proving the chip\n   executes commands — fault isolated to the panel side\n     |-\n     | 5 consecutive bus scans + 10 consecutive status reads || All values stable and\n   identical — ruled out loose wiring and parasitic power\n     |}",
                "char_count": 1072,
                "token_estimate": 268
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > 3. Files Created \/ Modified",
                "chunk_index": 48,
                "content": "{| class=\"wikitable\"\n     |+ Fixes and deliverables\n     ! File !! Type !! Description\n     |-\n     | <code>ssd1306_128x32.conf<\/code> || Fixed || Initially written in INI format,\n   causing \"unrecognized arguments\". Based on the source of\n   <code>luma.core.cmdline.load_config<\/code> (reads line by line, no whitespace\n   splitting), rewritten as one <code>--key=value<\/code> per line; demo.py then ran\n   successfully\n     |}\n\nNo files in luma.oled \/ luma.core or the example scripts were modified.",
                "char_count": 501,
                "token_estimate": 126
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > 4. Final Working Configuration",
                "chunk_index": 49,
                "content": "- Module: bare 0.91\" 128×32 SSD1306, <strong>no onboard regulator<\/strong>\n- Wiring: VCC → <strong>3.3 V<\/strong> (pin 1), GND → GND, SDA → GPIO2 (pin 3), SCL → GPIO3 (pin 5)\n- No RST\/RES connection needed (I2C interface)\n- I2C address: `0x3C`",
                "char_count": 243,
                "token_estimate": 61
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > 5. Operating Instructions",
                "chunk_index": 50,
                "content": "#### Run any luma example in this directory\n\n<pre>\npython demo.py    -f ssd1306_128x32.conf\npython clock.py   -f ssd1306_128x32.conf\npython pi_logo.py -f ssd1306_128x32.conf\n<\/pre>\n\nOr pass parameters explicitly:\n\n<pre>\npython demo.py -d ssd1306 -i i2c --i2c-port 1 --i2c-address 0x3c --width 128 --height 32\n<\/pre>",
                "char_count": 315,
                "token_estimate": 79
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > Minimal code (luma)",
                "chunk_index": 51,
                "content": "<pre>\nfrom luma.core.interface.serial import i2c\nfrom luma.oled.device import ssd1306\nfrom luma.core.render import canvas\n\ndevice = ssd1306(i2c(port=1, address=0x3C), width=128, height=32)\nwith canvas(device) as draw:\n    draw.rectangle(device.bounding_box, outline=\"white\")\n    draw.text((4, 10), \"OK 128x32\", fill=\"white\")\n<\/pre>",
                "char_count": 331,
                "token_estimate": 83
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "FAQ > 6. Black-Screen Decision Tree (for future modules)",
                "chunk_index": 52,
                "content": "- `i2cdetect -y 1` shows the address?\n  <strong>No<\/strong> → power\/wiring fault: measure VCC-GND **at the module's solder pads**, check SDA=pin 3, SCL=pin 5, try fresh dupont wires.\n  <strong>Yes<\/strong> → continue.\n\n- Run `python oled_diagnose.py`. Any step lights the panel?\n  <strong>Yes<\/strong> → software\/parameter issue; use the matching parameters (`-d ssd1306 --width 128 --height 32 --i2c-address 0x3c`).\n  <strong>No<\/strong> → continue.",
                "char_count": 450,
                "token_estimate": 113
            },
            {
                "title": "DR-0001",
                "rev_id": 16576,
                "heading_path": "Keywords",
                "chunk_index": 53,
                "content": "- 1U Rackmount for Raspberry Pi 5 with M.2 NVMe SSD support.",
                "char_count": 60,
                "token_estimate": 15
            }
        ]
    }
}