Greetings
As a reminder of what this project is about, please take a moment to read my poem
<aside>
🥅 Goal: Provide students with a quick and easy way
to comprehensively capture and display
their robotics projects so that they
can very easily convey
all that they may
create that day
</aside>
Today you will: build and program your own simple robot, film it from several angles, process the video, and upload it to SwipeVideo
https://usw.swipevideo.site/w/a946c87077
1. Making and programming your robot 🧘(15 minutes)
-
First things first: make a robot.
- The robot should do a simple action(s) that can be repeated perfectly every time you start the program
- The actions should take a small amount of time, probably 4 to 10 seconds
- If you want the action to be looped, it should end where it started
- Ideally, the right arrow button should be accessible
- Program your robot using blocks or Python with the Spike prime desktop app
-
Next, download one of the SPIKE Prime code files (in blocks or Python) 👇
Display robot - blocks.llsp
Display robot - Python.llsp
-
Open the file and then copy and paste your commands under the block/function that says YOUR_CODE_HERE
-
Change the variable checkpoints
to the value of your choice. If you are going to take videos by hand, 4-8 should be good. If you want to use the train, choose 16
-
Change the variable actionLength
to the time (in seconds) it takes your robot to complete its action. It's better to overshoot than undershoot with this number
What the program does ⚙️
- Waits until you press the right arrow button to start
- Beeps at a specific frequency to signal the start of an action
- Conducts an action (the commands you wrote)
- Waits a couple seconds for you to move the camera
- And repeats a set number of times
2. Filming your robot by hand 🎥 (15 minutes)
- Note: Read through the following instructions before starting
- You may also film your robot using the train set up. Come talk to me if you want to do this
- Hold up your phone and start recording (don't stop recording until you get all angles)
- Press the right arrow button on your robot to start it
- The robot will beep and then complete the action you programmed it to
- Once the action completes, move your phone to another position looking at the robot
- The robot will again beep and then complete the action you programmed it to
- Continue moving your phone to different positions to capture different views
- Stop the recording
- Get the video onto your computer when finished
Notes:
- Feel free to get creative with your camera angles. You can go up close to the robot, look down on it, get angles from the sides, move the camera during the videos, etc.
- It is best to go generally in the counterclockwise direction (to the right) so the final swipe video is more intuitive
- You will take one long continuous video which the program will then split
- Setting up and using the train
Taking a screen capture of the code to overlay 👨💻 (optional, 5 minutes)
Using the screen capture software of your choice, take a screen capture of the SPIKE Prime's code blocks running
- Just capture the commands you created under
YOUR_CODE_HERE
. The other commands are not important
- You only need to do this for one action
- Export the video as an mp4
3. Processing with the Python parsing program 🎞️ (10 minutes)
What the program does ⚙️
-
It uses the beeps the robot makes to signal the beginning of each clip and separates individual camera angles from the original video accordingly
-
It exports the videos to a folder named processedVideos
-
Loops the videos if the action is short
-
Can accept a screen capture of the code running to overlay on the swipe video
-
For Windows (click the triangle)
-
For macOS (click the triangle)
4. Creating the swipe video ↔️ (10 minutes)
- Log in to SwipeVideo 👉
- Select
contents
from the left side of the page
- Select the
+
window to create a new swipe video
- Enter the name of your swipe video (make it contain your name) and click
create
- Drag the videos from the
processedVideos
folder onto the webpage and wait for them to upload
- This can take up to 5 minutes depending on the number and length of videos
- Click
sort by file name number
and click sort
- Now click
preview
in the top right to view your swipe video!
- To make it public
- Select
private
in the top right
- Click the switch from
private
to public
- Copy the link under
player url
- Click
change
to finish
- Now you can link to the swipe video when creating your hackathon website post
https://usw.swipevideo.site/admin/3/works
5. SwipeVideo with everyone's projects! 🚉 (if we have time, 10 minutes)
Now we get to the fun part! I want to try to make a large scale swipe video with everyone's projects using the train.
- Remove the purple block/line that says
play beep 96 for .1 seconds
- Change the variable
checkpoints
to 24
- Change the variable
actionLength
to 10 and modify your blocks so that the robot action takes less than or equal to 4 seconds
- Chage
bufferLength
to 15
- Now everyone will put their robots around the train in the middle of the floor
- Then everyone will press the right button on their SPIKE at the same time and the train will go and record at different angles each time it goes along the track
- It will repeat this 24 times to get an essentially 360 degree view from the point of view of the train
Thanks for joining me!
If you want to capture a swipe video of any other projects in the future, I can help!
Also, please document what you did on the Hackathon website.
- SwipeVideo examples other interns made (click the triangle)