A machine for sorting anything using Raspberry Pi, Mindstorms and a PC. Originally created for chilli peppers. This repo contains code for lego bricks.
Read the paper here.
- Update the Raspberry Pi's software
sudo apt-get update && sudo apt-get upgrade- Install git
sudo apt-get install git -y- Download the Node version manager install script and pipe it to bash to execute
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash- Add nvm to path
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"- Use nvm to install the Node long term support versions
nvm install --lts- Clone this repository
git clone https://github.com/rubenuijtdewilligen/sorting-machine.git- Move the rpi folder to sorter/
mv sorting-machine/rpi/ sorter/- Remove the rest of the repository
rm -rf sorting-machine- Change directory to sorter/
cd sorter/- Use npm to install the required Node modules (only Express)
npm install- Execute the program
node .