I've seen a lot of questions on here that have this same issue, but I haven't found a solution that works yet. I'm trying to run this face tracking program, but I can't get it to work. I know that the program says that it's written for python 2.7, but as far as I know there isn't that much of a difference in the language structure, right? I have a pretty firm understanding of the basics of python, but I'm still going through school.
The issue is in the title, I downloaded pyserial, open-cv and numpy through the terminal on mac into /3.8/bin. However, when I try to run the code below, it throws an AttributeError like I don't have serial installed. Am I missing something, or misreading something? Any help would be greatly appreciated.
Input:
#import all the required modules
import numpy as np
import serial
import time
import sys
import cv2
arduino = serial.Serial('/dev/cu.usbmodem14201', 9600)
Error:
Traceback (most recent call last):
File "/Users/daPWNDAZ/Desktop/Arduino/Codes/FaceTracking/face.py", line 7, in <module>
arduino = serial.Serial('/dev/cu.usbmodem14201', 9600)
AttributeError: module 'serial' has no attribute 'Serial'