Main Menu

OS X support

Started by peterhull90, June 16, 2013, 01:46:51 PM

Previous topic - Next topic

devlware

Hi Andy,

I got it!

This is my directory list (/Applications/FlashMagic.app/Contents/Resources/dosdevices):
lrwxr-xr-x   1 admin  admin    27 Jul 16 00:25 COM10 -> /dev/tty.Bluetooth-PDA-Sync
lrwxr-xr-x   1 admin  admin    32 Jul 16 00:25 COM11 -> /dev/tty.DiegoAntunessiPhone-Wir
lrwxr-xr-x   1 admin  admin    32 Jul 16 00:25 COM12 -> /dev/tty.DiegoAntunessiPhone4-Wi
lrwxr-xr-x   1 admin  admin    18 Jul 16 00:25 COM13 -> /dev/tty.usbserial
lrwxr-xr-x   1 admin  admin    23 Jul 16 00:25 COM4 -> /dev/cu.Bluetooth-Modem
lrwxr-xr-x   1 admin  admin    26 Jul 16 00:25 COM5 -> /dev/cu.Bluetooth-PDA-Sync
lrwxr-xr-x   1 admin  admin    31 Jul 16 00:25 COM6 -> /dev/cu.DiegoAntunessiPhone-Wir
lrwxr-xr-x   1 admin  admin    31 Jul 16 00:25 COM7 -> /dev/cu.DiegoAntunessiPhone4-Wi
lrwxr-xr-x   1 admin  admin    17 Jul 16 00:25 COM8 -> /dev/cu.usbserial
lrwxr-xr-x   1 admin  admin    24 Jul 16 00:25 COM9 -> /dev/tty.Bluetooth-Modem
lrwxr-xr-x   1 admin  admin    10 Jul  5 09:25 c: -> ../drive_c
lrwxr-xr-x   1 admin  admin    21 Jul  5 09:25 d: -> /Volumes/FlashMagic 1
lrwxr-xr-x   1 admin  admin    13 Jul  5 09:25 d:: -> /dev/rdisk2s1
lrwxr-xr-x   1 admin  admin    21 Jul  5 09:25 e: -> /Volumes/FlashMagic 2
lrwxr-xr-x   1 admin  admin    13 Jul  5 09:25 e:: -> /dev/rdisk1s1
lrwxr-xr-x   1 admin  admin    13 Jul  5 09:25 f:: -> /dev/rdisk1s2
lrwxr-xr-x   1 admin  admin     1 Jul  5 09:25 z: -> /

I used COM13 to program the device, this is a prolific USB->Serial converter plugged on a MAX3222
that connects to the lpc800 mini-kit.

Regards, Diego

peterhull90

It seems to work OK so far for me. I have not actually programmed the flash but I can get the CPU id and open up a terminal so I believe it will be fine. I'll report back when I've done the programming.
My set-up: LPC800 mini board with LPC810, OS X 10.8.4, SILABS CP2102-based USB-serial converter. The com ports are set up like this
lrwxr-xr-x  1 peterhull  admin  23 15 Jul 21:58 COM4 -> /dev/cu.Bluetooth-Modem
lrwxr-xr-x  1 peterhull  admin  26 15 Jul 21:58 COM5 -> /dev/cu.Bluetooth-PDA-Sync
lrwxr-xr-x  1 peterhull  admin  22 15 Jul 21:58 COM6 -> /dev/cu.SLAB_USBtoUART
lrwxr-xr-x  1 peterhull  admin  24 15 Jul 21:58 COM7 -> /dev/tty.Bluetooth-Modem
lrwxr-xr-x  1 peterhull  admin  27 15 Jul 21:58 COM8 -> /dev/tty.Bluetooth-PDA-Sync
lrwxr-xr-x  1 peterhull  admin  23 15 Jul 21:58 COM9 -> /dev/tty.SLAB_USBtoUART

and I used COM9 to connect at 115000 baud.

Using Wine is not ideal I suppose but it does work and beggars can't be choosers!

Pete

Andy Ayre

Thanks for posting feedback! Yes, using Wine is not ideal but it saves a huge amount of development effort for us and makes regular updates possible.

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

hubert

Sorry for the late response.

Changing permissions did not help for me (home system), but...

I tested it at my work Mac and there it worked perfectly. I will investigate if there is a driver difference between the two systems.


Hubert

Andy Ayre

If you could report back on what you find that would be greatly appreciated!

Same version of OS X on both Macs?

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

hubert

Work Mac (flashmagic works fine):
OS version 10.8.4

USB info:
FT232R USB UART:
  Product ID:   0x6001
  Vendor ID:   0x0403  (Future Technology Devices International Limited)
  Version:    6.00
  Serial Number:   A600K1PQ
  Speed:   Up to 12 Mb/sec
  Manufacturer:   FTDI
  Location ID:   0xfa123000 / 5
  Current Available (mA):   500
  Current Required (mA):   90

