User avatar
Posts: 92
Joined: Tue Jan 13, 2015 7:25 pm
Location: Rotterdam
Contact: Website

Pi for Bachelor Offshore Engineering Students

Sat Nov 24, 2018 12:04 pm

Hi there,

I'm a lecturer offshore engineering from the Rotterdam University of Applied Sciences, and a pi enthousiast. Last week me an me colleagues got into the discussion that we would possibly integrate a SBC in our education from years 1 to 3. I myself am an advocate for the Pi since I really love this tiny friend and I think that learning Python is really useful for offshore engineers over Matlab or Excel, which we currently use. I'd like to discuss the possibilities with you all in this post.

We got into the discussion if we should use the arduino or the raspberry. I know the arduino and the Pi are completely different things, but obviously when choosing for education both machines could fulfill the same purpose. The pi is a giant toolbox which has a huge set of possibilities but it also has some disadvantages over the arduino. My main choice why I like to choose the pi over the arduino is Python. I'd like to explore how I can prepare an SD so I can overcome the disadvantages:
Problem 1: Robustness: the arduino is much more robust as the pi, you can just yank the power from it, and it'll be fine. this is not the case for the pi. To cover this i'm looking writing a program where, if I connect two gpio pins the pi will shut down. This way the students can at least power the pi off without any connection to it. Thus a connection using ssh, keyboard, monitor, vnc, etc is not required to power off the pi.
I've found this script to solve this: ... spberry-pi
Question: Do you have any other suggestions or tips to maybe solve this problem in a better way ?

Problem 2: Connectivity: the arduino can be programmed using it's own GUI that runs on the laptop of the student, the pi has it's desktop interface which is more difficult to access. Why? We have these annoying monitors with built in pc's that have no input for HDMI, additionally we need the students to also be able to connect to the pi from their laptops. Thus, I'd like to set up a SSH and VNC connection over ethernet. I'd like to stay away from wifi SSH and VNC since our eduroam network is very fragile and blocks a lot of traffic. As a solution I'd like to set up an automated VNC connection using the guide in the link below, addittionally I just discovered adafruit has the 'Adafruit Raspberry Finder' which helps to set up a connection. ... sb-windows
Question:Do you have any other suggestions or tips to maybe solve this problem in a better way ?

Problem 3: Running scripts. With the arduino you can just compile a script and run it on the arduino. With the pi you firstly need to send it to the pi and then run the script using a terminal command. This makes it rather difficult, and created a steep learning curve for students. To solve this I'd like to write a script that looks if a usb is connected to a specific usb port on the pi, if so, it looks for a certain pi script name and runs that. I'd also like the script to log any errors. This way students can just plug in a usb with a script on it, reboot the pi and it will run. This will help the students experiment with creating a autonomous boat. If students like to tinker with the script they can of course do that over the VNC connection in problem 2. I've found the solution in the following link: viewtopic.php?t=143649
Question:Do you have any other suggestions or tips to maybe solve this problem in a better way ?

As stated, I'm planning to create a custom image where all these problems are tackled so I'd like all solutions to be implementable on that image. Furthermore, I'd also like to be able to push updated code to the images, possibly using gitlab but I have no clue how that works. Also the students still need to be able to connect the pi to HDMI, mouse, keyboard and wifi. This way the students can still tinker and play with the pi normally at home.

One final request, does anyone have any comments or tips for me how I can iron out all these problems? I think all the problems I am facing should not be that uncommon, so any help or links to reduce my workload is greatly appreciated. I'm the only raspberry and linux 'expert' and my main goal is to get the students to work with Python as fast as possible, without needing to have to tackle the learning curve of linux first.

Thank you in advance!

Johan Antonissen
Senior Lecturer Offshore Engineering
Rotterdam University of Applied Sciences (Netherlands)

Posts: 239
Joined: Tue Oct 30, 2018 3:34 pm

Re: Pi for Bachelor Offshore Engineering Students

Sat Nov 24, 2018 3:36 pm

If you are looking to use a Pi in a more Arduino-like manner.
There is some effort being done to get Micropython working on Pi zero (bare metal, not running under Linux).
Which just looks for a file called on the SD card to execute.

Doesn't do USB sticks, VNC or anything fancy though.

Return to “Teaching and learning resources”