Black Lives Matter - Action and Equality. ... Adafruit joins the Stop Hate for Profit campaign.
0

MCP2221 - Mac / Blinka - Errors
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

MCP2221 - Mac / Blinka - Errors

by MattPackwood on Fri Mar 06, 2020 5:58 pm

Hi,

I am trying the instructions for "CircuitPython Libraries on any Computer with MCP2221" - https://learn.adafruit.com/circuitpytho ... l#overview

I am running MacOS 10.15.3

Python 3.8.2
This is what I have entered and the result I get

pip3 install hidapi --user (Success)
pip3 install hidap adafruit-blinka --user (Success)
export BLINKA_MCP2221="1" (Success)
echo $BLINKA_MCP2221 (I get "1")

Now for the problem, I go into the REPL
python3
Python 3.8.2 (v3.8.2:7b3ab5921f, Feb 24 2020, 17:52:18)
[Clang 6.0 (clang-600.0.57)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
import board>>> import board
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mattpackwood/Library/Python/3.8/lib/python/site-packages/board.py", line 110, in <module>
elif board_id == ap_board.JETSON_NX:
AttributeError: module 'adafruit_platformdetect.constants.boards' has no attribute 'JETSON_NX'
>>> dir(board)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'board' is not defined

Any suggestions? All other Python stuff I am playing with working "fine"....

MattPackwood
 
Posts: 32
Joined: Wed Jul 23, 2014 9:13 pm

Re: MCP2221 - Mac / Blinka - Errors

by MakerMelissa on Sat Mar 07, 2020 3:37 pm

Hi,

I just tried using the commands you posted and it seems to be working fine. Perhaps try running the following command to make sure you are running the latest version of Blinka to see if that helps:
Code: Select all | TOGGLE FULL SIZE
pip3 install --upgrade adafruit-blinka Adafruit-PlatformDetect

MakerMelissa
 
Posts: 141
Joined: Wed Jun 05, 2013 2:10 am

Re: MCP2221 - Mac / Blinka - Errors

by MattPackwood on Sat Mar 07, 2020 4:36 pm

Predictably this is what I get...

Code: Select all | TOGGLE FULL SIZE
>>> import board
>>> dir(board)
['G0', 'G1', 'G2', 'G3', 'I2C', 'SCL', 'SDA', 'SPI', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'ap_board', 'board_id', 'detector', 'pin', 'sys']
>>>

MattPackwood
 
Posts: 32
Joined: Wed Jul 23, 2014 9:13 pm

Re: MCP2221 - Mac / Blinka - Errors

by MakerMelissa on Sat Mar 07, 2020 4:41 pm

Awesome. That looks correct to me.

MakerMelissa
 
Posts: 141
Joined: Wed Jun 05, 2013 2:10 am

Re: MCP2221 - Mac / Blinka - Errors

by MattPackwood on Sat Mar 07, 2020 5:02 pm

I will poke it some more...

MattPackwood
 
Posts: 32
Joined: Wed Jul 23, 2014 9:13 pm

Please be positive and constructive with your questions and comments.