Mechanical design

[-] Documented the machine building process to the group page Documented your individual contribution to this project on your own website [-] Linked to the group page from your individual page as well as from group page to your individual pages Shown how your team planned, allocated tasks and executed the project (Group page) Described problems and how the team solved them (Group page) Listed possible improvements for this project (Group page) Included your design files (Group page) You need to present your machine globally and/or include an aprox. 1 min video (1920x1080 HTML5 MP4) + slide (1920x1080 PNG) (Group page)

Edwin's notes are helpful

Group project

Doppler microwave and milimeter wave radiation can detect through solid nonmetal surfaces milimeter can detect you even when you stop moving

Microwave radar RCWL-0516

This video is from 7 years ago, but he runs useful test to understand the sensor: Radar Sensors / Switches: Comparison and Tests.

From Alfia in Kochi:

This sensor module utilizes an RCWL-9196 chip that helps repeat triggers and a 360-degree detection area with no blind spot. It can recognize motion via walls and other materials and have a susceptibility range of 7 meters.

The specifications of the sensor is as follows: Input Voltage – 4V to 28V Operating current – 3mA (max.) Operating frequency – 3.2GHz Transmission power – 30mW (max.) Regulated output voltage – 3.3V, max. 100mA Sensing distance – 5 to 7 meters

Operating Voltage: 4V to 28V Operating Current (Typical): 2.8mA Detection Distance: 5 to 9 meters (adjustable) Transmitting Power: <0.2mW Output Voltage: 3.3V (typical) Output Delay Time (Default): 2 seconds Operating Frequency: ~3.2GHz

If ft is the transmitted frequency, fr is the reflected frequency (as measured by the common transmit/receive antenna on the sensor), v is the speed of the target relative to the sensor (negative if receeding, positive if advancing toward sensor), c is the speed of light and fd = (fr-fd) is the doppler shift, then: fr = ft (c + v) / (c - v) fd = fr - ft = 2v ft / (c - v) If ( c << v) then fd ≈ 2v ft / c Assume typical human motion speed of v = 1 m/s. ft = 3.181GHz, c = 2.998E8 m/s, then fd = 10Hz.

Neil's example board

Neil's board

some info

Crikit design tutorial

Power Supply: Connect the VIN pin to a power source between 4V and 28V, and connect the GND pin to the ground of the power source. Output Connection: Connect the OUT pin to the digital input of a microcontroller or to the base of a transistor if you're driving a load. Sensor Disable (Optional): The CDS pin can be connected to a photoresistor and resistor to form a voltage divider. This can disable the sensor when it is bright, saving energy during the day.

I used the code that I found in the Crikit tutorial.

// RCWL-0516 Motion Sensor Example Code
#define SENSOR_PIN D6  // Connect the OUT pin of the sensor to digital pin 2

void setup() {
  pinMode(SENSOR_PIN, INPUT);
  Serial.begin(9600);
}

void loop() {
  int sensorValue = digitalRead(SENSOR_PIN);
  if (sensorValue == HIGH) {
    // Motion detected
    Serial.println("Motion!");
    // Add your code here to handle the motion detection event
  } else {
    Serial.println("All good, homie");
  }
  delay(100);  // Delay to prevent overwhelming the serial output
}

testing

results

Group plan

Introverted Robot

Main parts:

  • eyes (Spiral 2)
  • wheels / driving components
  • structure / base
  • body - esp32 frame (Spiral 2)

Character traits (Spiral 1):

  • moves away from you (but knows when it's stuck in a corner?)
  • moving into other areas?
  • eyes: watches you as you approach / look around (Spiral 3)
  • moves on servos
  • eyes: hides when you get too close (Spiral 2)
  • LEDs that convey mood (Spiral 2)

Character traits (Spiral 3):

  • doesn't like sound
  • shakes
  • snores when being left alone
  • wheels: lock when you get too close

Sensors:

  • distance (microwave / tof) (Spiral 1)
  • sound [Spiral 3]
  • light [Spiral 3]

Output:

  • servos (eyes / top closing) (Spiral 3)
  • dc (wheels)
  • steppers?
  • LEDs (mood) (Spiral 2)

Communication:

  • I2C
  • esp-now
  • what MCUs are we using?

Power:

???

Other:

  • Sensor input communicated to eyes (3) and wheels
  • Moods -- LEDs / shakes (which scenarios)
  • approaching too quickly (orange)
  • stuck in a corner (red)
  • happy (green)

Bill of Materials:

  • MCUs (what kinds)
  • sensors

Spiral 1:

  • decide on base size
  • build base (designed to have the ESP32 body attach to it)
  • build wheel system
  • test sensors and get them to communicate with environment / wheels
  • power (with plan for more power consumption)
  • document / take videos
  • consider movie ideas
  • prep spiral 2 designs

Spiral 2:

  • create the eyes (servos)
  • eye box
  • make the ESP32 body
  • connected LEDs
  • work on making Spiral 1 more effecient / debug
  • document / take videos
  • movie compiling

Spiral 3:

Roles:

Irja - wheel and base assembly / body design and compilation / eye lights Patrick - wheel, base and eye assembly / sensor holders Dylan - CNC shield set up / servo set up / eye box assembly Sam - wheel programming / sensor code / protocol management / multiplexer

robot ideation

robot ideation

robot ideation

robot ideation

wheels turn

eyes move

Stepper driver

I considered making my own step stick. But that was going to be too time costly / risky. If future me does decide to go for it, here's a great resource I found from a past student: this.

alicia zang

When I decided to use a CNC shield, this resource was very helpful. I dubbed him the CNC Shield YouTube champion!

BOM:

  • 3 x Red "Made in China" A4988 step sticks
  • 1 x DRV8825 step stick
  • 1 x CNC Shield
  • 1 x Ardunio Uno

One of the A4988s was missing a bulk input capacitor. Located near the motor power supply (VMOT) and ground, its main purpose is to filter voltage spikes and provide stable power to the driver.

Capacitor C3 (Rep Rap has a very useful Wiki on using stepsticks):

The RepRap StepStick BOM explicitly lists the big SMD capacitor as 4.7 µF, 1206 package, 16 V.

I was able to get two wheels with two step sticks turn well, but there was trouble when I added a third.

I tested each step stick one by one. The DRV8825's current limit needed to be set differently to the others.

The current drawn by each step stick was different. All around 0.2A, except for the DRV8825, which was double that. I adjusted the current limit and that fixed the issue.

NB. You can adjust the current (and track it's amp reading) by turning the potentiometer while it's powered!

Max Current limit of the stepper motors: 1.7A 70% of max = 1.2A

Pololu DRV8825 current limit equation: VREF = CL/2 VREF = 1.2/2 = 0.6

Made in China A4988:
Vref = I_TripMax * 8 * Rs Rs (sensing resistors) = 0.1 0.96 = 1.2 * 8 * 0.1

1.5A current limit DRV8825: 1.5/2 = 0.75 A4988: 1.5 * 8 * 0.1 = 1.2

1.5 Vref is the limit for the A4988 sticks.

NB

NB. The sensing resistor value is different on the Pololu and Made in China step sticks. Rep Rap have good documentation on this.

To get the fourth stepper moving, there is a certain four pins that need bridging. Find that here.

shield pins

arduino pins

Servos (Eyes)

eye work

DUTY RATIO (20ms Duty cycle) - the servo expects to see a pulse every 20ms and the width of that pulse determines the position.

We made some structural adjustments to the eye box and started programming the eye movement sequences.

Here's some basic code on getting the eyes to move up and down + side to side.

NB. It's important to make sure that the servos are set to their midpoints before attaching the back of the box to the rest of the unit.

servo1

servo2