ls -la /dev/*A600*
crw-rw-rw-  1 root  wheel   18,   9 17 jul 17:57 /dev/cu.usbserial-A600K1PQ
crw-rw-rw-  1 root  wheel   18,   8 17 jul 17:57 /dev/tty.usbserial-A600K1PQ

ls -la COM*
lrwxr-xr-x  1 hubert  admin  24 17 jul 17:58 COM10 -> /dev/tty.PL2303-004012FA
lrwxr-xr-x  1 hubert  admin  27 17 jul 17:58 COM11 -> /dev/tty.usbserial-A600K1PQ
lrwxr-xr-x  1 hubert  admin  23 17 jul 17:58 COM4 -> /dev/cu.Bluetooth-Modem
lrwxr-xr-x  1 hubert  admin  26 17 jul 17:58 COM5 -> /dev/cu.Bluetooth-PDA-Sync
lrwxr-xr-x  1 hubert  admin  23 17 jul 17:58 COM6 -> /dev/cu.PL2303-004012FA
lrwxr-xr-x  1 hubert  admin  26 17 jul 17:58 COM7 -> /dev/cu.usbserial-A600K1PQ
lrwxr-xr-x  1 hubert  admin  24 17 jul 17:58 COM8 -> /dev/tty.Bluetooth-Modem
lrwxr-xr-x  1 hubert  admin  27 17 jul 17:58 COM9 -> /dev/tty.Bluetooth-PDA-Sync


Home Mac (flashmagic does not works):
OS version 10.7.5

USB info:
FT232R USB UART:
  Product ID:   0x6001
  Vendor ID:   0x0403  (Future Technology Devices International Limited)
  Version:    6.00
  Serial Number:   A600K1PQ
  Speed:   Up to 12 Mb/sec
  Manufacturer:   FTDI
  Location ID:   0xfd630000 / 3
  Current Available (mA):   500
  Current Required (mA):   90

ls -la /dev/*A600*
crw-rw-rw-  1 root  wheel   17,  13 16 jul 22:41 /dev/cu.usbserial-A600K1PQ
crw-rw-rw-  1 root  wheel   17,  12 16 jul 22:41 /dev/tty.usbserial-A600K1PQ

ls -la COM*
lrwxrwxrwx  1 hhoef  admin  23 13 jul 15:39 COM4 -> /dev/cu.Bluetooth-Modem
lrwxrwxrwx  1 hhoef  admin  26 13 jul 15:39 COM5 -> /dev/cu.Bluetooth-PDA-Sync
lrwxrwxrwx  1 hhoef  admin  17 13 jul 15:39 COM6 -> /dev/cu.usbserial
lrwxrwxrwx  1 hhoef  admin  26 13 jul 15:39 COM7 -> /dev/cu.usbserial-A600K1PQ
lrwxrwxrwx  1 hhoef  admin  24 13 jul 15:39 COM8 -> /dev/tty.Bluetooth-Modem
lrwxrwxrwx  1 hhoef  admin  27 13 jul 15:39 COM9 -> /dev/tty.Bluetooth-PDA-Sync
lrwxrwxrwx  1 hhoef  admin  18 13 jul 15:39 COM10 -> /dev/tty.usbserial
lrwxrwxrwx  1 hhoef  admin  27 13 jul 15:39 COM11 -> /dev/tty.usbserial-A600K1PQ


Hubert

Andy Ayre

You could try changing the permissions of the symbolic links to match, although it probably won't help.

chmod 755 COM*

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

Daniel128

#22
Hello,
I have strange problem at work of terminal in version 7.5 on Mac OS 10.8.5. After run terminal, it's receiving data from device only around 5 second and stops working. Transmit data to device is posible at all times.
ISP programing works OK.

Daniel

Andy Ayre

I recommend you use a different terminal rather that the one that is built in.

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

Yutaro Oguchi

#24
Hi Pete,

2014-10-14: At this time I knew that this is not a solution for your problem. Reason why is in the Reply #25 & #26.
Very sorry.  Using COMn as a FM's default is a best way.

Yutaro

------( 2014-10-13 posted message below )-----
Now it works fine. But it's too late ?

I gave it up last year because I met with a problem same as you.
For these past several days, I searched for the websites and challenged it again, but the result was no use.
However, I had solution by the problems this time.
The big difference is a thing with the following items.

   a.   9600 [bps]
   b.   Enable (check mark) the "Use my timeouts for ISP operations" of "Timeouts" of
      "Advanced Options..." in menu bar.

         
Next time you might have a same problem we had been, the solution is do the symbolic link again with ln command.

My environment:
   - MacBook Air 2012 Mid model
   - Mac OS X Version 10.9.5
   - Silicon Lab CP210x Driver for Mac (Mac_OSX_VCP_Driver.zip)
   - FlashMagic Version 8.16 ( use FM as abbr. )
   - LPXpresso Version 7.4.0 ( 2014-09-16 )
   - Target MCU named MARY MB with SiLab CP2104 USB chip
         ( NXP LPC1114LV/301, Oscillator: 12 [MHz], so NO Xtal ==> slow [bps] )
   - USB cable : A to mini-B

1.   Turn on the FlashMagic.app.
2.   Open Terminal window.
   $ cd /Applications/FlashMagic.app/Contents/Resources/dosdevices
   $ ls   ; <--- check the current info if COM3 disappeared.
         ; Next time, the COM3 will disappeared if FlashMagic abort.
3.   Connect the target MCU via USB cable.
      - Target program will running if programmed.
4.   Go back to the Terminal window.
   $ ls /dev/cu*
   /dev/cu.Bluetooth-Incoming-Port   /dev/cu.SLAB_USBtoUART
   /dev/cu.Bluetooth-Modem
   $ ls   
   if symbolic link COM3 is not exist then type the following command
      $ ln -s /dev/cu.SLAB_USBtoUART COM3
   If some settings are wrong or not fit for FM and/or TargetMCU then
   FlashMagic for Mac (v8.16) will often abort with no messages or hang up on START push.
   I suppose it caused COM3 disappeared.
   
Flash Magic Settings:
   Step 1:
      COM Port:    COM3
      Baud Rate:    9600   ; NOT 115200
      Interface:   None (ISP)
      Oscillator [MHz]:   12
   Step 2:
      "Erase blocks used by Hex File" <-- Enable
   Step 3:
   Step 4:
      "Fill unused flash" <-- Enable
   Advanced Options:
      Hardware Config:
         "Use DTR and RTS to control RTS and ISP pin" <-- Enable
      Timeouts:
         "Use my timeouts for ISP operations" <-- Enable
         , and then push the "OK" button.

After pushing the "Start" button, if you have this dialogue message below,
but the way left here is merely choose one "Yes".

   Warning Message from FlashMagic :
      The device signature does not match the expected values, Accessing a
      device using the wrong protocol could the render the device unusable.
      Do you want to continue ?
         Yes   or No

Yutaro      

Andy Ayre

So the root cause is the symbolic link to COM3 disappearing or missing?

On startup FM deletes all symbolic links and recreates them. Please try doing the following and letting us know the result (the following is in a bash script):

rm -rf /Applications/FlashMagic.app/Contents/Resources/dosdevices/COM*
portnum=4
for f in /dev/cu.*
do
  echo "$f - COM$portnum"
  ln -s "$f" "/Applications/FlashMagic.app/Contents/Resources/dosdevices/COM$portnum"
  (( portnum += 1 ))
done

Also could be that you are running FM without enough permissions to create the symbolic links?

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

Yutaro Oguchi

#26
Hi Andy ( & Pete ),

I may have to apologize for former comment (Reply #24) I posted that is NOT a solution for Pete's problem.
I have written wrong comment by the matter that I overlooked.

In Andy's Reply #25:>
   On startup FM deletes all symbolic links and recreates them. ...

I just knew the function of the initial movement of FM in what Andy pointed out above.
I connected the target, and then checked the symbolic links on startup FM.

   $ cd /Applications/FlashMagic.app/Contents/Resources/dosdevices
   $ ls -l COM*
   lrwxr-xr-x  1 yutaro  admin  31 Oct 14 22:24 COM4 -> /dev/cu.Bluetooth-Incoming-Port
   lrwxr-xr-x  1 yutaro  admin  23 Oct 14 22:24 COM5 -> /dev/cu.Bluetooth-Modem
   lrwxr-xr-x  1 yutaro  admin  22 Oct 14 22:24 COM6 -> /dev/cu.SLAB_USBtoUART
   lrwxr-xr-x  1 yutaro  admin  32 Oct 14 22:24 COM7 -> /dev/tty.Bluetooth-Incoming-Port
   lrwxr-xr-x  1 yutaro  admin  24 Oct 14 22:24 COM8 -> /dev/tty.Bluetooth-Modem
   lrwxr-xr-x  1 yutaro  admin  23 Oct 14 22:24 COM9 -> /dev/tty.SLAB_USBtoUART

COM6 (that I overlooked) is appeared as a correct symbolic link for my target MCU.

FM's settings:
   Step 1:
      Baud Rate: 115200 [bps]   ;
   Advanced Options:
      Hardware Config:
         "Use DTR and RTS to control RTS and ISP pin" <-- Enable
      Timeouts:
         "Use my timeouts for ISP operations" <--- No check

By using COM6, my problem has gone away, and it works VERY FINE very fast.
Thank you, Andy.

So I think for now it should remove the last post (Reply #24).

Yutaro

nggeman

Very useful topic, helps me as well