Synchronized Drawing

I was tasked with using MPI_Barrier to synchronously draw two triangles on two different raspberry pi boards. I was unsuccessful, but not unproductive.

The reason I wasn’t successful is this: When I executed Dr. Johnson’s program, the program would give me the following error:

numconfig= c_long(1)
Traceback (most recent call last):
  File "", line 27, in <module>
    program = context.get_program(vertexShader, fragmentShader, binding)
AttributeError: 'EGL' object has no attribute 'get_program'

This is after installing the pyopengles library. Googling provided little help.

Order Matters

One lesson I reminded myself of is that “Order matters” order referring to the sequence of things. I spent all too much time trying to get Dr. Bui’s code up and running again with both our machines on my local network. I was trying this command:

mpiexec -np 2 python -f machines

Instead of:

mpiexec -np 2 -f machines python

It just putting the program to execute at the end made the difference.

Time Analysis

The next thing I accomplished was some analysis on the delay it took between when the initial board would write its output and the other boards to receive the message and write their own. If this time is too long, they videos will not look as if they are playing at the same time.

Taking the log files generated from Dr. Bui’s program, here are the results of analyzing the difference in time between when bramble00 and bramble01 wrote the same line to their log files. There are 736 samples. All values are in seconds:

avg min max range std dev
0.009541388 0.008450031 0.011140108 0.00269 0.000529



Leave a Reply

Your email address will not be published. Required fields are marked *