{"id":26236174,"url":"https://github.com/kathyreid/sensebreast","last_synced_at":"2026-04-21T23:03:50.883Z","repository":{"id":146408529,"uuid":"195737276","full_name":"KathyReid/sensebreast","owner":"KathyReid","description":"A sensing mastectomy prosthetic based on RPi 3B+ and a Sense HAT","archived":false,"fork":false,"pushed_at":"2019-09-04T21:41:30.000Z","size":3155,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-09T06:06:39.136Z","etag":null,"topics":["breast-cancer","cybernetics","data-ownership","data-visualization","dataviz","mastectomy","python","quantified-self","quantifiedself","rpi","rpi3b-plus","sense-hat","sensor","sensors"],"latest_commit_sha":null,"homepage":"https://sensebreast.org","language":"MATLAB","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/KathyReid.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-07-08T04:37:17.000Z","updated_at":"2023-11-23T05:04:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"b2082c17-e086-4faf-8412-400911871280","html_url":"https://github.com/KathyReid/sensebreast","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KathyReid%2Fsensebreast","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KathyReid%2Fsensebreast/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KathyReid%2Fsensebreast/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KathyReid%2Fsensebreast/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KathyReid","download_url":"https://codeload.github.com/KathyReid/sensebreast/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243333029,"owners_count":20274600,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["breast-cancer","cybernetics","data-ownership","data-visualization","dataviz","mastectomy","python","quantified-self","quantifiedself","rpi","rpi3b-plus","sense-hat","sensor","sensors"],"created_at":"2025-03-13T03:27:38.604Z","updated_at":"2025-12-28T23:36:39.760Z","avatar_url":"https://github.com/KathyReid.png","language":"MATLAB","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SenseBreast \n\n- [SenseBreast](#sensebreast)\n  * [What is SenseBreast?](#what-is-sensebreast-)\n  * [How do you build SenseBreast?](#how-do-you-build-sensebreast-)\n    + [Requirements](#requirements)\n    + [Method](#method)\n      - [Raspberry Pi](#raspberry-pi)\n        * [Flash the Raspbian operating system to the Micro SD card](#flash-the-raspbian-operating-system-to-the-micro-sd-card)\n        * [Set the localisation for your preferred keyboard layout](#set-the-localisation-for-your-preferred-keyboard-layout)\n        * [Connect to a network with internet access](#connect-to-a-network-with-internet-access)\n        * [Install `git` and clone this repo](#install--git--and-clone-this-repo)\n        * [A little `.bashrc` hack for making `ls` much nicer](#a-little--bashrc--hack-for-making--ls--much-nicer)\n        * [Symlinking the `wpa_supplicant.conf` file](#symlinking-the--wpa-supplicantconf--file)\n        * [Install the `sense-hat` package for Raspbian](#install-the--sense-hat--package-for-raspbian)\n      - [Using sensors](#using-sensors)\n    + [Prosthetic form](#prosthetic-form)\n    + [Future directions for development](#future-directions-for-development)\n\n\u003csmall\u003e\u003ci\u003e\u003ca href='http://ecotrust-canada.github.io/markdown-toc/'\u003eTable of contents generated with markdown-toc\u003c/a\u003e\u003c/i\u003e\u003c/small\u003e\n\n\n## What is SenseBreast? \n\nSenseBreast is a Maker Project for CECS8001 - Lab, by Kathy Reid (@kathyreid on the Twitters, GitHub, IRC etc). \n\nIt is designed to be an early prototype of a mastectomy prosthetic, and explores the concept of a _cyberphysical system_ by having both computing-based components - \"the cybers\" - and physical components that are placed in close proximity to the body - \"the physical\". \n\n_Side note: For an excellent discussion of context and personal vs public space, see:_ \n\n\u003e Haber, J., Greening, M., Castellano, L., \u0026 Wheaton, P. Proxemic Conversational UI: Moving beyond simple conversation.\nhttp://www.jonathanhaber.com/pub/gi2016.pdf\n\nSenseBreast is open source under the Apache2 license, inspired by projects like OpenAPS. Because open source is an act of generosity - an act of contributing to the commons - a movement which is more than the sum of its individual contributions. \n\n## How do you build SenseBreast? \n\nThese instructions are provided so that SenseBreast has a _reproducible build_. \n\nWhere documentation for a step already exists, it is linked rather than being reproduced. \n\n### Requirements \n\nTo build SenseBreast you will need: \n\n* Raspberry Pi 3B+\n* Sense HAT\n* Monitor with a HDMI connection and a HDMI cable \n* USB keyboard \n* 8GB or more Micro SD card and a way to write to the card (ie Etcher)\n* Basic `bash` and `python` knowledge\n* A source of battery power - I recommand a small form factor Li-Ion pack with a Micro-USB cable to go to the Raspberry Pi. _NOTE: Most of the power sources I tested resulted in 'under voltage' warnings on the RPi, but these are generally safely ignored._\n* Coffee, patience, and when that fails, your favourite curse words. \n\n### Method\n\n#### Raspberry Pi \n\n##### Flash the Raspbian operating system to the Micro SD card\n\n* Flash the [Raspbian Stretch Lite operating system](https://www.raspberrypi.org/downloads/raspbian/) to your Micro SD card using a program like Etcher \n* To prove that you have a working Raspberry Pi with Rasbpian, connect the RPi to the monitor using a HDMI cable, and to the keyboard using the USB cable. Connect the RPi to a power source using the Micro USB cable. On the first boot, the RPi will display \"resizing file system, rebooting in 5 seconds...\". Once the RPi is powered on, you should see the device boot. Use the username `pi` and password `raspberry` to log in. If you can successfully log in, you are ready for the next steps. \n\n_NOTE: You will not have network access yet, that's the next step._\n\n##### Set the localisation for your preferred keyboard layout\n\nBy default, the RPi ships with the `en-GB` keyboard layout, which has several different key settings, like the `@` symbol and `#` symbol aren't where they are on an Australian keyboard. To set localisation options, type `sudo raspi-config` at the command line, then choose `4 - Localisation option`. If you're Australian, choose `en-AU`, then set this as the default `LOCALE`. Then, set the keyboard layout to `English-Australian` by typing `sudo raspi-config`, then choosing `4 - Localisation options` then `I3 Change Keyboard Layout`. \n\nThis will make you life easier when manually typing configurations. \n\n##### Connect to a network with internet access\n\n_NOTE: This is the hardest step in hardware setup. Do not underestimate how difficult this step is. Here be dragons._\n\nThere are two methods to do this. \n\n* You can use `sudo raspi-config` from the command line, then choose `2 - Network options` and enter the details for your network. \n\nChances are though that you're on a secure, PEAP-authenticated network, in which case this method won't work and you'll need to manually edit the `wpa_supplicant.conf` file. This is an exercise in pain, misery and the limits of caffeine tolerance, so the repo includes a sample `wpa_supplicant.conf` to protect your sanity. The tutorial [here](https://www.raspberrypi.org/forums/viewtopic.php?t=111100) shows you how to generate a password hash for PEAP authentication. \n\n* `cd /etc/wpa_supplicant`\n* `sudo mv wpa_supplicant.conf wpa_supplicant.conf.BAK` # this makes a copy of the existing file in case of borkage\n* `sudo nano wpa_supplicant.conf` \n\nThen, edit the wpa_supplicant.conf with the details relevant for your network. Use `Ctrl + X` to save. Type `sudo reboot now` on the command line to reboot. \n\nIf you have a working `wpa_supplicant.conf` file then you will be able to proceed and install other components, otherwise you will be blocked until you can get `wpa_supplicant.conf` working. \n\n##### Install `git` and clone this repo\n\n`git` will make setting up the SenseBreast a lot easier, because you can pull down this repo and a lot of the associated files. \n\n`sudo apt-get install git`\n\nThen, we clone this repo: \n\n`git clone https://gitlab.cecs.anu.edu.au/u6933485/sensebreast/`\n\nYou will be asked for your ANU CECS GitLab username and password. \n\n_NOTE: If you have 2FA enabled on the CECS GitLab, remember to use your token instead of your raw password._\n\n##### A little `.bashrc` hack for making `ls` much nicer \n\n`sudo vi ~/.bashrc`\n\nUse the `/` key and enter `alias`. \n\nIn the block of aliases, add: \n\n`alias ls='ls -las'`\n\nThen use `:wq` to write and quit. \n\nType `exit` then log in again, and when you use `ls` it will give you verbose information. Very helpful for development purposes. \n\n##### Get `nano` to do proper syntax highlighting\n\nIf you're doing any development work on the SenseBreast using the `nano` editor, then you will want to create and edit a `.nanorc` file in the `pi` user's home directory. \n\nAn example `.nanorc` is included in the repo, which includes Python and bash syntax highlighting. \n\n```bash\ninclude /usr/share/nano/sh.nanorc\ninclude /usr/share/nano/python.nanorc\n```\n\n##### Symlinking the `wpa_supplicant.conf` file\n\nOnce you have the repo down, you can symlink `wpa_supplicant.conf` to make your life easier. \n\n```\ncd /etc/wpa_supplicant\nsudo rm wpa_supplicant.conf\nsudo ln -s /home/pi/sensebreast/wpa_supplicant.conf wpa_supplicant.conf\n```\n\nThis means that you can make changes to `wpa_supplicant.conf` in `git` such as adding a new network, and when you update the `sensebreast` repo using `git pull`, you will bring the changes down automagically. \n\n##### Setting up a `crontab` for the `pi` user to run the scripts\n\nUse the `crontab` program to set up scripts to run at the frequency you want. Currently the script will sense for 5 minutes then write to disk, so the [example crontab](pi-user-crontab) is set to run the scripts every 5 minutes. \n\n##### Logging\n\nThe `crontab` is set to log to `./log/sensebreast.log`. You may wish to use this if you do any additional sensing. \n\n_NOTE: `rsyslog` has been configured to log `cron.d` events to `/var/log/cron.log`, *however* this file is not writeable by the `pi` user and so commands executed under `crontab` will fail - this is why they are set to log to a different log file. \n\n\n##### Install the `sense-hat` package for Raspbian\n\n* Install [Sense HAT and the Python libraries for Sense HAT](https://www.raspberrypi.org/documentation/hardware/sense-hat/). The Python libraries are installed by installing the `sense-hat` package - you don't have to install something separate. \n\n#### Using sensors \n\n##### Calibrate the sensors using `octave`\n\n* Follow the [instructions on the Sense HAT website](https://www.raspberrypi.org/forums/viewtopic.php?f=104\u0026t=109064\u0026p=750616#p810193) or [this forum post](https://www.raspberrypi.org/forums/viewtopic.php?f=104\u0026t=109064\u0026p=750616#p810193) to calibrate the sensors. \n\n* The files in the `sensing-scripts` directory use Python to take readings from the Sense HAT. \n\n\n### Prosthetic form \n\n\n### Future directions for development\n\n#### Additional sensors \n\nIt may be possible to add additional sensors, and use the pins that are not consumed by the Sense HAT. \n\n\n### Disk image of SenseBreast\n\nA [disk image of SenseBreast 1.0 is available](https://drive.google.com/file/d/1BEew4lalLM3Gj5rReMM677PFe3qEfLil/view?usp=sharing)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkathyreid%2Fsensebreast","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkathyreid%2Fsensebreast","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkathyreid%2Fsensebreast/lists"}