{"id":20887389,"url":"https://github.com/ryanweal/raspberry-pi-recipes","last_synced_at":"2026-04-25T13:36:06.613Z","repository":{"id":143892045,"uuid":"169278750","full_name":"ryanweal/raspberry-pi-recipes","owner":"ryanweal","description":"My raspberry pi recipes","archived":false,"fork":false,"pushed_at":"2020-04-13T00:37:14.000Z","size":28,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-29T12:24:23.949Z","etag":null,"topics":["nodejs","raspberry-pi","raspberrypi","waveshare"],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryanweal.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2019-02-05T17:07:32.000Z","updated_at":"2020-04-13T00:37:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"c61ac9bc-445b-48fe-bf25-853dfcf2c761","html_url":"https://github.com/ryanweal/raspberry-pi-recipes","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ryanweal/raspberry-pi-recipes","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanweal%2Fraspberry-pi-recipes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanweal%2Fraspberry-pi-recipes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanweal%2Fraspberry-pi-recipes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanweal%2Fraspberry-pi-recipes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryanweal","download_url":"https://codeload.github.com/ryanweal/raspberry-pi-recipes/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanweal%2Fraspberry-pi-recipes/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32264430,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-25T09:15:33.318Z","status":"ssl_error","status_checked_at":"2026-04-25T09:15:31.997Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["nodejs","raspberry-pi","raspberrypi","waveshare"],"created_at":"2024-11-18T08:19:55.095Z","updated_at":"2026-04-25T13:36:06.133Z","avatar_url":"https://github.com/ryanweal.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# raspberry-pi-recipes\nMy raspberry pi recipes\n\n\n## Pi-Hole\n\nAn ads-free and malware-free wifi network for every device to enjoy!\n\n1. Download \"lite\": https://www.raspberrypi.org/downloads/raspbian/\n2. Flash the SD card: https://www.raspberrypi.org/documentation/installation/installing-images/linux.md\n\n    ```dd bs=4M if=2018-11-13-raspbian-stretch.img of=/dev/sdX conv=fsync```\n    \n    ```# note: may need to fully unmount first time, do not do /dev/sdb1 here (must be root of device)```\n    \n3. Boot with HDMI and keyboard and ethernet connected, sd card loaded before power.\n4. User pi pass raspberry\n5. Change password\n6. Enable SSH\n7. Run updates\n8. Run pi-hole curl command: https://github.com/pi-hole/pi-hole/#one-step-automated-install\n\n    ```curl -sSL https://install.pi-hole.net | bash```\n\n9. Edit router settings, set current as fixed IP, accept pi-hole network defaults after confirming\n10. Set router to use pi-hole IP as the DNS\n\nIt took me about an hour to do this recipe. It could probably be done in much less time.\n\nI copied down the wrong password for the web UI but when I did \"forgot password\" it gave me a command to run to reset it. That was helpful.\n\n\n\n## E-ink PaperTTY pi\n\n1. Lite\n2. Flash\n3. Boot with keyboard, hdmi, waveshare 2.13\" connected and flash card loaded.\n4. Login\n5. Change pass\n6. Enable SSH, SPI, I2C\n7. Run updates\n8. Install git: apt-get install git\n9. mkdir -p /home/pi/code \u0026\u0026 cd /home/pi/code\n10. git clone https://github.com/joukos/PaperTTY.git\n11. sudo apt install virtualenvwrapper python3-virtualenv libopenjp2-7\n12. source /usr/share/virtualenvwrapper/virtualenvwrapper.sh\n13. add above line to .bashrc\n14. still in PaperTTY directory: mkvirtualenv -p /usr/bin/python3 -r requirements.txt papertty\n15. apt-get install python-libtiff?\n16. screw it, use it without virtualenv: sudo apt install python3-rpi.gpio python3-spidev python3-pil python3-click\n17. sudo ./papertty.py list\n18. sudo ./papertty.py --driver epd2in13 scrub\n19. sudo ./papertty.py --driver epd2in13 terminal # works with physical keyboard\n20. apt-get install tmux\n21. in another ssh window after terminal is running: sudo openvt -fc 1 -- sudo -u pi tmux\n22. tmux attach\n...\n23. (on different machine) sudo apt install xfonts-terminus\n24. (on different machine, with PI's IP)  scp ter-u12b_unicode.pcf.gz pi@192.168.1.8:/home/pi/code/PaperTTY\n25. gunzip -c /usr/share/fonts/X11/misc/ter-u12b_unicode.pcf.gz \u003e terminus-12.pcf # note the -c\n26. pilfont.py terminus-12.pcf\n27. sudo ./papertty.py --driver epd2in13 terminal --autofit --font terminus-12.pil --noclear --nocursor --scrub\n\n## E-ink bitmap\n\n- do not install bcm driver or wiredpi\n\nhttps://github.com/soonuse/epd-library-python\npython-spidev\npython-pil\nttf-freefont\n\n- Create a loader using the example:\n\n```\nimport epd2in13\nimport time\nfrom PIL import Image\nfrom PIL import ImageDraw\nfrom PIL import ImageFont\n\ndef main():\n    epd = epd2in13.EPD()\n    epd.init(epd.lut_full_update)\n\n    image = Image.open('weather.bmp')\n    draw = ImageDraw.Draw(image)\n    font = ImageFont.truetype('/usr/share/fonts/truetype/freefont/FreeMonoBold.ttf', 12)\n    draw.rectangle((0, 240, 130, 250), fill = 0)\n    draw.text((20, 239), 'Hello world!', font = font, fill = 255)\n   \n    epd.clear_frame_memory(0xFF)\n    epd.set_frame_memory(image, 0, 0)\n    epd.display_frame()\n\nif __name__ == '__main__':\n    main()\n```\n\n## E-ink bitmap scrape and display bitmap generator\n\n- install nvm\n- nvm install node --lts\n- install puppeteer script + cards nuxt folder\n- configure template in nuxt (cards/pages/weather.vue as example)...\n- then `npm run generate` to create cards/dist folder\n- install the webserver: `npm i -g http-server`\n- make sure port numbers match index.js and the port in do-it.sh\n- npm i puppeteer # it is a different processor type so don't rsync your node_modules\n- install debian dependencies necessary for headless chrome:\n  - ```sudo apt install gconf-service libasound2 libatk1.0-0 libatk-bridge2.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils wget```\n  - that doesn't work.\n  - sudo apt install chromium-browser\n  - chromium-codecs-ffmpeg\n  - add to headless config\n  - sudo apt install imagemagick\n - puppeteer is not my friend right now, different models of pi have different ARM architecture... hmm.\n - puppeteer-core@v1.11.0 \"stable\" is the one that works with chromium-browser version 65, which is the default in Stretch\n - const puppeteer = require('puppeteer-core');        \n - const browser = await puppeteer.launch({executablePath: '/usr/bin/chromium-browser'});\n - ... but the site I was scraping has changed selector names today. So it isn't perfect yet.\n - cleaned up my custom code... \"it works now\" https://github.com/ryanweal/papercards (sorta, mostly).\n - debugging cron\n   - `sudo apt install sendmail mutt`\n - real webserver so we can detach the console completely\n   - `sudo apt install nginx`\n   - `sudo vi /etc/nginx/sites-available/default`\n     - set root to point to cards/dist; include semicolon for best results\n     \n\n\n\n## Pi Zero-W Headless setup\n\n - rasbian lite flashed\n - two text files in /boot partition:\n   - ssh (just touch the file is enough)\n   - wpa_supplicant.conf (with initial defaults)\n\n```\nctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev\nupdate_config=1\ncountry=US\n\nnetwork={\n  ssid=\"mynet\"\n  psk=\"mypass\"\n  scan_ssid=1\n}\n```\n   \n- sudo su\n  - apt-get update\n  - apt-get upgrade\n  - apt-get install git\n  - ^D\n  \n- raspi-config\n  - interfaces -\u003e enable spi\n  - localization\n    - set locale\n    - set timezone\n  \n- setup PaperTTY (fresher instructions)\n  - sudo apt-get install python-spidev python-pil\n  - sudo apt-get install python-pip\n  - sudo apt install python3-rpi.gpio python3-spidev python3-pil python3-click\n  -  pip install -r requirements.txt # fails - memory error\n  - comment out line 44 of papertty.py (import vncdtool)\n  - sudo ./papertty.py --driver epd2in13 scrub\n  - ... tmux stuff\n  - tmux set -g status off (see https://superuser.com/questions/265320/disable-the-status-bar-in-tmux)\n  \n### Profanity settings\n    - create \"account\"\n    - set jid\n    - set account default\n    - set autoconnect\n    - create startup script with launch commands: ~/.local/share/profanity/scripts\n  ```\n/statusbar down\n/occupants hide\n/join wall@conference.kafei.dev\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanweal%2Fraspberry-pi-recipes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryanweal%2Fraspberry-pi-recipes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanweal%2Fraspberry-pi-recipes/lists"}