Cannot find function get_laser_summit() as required in exercise 3.2

in “Unit 3: Functions” of Python for Robots, there is new simulation with a Summit XL robot, but in the robot_control_class, there is no “get_laser_summit()” function, as mentioned in exercise 3.2 .
This function is supposed to be found in robot_control_class that is loaded with the example, but its not in there. Can someone please clarify?

Hi James,

Did you copy the robot_control_class.py indicated in “Unit 1: Python Basics” (2 - Basic Concepts)? I just did and can find that function there.

PS: this function is an “instance method” of the RobotControl class; hence it can be accessed with something like this (as you can see from the solution).

robot_ctrl = RobotControl()
robot_ctrl.get_laser_summit()

I did copy robot_control_class.py as instructed and the functions were working as per Unit 1 and Unit 2 of the Python Basics course. I could not have done these without the robot_control_class.py

I happened to save the robot_control_class.py to my notepad and I have it as a reference.

Just NOW I repeated the copy instruction again, and NOW I see the proper functions for the summit robot. It has definitely changed since I first copied that file. I think I first copied it a month ago, I’m not sure.

Did you guys change it recently to include Summit functions ? that would explain it.

Hi James,

Oh, I see. We are constantly improving the courses, and this definitely would be the case. Apologies for the inconvenience.

Regarding this same exercise 3.2 in unit 3, did you know the Run Cell (for the left-most panel where the instructions/sample code is) gives an error. The code works when running from my python file, but not when clicking Run Cell. The following error output: Try it. Maybe something’s wrong on my end?

ImportErrorTraceback (most recent call last)
<ipython-input-4-e147d78008a1> in <module>()
----> 1 from robot_control_class import RobotControl
      2 
      3 robotcontrol = RobotControl()
      4 
      5 def get_laser_values(a,b,c):

ImportError: No module named robot_control_class

Oh, no, let’s have a look at that, but better to make it a separate thread…New thread: