Manish-Subedi / poromagia

Raspberry pi (Master) communicates with Arduino (Slave) via I2C. Raspi subscribes to MQTT topic, interfaces with Identifying Algorithm

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Brief

Raspberry pi (Master) communicates with Arduino (Slave) via I2C. Raspi takes images, sends images to the Identifying Algorithm and gets the decision via MQTT. The decision is sent to the Arduino.

Raspberry Pi is configured as I2C Master and Arduino as a Slave.

Raspi subscribes to a topic for status of the sorting machine (ON/OFF). It will then put the Arduino in the respective state. [ Either START or STOP ] Arduino will be put into deep sleep state on STOP state.

Raspi also gets the decision (as an integer) from the same topic. The integer determines the position of one of the 4 slots where the card is to be dropped. The first three will be identified cards and the last slot would hold the unidentified cards.

The Raspi then writes the integer to I2C bus (to Arduino) Arduino performs necessary action, puts the card to the respective box.

The Arduino, on the other hand, sends a command when the suction system takes a card and waits on top of the camera.

About

Raspberry pi (Master) communicates with Arduino (Slave) via I2C. Raspi subscribes to MQTT topic, interfaces with Identifying Algorithm

License:Apache License 2.0


Languages

Language:Python 72.0%Language:C++ 28.0%