Hi folks, hard to believe this was our last regular session of 2019. Next week is our Christmas pizza party and show-and-tell.
This week we took a photo of a cereal box and UV mapped it to a simple cube which we scaled to the appropriate proportions. One we made our model we built a very basic studio setup and did our first render with a camera and a light.
This week, we took the mug we’d created the week before and UV unwrapped it again. We’d covered that last week too, and it’s in last week’s notes, but because we’d rushed a little we went over it again.
One the model was unwrapped, we created an image texture and manually painted it. We then used the GIMP image editing program to add an image to our texture.
At Hackers this week, we learned how to solder. Group members stripped wires and then soldered them together, and they made LED circuits by soldering them onto stripboard, and tested them with Arduino programs.
As we discussed, it is important to build your circuits temporarily with a breadboard (where you just push the wires in, and can easily move them) before moving onto soldering them on to stripboard. Stripboard (also called Veroboard) has holes every 2.5mm in a grid, and has copper strips on one side connecting the holes in one direction. You mount the component (such as an LED on the side with no copper, and solder its pins to the copper strip. Then, you can solder a pin of a different component somewhere else along the same copper strip, and current can flow through the copper strip.
There are plenty of videos on YouTube to demonstrate soldering technique. Here is one by Emer Cahill of GMIT:
This week we started looking at texturing. Texturing is the process of taking an image, which is flat, and mapping it onto a 3D object, which generally isn’t.
UV maps are just the plan that shows which part of the texture goes to which part of the 3D model.
Unwrapping is the process of taking the 3D surface of the model and laying it flat, like peeling an orange. This flattened version of the model, when placed over the texture becomes the UV map.
The animation above illustrates the process for a simple shape as if we really were unfolding the shape manually. In reality, we just tell Blender where the seams are (where it can cut the model’s surface) and the rest can happen automatically.
In the past two weeks in the Hackers group at CoderDojo Athenry, we have started Python programming on the Raspberry Pi.
The Pi is about the same size as the Arduino that we used earlier, and the Pi Zero is about the size of the Arduino Nano, and both Pi and Arduino have input/output pins for physical computing. However, they have significant differences.
Unlike the Arduino which is a microcontroller (which means it is designed to run a single program that was uploaded onto it), the Raspberry Pi has a full computer operating system, so it is more like a PC to use. It can be programmed in many languages, but Python is a popular choice as it is clear to read and there are lots of libraries to make tasks easier. Because it’s a full computer, you can write and run your programs all on the Pi, without connecting it to a laptop.
The first step in programming is to figure out how to do loops, variables and decisions, as these are fundamental. Here is our first Python program to try out these:
# Python comments start with #
age = 14 # a variable holding an int
name = "Michael" # variable holding a string
print ("My name is", name, "and my age is ", age)
for x in range (1, 5):
print ("This is line ", x)
if (age 17):
Next we moved on to using the GPIOZero libraries for controlling lights and buttons. We will continue to explore this in the coming weeks.
Hi folks, we got a lot covered this week and completed our sword model.
Here are the video instructions from this week:
The model from this week can be downloaded from here.
Next week we are going to have an open session. Bring your own ideas for models and we’ll help you build them.
See you then!
We completed our Mario game this week. We coded Mario so that he always floated down on to the wall. We added a fraction of a second of a wait so that it appears that he floats as he comes down. This also allows time for you to navigate left or right as needed.
We also introduced a more advanced concept, the Parallax effect, whereby objects further away appear to move slower than objects nearer. We coded mountains and a Sun to demonstrate this.