NOW WITH Raspberry Pi 3
Raspberry Pi 3
First things first: Thank you for your interest in the gocupi project! Without the support of the community and of course the customers (FYI the community is a group of the best customers so, step your game up and join the community) the project would be a long forgotten mess of hardware in the back of a closet somewhere.
The goal is to keep the document setup as a reference for first time users as well as a handy cheat-sheet for everyone. This guide will be broken up into sections as such:
The box you receive in the mail will contain a gray plastic case with a latching lid that can also be locked.
a. gocupi board mounted on the Raspberry Pi
b. SD card with custom Linux distro (already in the Raspberry Pi)
c. Dry erase marker
d. Hex keys of different sizes (1.5mm and 2mm)
e. Nylon tape measure
f. Gondola with a servo attached
g. 12V power supply
h. Two stepper motors with suction cup mounts
If you are missing any of these parts contact gocupi support at email@example.com and we’ll get you taken care of post haste.
The gray plastic box was intended to be used for transporting your gocupi, you may want to keep some of the packing foam to keep it safe when in transit.
The gocupi can be used without any additional hardware. Using a computer (the Raspberry Pi is indeed a single board computer or SBC as the kids call them) without a display is referred to as running “headless”. We will discuss how to do that in the setup section called SSH. However, since we need to setup the custom boot image lets connect to a monitor or TV since the Raspberry Pi has HDMI output. I find it easiest to grab a USB keyboard, a spare HDMI cable and get comfy on the couch using the living room television as the first boot takes a bit of time to get through.
The short version of all that is: Grab a USB keyboard and a display (monitor or TV) with an HDMI input and an HDMI cable to get through the first boot. After we get through the setup the use of additional hardware is optional.
This section will contain different things for different people. For some, reading this will be painful as it includes details that seemingly no one cares to know or perhaps some of these things go without saying like telling someone to breathe…I would like to take this time to say hello to all the sys admins so, “Hello you arrogant keyboard cowboys, I’m sorry to make you suffer through this nonsense. Hopefully you aren’t too insulted by this.”
For others, this section will be confusing the first seventeen times you read it, I’m sorry for that and I would like to take this time to say hello to all the first time Linux and/or terminal users so, “Hello Windows and Mac fanboys! Don’t complain, just learn a new skill and get your robot drawing ASAP.”
First make sure the power switch on the gocupi board is in the OFF position, if you have the HDMI port facing you the power switch is above and to the right of the HDMI port. The power supply that was included with your gocupi connects to the barrel jack above and to the left of the HDMI port.
Note that I did not mention using a USB cable to power the Raspberry Pi as you would without the gocupi or any other board that provides power to the Raspberry Pi. Connecting a power supply to both boards can damage one or both the gocupi and/or Raspberry Pi.
Only use the provided 12VDC power supply, do not power the Raspberry Pi via Micro USB. (However this is not an issue on recent purchases as the included case for the gocupi does not allow you access to the Micro USB connector.)
You can connect an Ethernet cable at this time if you wish however, it is not required for initial setup of the gocupi.
You should have:
1. Confirm the power switch is in the OFF position
2. Connect the 12VDC power supply included with your gocupi
3. Connect your display via HDMI
4. Connect your keyboard via USB
The first boot will initialize the system, start this process by setting the power switch on the gocupi to the ON position.
Select “gocupi” from the list of options on the screen and install by using the “i” key on your keyboard or clicking the “install” button atop the window.
While the system does its thing there are bits of gocupi info as well as some gocupi art on the screen for you.
You can also take this time to select your keyboard setup by region at the bottom of the screen.
Once the process is finished click “ok” to reboot the Raspberry Pi.
The default username is “pi” and the password is your gocupi order number which can be found on your invoice, either in the box your gocupi came in or you should have gotten a copy via email. These are the default credentials for the Raspbian distribution (which our custom image is based on).
Pi 3 Wireless Awesome
We set up a soft access point called gocupi_AP which you can connect to from another computer or
smartphone or tablet or potato. The password is your gocupi order number
(same as login creds listed somewhere above). Just power the gocupi and
look for the SSID gocupi_AP.
You can also connect to a wired network via Ethernet (on the
Pi, not the gocupi board on top of it…idk what that would do to your
router “exactly” but you will at least see and smell smoke on both ends of
the Ethernet cable between the gocupi and said router) if the wired
network has internet access then devices connected to the gocupi_AP will also have access to
You can also connect to another wireless network while acting
as a soft access point. To do this you will need to follow standard
Raspbian protocol for connecting to WiFi, take care not to change any of
the settings we previously made…that vague enough of a CYA?
5. You’re Welcome.
Connecting to a network
Pi 3 Wireless Awesome
1. We set up a soft access point called gocupi_AP which you can connect to from another computer or smartphone or tablet or potato. The password is your gocupi order number (same as login creds listed somewhere above). Just power the gocupi and look for the SSID gocupi_AP.
2. You can also connect to a wired network via Ethernet (on the Pi, not the gocupi board on top of it…idk what that would do to your router “exactly” but you will at least see and smell smoke on both ends of the Ethernet cable between the gocupi and said router) if the wired network has internet access then devices connected to the gocupi_AP will also have access to the internet.
3. You can also connect to another wireless network while acting as a soft access point. To do this you will need to follow standard Raspbian protocol for connecting to WiFi, take care not to change any of the settings we previously made…that vague enough of a CYA?
5. You’re Welcome.
For wired network connections simply connect an Ethernet cable from the router to the Raspberry Pi. For wireless connections using a Raspberry Pi 2 you will need a USB WiFi dongle, using a Raspberry Pi 3 does not require a dongle as WiFi is onboard.
Wired network connections should be made before powering the gocupi.
If you are using a wireless connection then we will do that through the graphical user interface (GUI). Login to the gocupi using credentials listed above then issue the command “startx”. The GUI is called X Windows and we want to start the X Windows, so, that’s how you decrypt that command. Once the pretty interface is running you’ll find an icon on the desktop called WiFi something or other…sorry, I rarely use the GUI and I’m going off of memory here. You’ll configure your settings to those of your wireless network and then open a terminal by double clicking on the icon with a black box called XTerm or something similar. Issue the command “sudo reboot” to restart the computer, you may be asked for your root password, enter the password you used to login. If you have not changed the default password then enter “raspberry” and hit enter.
When powering or rebooting the gocupi a lot of information will scroll by on the screen, there is some info we want that appears just above the prompt to login. We’re looking for the bit that says “My IP address is 123.456.7.890” but with a non-made up address. This tells us 2 things, 1 that we are connected to the network and B what our IP address is if we want to connect to the gocupi from another machine as covered in the “headless operation” section.
You can control the gocupi from any computer on the same network using a protocol called SSH. I’ll use the term “SSH into” or “remote into” when describing the connection from another computer to the gocupi. I’ll discuss the setup for 3 OS’s, Windows, Mac, and Linux but not in that order.
Linux: If you will be using another Linux box to SSH into the gocupi then you probably know what to do, but, for the sake of making this document long as hell...Uh...I mean thorough, let’s talk about it.
You can open a terminal in just about any distro (that’s nerd speak for “Linux distribution”) with some combination of Ctrl, Alt, and T or it’s usually in the menu of installed applications. Once you find it simply issue the command “ssh firstname.lastname@example.org” but use the real address that you saw when the gocupi booted up. You’ll be asked for the password to the gocupi which unless you changed the default, it will still be “raspberry”.
Mac: I believe the process is very similar if not exactly the same as show above for a Linux box. Someone up on their high horse (mac user) will have to let me know if that’s not correct.
Windows: You’ll need to download a program called “Putty” to connect to the gocupi. I use a version called “ExtraPutty” which can be found at www.extraputty.com. The site does have some misleading ads that look like download links so you can use this link to download the most recent version at the time of writing this document (July 30, 2016) http://extraputty.com/snapshots/Download/thanks.php
Windows users get a little more help in the form of a screen shot since I’m currently on a Windows box. Here’s what your window should look like before clicking the “open” button at the bottom of the window:
Once again: include the real address of your gocupi and you’ll be required to provide your password upon connection which the default is “raspberry” unless you changed it. When setting up a new gocupi installation I typically run a headless wired system, to find the IP address of the gocupi I use my phone which is connected to the same network. I do this with an Android app called FING, you can find it in the play store. Not sure if it exists for iPhone and if you have a Blackberry then you probably need more help than this document can include.
The 3D printed motor mounts do not have “Left” and “Right” labelled on them, perhaps this is something I overlooked but I’ll tell you how you can differentiate them with a glance. The motor mounts connect to the gocupi board via Ethernet cables, to keep the Ethernet cables out of the way when drawing they connect to the motor mounts opposite the drawing area. Short version: the right motor has an RJ45 (Ethernet) connector on the left side and the left motor has an RJ45 connector on the right side.
The motors should be aligned horizontally, I usually line them up visually but measuring from the top of the white board would obviously be better than my approach. To connect the mounts first make sure the drawing surface and the suction cup are clean, I spit on mine and wipe it with my hand…I may have even done this to yours too. Once the surfaces are clean turn the knob above the motor to the middle position (oo) and press the suction cup firmly to the drawing surface. Holding the motor mount with one hand and turning the knob with the other to the third position (ooo) should securely affix the mount to the surface. I usually confirm the suction between the two by gently trying to remove the mount from the surface.
Use the nylon tape measure included with your gocupi to measure the distance between the two motor mounts in millimeters. Before powering the gocupi make sure there is enough line from each motor unspooled to reach around half way to the other mount.
If your cables from the gocupi to the motor mounts are connected then turn on the gocupi and hang the gondola on the lines between the motors. Measure the distance from the left motor mount to the gondola in millimeters. The measurement should be from the point of contact between the line and the line guide on the motor mount to the edge of the gondola nearest the motor mount. The same process should be followed for the right side.
We need to tell the gocupi software where the intersection of the two lines happens, to do this we need to take into account the distance from the end of the gondola to the marker. This distance is 120mm on each side, so add 120mm to the left measured distance and the right measured distance.
Input the values by issuing the command “gocupi setup 700 470 460” where 700 is the distance between motor mounts, the left motor mount to gondola was measured to be 350mm + 120mm = 470mm and the right motor mount to gondola measured 340mm + 120mm = 460mm. The command is given with values in the order: top, left, right.
Once the measurements are input the easiest way to confirm the correct values were used is to draw a grid of squares that are 1cm by 1cm. This is done by issuing the command “gocupi grid 100 10” and measuring a few of the individual squares.