Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

osX, can't detect board. #10

Closed
Cyberek opened this issue Sep 3, 2015 · 5 comments
Closed

osX, can't detect board. #10

Cyberek opened this issue Sep 3, 2015 · 5 comments

Comments

@Cyberek
Copy link

Cyberek commented Sep 3, 2015

s2a_fm version 1.5   Copyright(C) 2013-14 Alan Yorinks    All Rights Reserved 

Python Version 2.7.10 (v2.7.10:15c95b7d81dc, May 23 2015, 09:33:12) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)]

PyMata version 2.10  Copyright(C) 2013-15 Alan Yorinks    All rights reserved.

Opening Arduino Serial port /dev/tty.usbmodem1411 

Please wait while Arduino is being detected. This can take up to 30 seconds ...
Board Auto Discovery Failed!, Shutting Down
Traceback (most recent call last):
  File "./s2a_fm.py", line 145, in <module>
    s2a_fm()
  File "./s2a_fm.py", line 80, in s2a_fm
    firmata.analog_mapping_query()
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/PyMata/pymata.py", line 216, in analog_mapping_query
    self._command_handler.send_sysex(self._command_handler.ANALOG_MAPPING_QUERY, None)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/PyMata/pymata_command_handler.py", line 619, in send_sysex
    self.pymata.transport.write(data)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/PyMata/pymata_serial.py", line 107, in write
    self.arduino.write(data)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/serial/serialposix.py", line 490, in write
    if not self._isOpen: raise portNotOpenError
serial.serialutil.SerialException: Attempting to use a port that is not open

Seems I cannot communicate with the board. Using the same tty I can upload code to Arduino via Arduino app.

@MrYsLab
Copy link
Owner

MrYsLab commented Sep 3, 2015

Do you have either StandardFirmata or FirmataPlus uploaded to the Arduino?

If yes, could you please run this test program and let me know the results.

Here is a sample output of that program:

Please Enter Your Serial Port In Quotes:'/dev/ttyACM0'
Attempting to open /dev/ttyACM0 at 57600
Serial Port /dev/ttyACM0 is open

@MrYsLab
Copy link
Owner

MrYsLab commented Sep 3, 2015

@Cyberek If the test program is successful, then please show me the command line you are using to start s2a_fm. Thanks.

@Cyberek
Copy link
Author

Cyberek commented Sep 4, 2015

Please Enter Your Serial Port In Quotes:'/dev/tty.usbmodem1411'
Attempting to open /dev/tty.usbmodem1411 at 57600
Serial Port /dev/tty.usbmodem1411 is open

I use this port to communicate via Arduino software.

@MrYsLab
Copy link
Owner

MrYsLab commented Sep 4, 2015

Good, so we know that pyserial can open your serial port. I don't own a Mac and that is why I am asking you to help me debug your problem.

The next step is to try another simple program that will blink the on-board LED (L13). The program is here. I edited the program to use the serial port you are using, so you just need to run this program and should not need to make any changes to it.

If this program fails, then I would like you remove the USB cable from your computer and then plug it back it. Wait about 10 seconds to allow the board to reset and try running the program again.

If this now works, then I would try removing and replacing the cable again and then try rerunning s2a_fm.

Please let me know the results.

@Cyberek
Copy link
Author

Cyberek commented Sep 5, 2015

I was able I solve the problem... Formata was somehow missing from the board causing all the problems. FirmataPlus works really well with all sensors. Thanks for the support.

@Cyberek Cyberek closed this as completed Sep 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants