Mleaf / stm32flash

Automatically exported from code.google.com/p/stm32flash
0 stars 0 forks source link

Not working on Mac OS X 10.8 #36

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Connect the STM32 and put it in bootloader mode
2. in the terminal : stm32flash /dev/tty.usbserial

And the result is : 

stm32flash - http://stm32flash.googlecode.com/

Serial Config: 57600 8E1
read_byte: Undefined error: 0
Assertion failed: (0), function stm32_read_byte, file stm32.c, line 90.
Abort trap: 6

I'm using the same version of the tool and the same STM32 on my macbook (10.7) 
and everything is working fine so I presume that's a Mac 10.8 problem.

I tried different baudrate but always the same problem.
No problem on windows (using VMWare) on the same computer with the ST Tool

Original issue reported on code.google.com by navarro....@gmail.com on 26 Nov 2012 at 12:24

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Does the error appear immediately or does it take a second or many before it 
appears (timeout)? Do you use the same USB-serial adapter on the macbook, and 
exactly what adapter is it?

Original comment by lists.to...@gmail.com on 26 Nov 2012 at 8:12

GoogleCodeExporter commented 9 years ago
The error appears about 1 or 2 seconds after the command is entered. 
I use the same board on both computers and it has a PL2303. I have the drivers 
up to date

Original comment by navarro....@gmail.com on 26 Nov 2012 at 8:48

GoogleCodeExporter commented 9 years ago
1. Do you have another RS232 device which you can test with another program 
using the same adapter? That would tell us if there is something wrong with 
PL2303 drivers on macosx 10.8 or if there is something we need to adapt to in 
stm32flash.

2. There are many versions of PL2303, e.g. PL2303-HX rev 4 etc. Can you please 
tell us the USB ID (vendorID:productId and bcdDevice)?

Of course, if you can get access to another adapter of different brand, and see 
if the same issue appears, it would be very useful.

Original comment by lists.to...@gmail.com on 27 Nov 2012 at 7:31

GoogleCodeExporter commented 9 years ago
I'm sorry but I don't have another RS232 device but I have an other PL2303 with 
the same results. But I ran a few more tests and on my macbook it works juste 
one time, I have to unplug then replug the PL2303 from the computer to get it 
works an other time.
I also tried to connect the TX pin from one PL2303 to the RX pin of the other 
one and vice-versa and using Coolterm and the screen command on the terminal, I 
was able to communicate from one device to the other, but only on the macbook.

So maybe it's more a driver related problem...

This is what I get from USB Prober : 

        Descriptor Version Number:   0x0110
        Device Class:   0   (Composite)
        Device Subclass:   0
        Device Protocol:   0
        Device MaxPacketSize:   64
        Device VendorID/ProductID:   0x067B/0x2303   (Prolific Technology, Inc.)
        Device Version Number:   0x0300
        Number of Configurations:   1
        Manufacturer String:   1 "Prolific Technology Inc."
        Product String:   2 "USB-Serial Controller"
        Serial Number String:   0 (none)

Prolific claims the support for this device up to Mac OS X 10.8 on this page : 
http://www.prolific.com.tw/US/ShowProduct.aspx?p_id=229&pcid=41 so I don't know 
what to think...

Original comment by navarro....@gmail.com on 27 Nov 2012 at 9:16

GoogleCodeExporter commented 9 years ago
Problem solved! 
It was a driver problem and the funny part is that I found a driver better than 
the Prolific's one.

It's from the osx-pl2303 project and the setup instructions are here : 
http://xbsd.nl/2011/07/pl2303-serial-usb-on-osx-lion.html

It may be a good idea to point out that problem/solution on the project 
homepage since the PL2303 is widely used in the electronic community.

Hope it can helps someone else

Original comment by navarro....@gmail.com on 27 Nov 2012 at 9:37

GoogleCodeExporter commented 9 years ago
Same in #6 helped me too! On Mac OS X 10.7.5

Original comment by g...@robotiklabor.de on 25 Jan 2013 at 10:24

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
I have added this info to the wiki.

Original comment by lists.to...@gmail.com on 9 Dec 2013 at 11:18