Tiny House project - Jeremy

From Sensors in Schools
Jump to navigation Jump to search

This box is used to test the thermal performance of a model Tiny House

Photo/Video Library

Photo/Video Album

MakerCase 580*580*580 Close box SVG file

Creation of pt-1 of the scale tiny house box

MakerCase

Go to MakerCase

Click on Simple Boxes

Change Units to Millimeters

Change With to 580 Change Height to 580 Change Depth to 580

Ensure Outside is selected for Are these inside or outside dimensions?

Ensure Material Thickness is 3mm

Ensure Open or closed box? is Closed

Change Edge Joints to Finger and set Finger Size to 51

Your settings should look like this

Then select Download Box Plans

Adjusting parameters

You should see a pop-up with this picture in it

Adjust Line And Spacing settings to match the ones below

Adjust Line Formatting settings to match the ones below

Adjust Kerf settings to match the ones below

Then select Download SVG

Finally rename the downloaded file to something better/more suited

Inkscape Editing

Open the aforementioned file in Inkscape and proceed to do the following things (Download Inkscape)

Adding Pages

In Inkscape change view mode to View -> Display Mode -> Outline so you can see the box sides

Create 6 pages with the dimensions 600*600mm by selecting the Create and edit document pages icon in the left toolbar

You can also add labels to the pages

All 6 pages

Align the 6 pages

Un-group & Align

Select the design then select Object -> Ungroup

Align separate sides onto their own page

Delete labels

Optionally after deleting the labels add smaller 1-2 letter labels in the corner of each side

Adding access hole

Add access square with the dimensions 131*131mm to the to-be front panel

Center the square on the front panel

Fixing parameters

Set Stroke Style to 0.01pt on all objects

Change Stroke Paint

Insert Creation

This is the creation of pt-2 of the scale tiny house box

MakerCase

Go to MakerCase

Click on Simple Boxes

Change Units to Millimeters

Change With to 574 Change Height to 180 Change Depth to 180

Ensure Outside is selected for Are these inside or outside dimensions?

Ensure Material Thickness is 3mm

Ensure Open or closed box? is Closed

Change Edge Joints to Finger and set Finger Size to 30

Your settings should look like this

Then Select Download Box Plans

Editing parameters

And edit the parameters to be the same as below

Then select Download SVG

And rename to something better/more relevant

Editing insert in Inkscape

Open the file in Inkscape

Add new page and size to fit

Rearange with new page

Remove labels

Edit Stroke Style

Add 131*131mm cutout

Final SVG files

These are pictures of the final SVG files

Main Box

Box Insert

Laser Cutting

Making the digital SVG files into a cardboard/wood box

Software

Put SVG files into your laser cutter software

Then Cut!

Video Of Laser Cutting

Assemble Laser Cut Side Panels

Connect all side panels into their according locations and stick together

Add top panel but DON'T STICK DOWN (For Later Access)

Adding Insert

Assemble and add insert without sticking down

Creating Sensor Board

Solder in place in order

The tape is just to relive the solder joints of stress (because my battery holder solder joint disconnected)

Final Sensor Board

Programming The Pycom LoPy 4

Some code examples for the Pycom

LED

from time import sleep
from machine import Pin

led = Pin('G16', mode=Pin.OUT, value=0)

for i in range(4):
    led.toggle()
    sleep(1)
led(1)

RGB-LED

import pycom
from time import sleep

pycom.heartbeat(False)
pycom.rgbled(0x0000ff) #green
sleep(2)

for cycles in range(10):
    pycom.rgbled(0x00ff00) #green
    sleep(2)
    pycom.rgbled(0xffff00) #yellow
    sleep(2)
    pycom.rgbled(0xff0000) #red
    sleep(2)

sleep(2)
pycom.rgbled(0x000000) #off

Sleep

import time
import machine

time.sleep(1) #sleep 1 second
time.sleep_ms(10) #sleep 10 milliseconds
time.sleep_us(10) #sleep 10 microseconds

machine.sleep(100, True) #light sleep 1 second
machine.deepsleep(1000) #deep sleep 1 second

GPIO-Output

import time
from machine import Pin

led = Pin('P9', mode=Pin.OUT)

for i in range(5):
    print("high")
    led.value(1)
    time.sleep(1)
    print("Low")
    led.value(0)
    time.sleep(1)

GPIO-Input

import time
from machine import Pin

led = Pin('P9', mode=Pin.OUT)
button = Pin('P10', mode=Pin.IN)

while True:
    if(button() == 1):
        led.value(1)
        sleep(1)
        break
    else:
        led.value(0)

ADC

from machine import ADC

adc = ADC(0)
adc_c = adc.channel(pin='P13')
adc_c()
adc_c.value()

ADC-Calibration

from machine import ADC
adc = ADC()

Output Vref of P22
adc.vref_to_pin('P22')

LED-Brightness

import pycom
from time import sleep

pycom.heartbeat(False)

value = 000000
end = '0x'

for i in range(9):
    value = value + 101010
    product = (end+str(value))
#    print(product)
    pycom.rgbled(int(product))
    sleep(1)

for i in range(9):
    value = value - 101010
    product = (end+str(value))
#    print(product)
    pycom.rgbled(int(product))
    sleep(1)

pycom.rgbled(0x000000) #off