ZAP programming on MacOSX


rfunderburk

Recommended Posts

Hello,

 

I have compiled ZAP for MacOSX and everything works but the actual program loading.  Here is the exchange between the zpuinoprogrammer and the ZPUino on Papilio Pro (LX9), Vanilla Variant:

 

 

---------------------------------------------------------------------------------------------------------
 
./zpuinoprogrammer -s 1000000 -R -vvv -d /dev/cu.usbserial-00002006B -b PhaseMeasure.cpp.bin 
Opened device '/dev/cu.usbserial-00002006B'
Connecting...
[1375704106.986641] Tx: 0x7e 0x01 0x1e 0x0e 0x7e
[1375704107.000600] Rx: 0x7e 0x81 0x01 0x09 0x06 0x00 0x00 0x7f 0xef 0x80 0x05 0xb8 0xd8 0x00 0xa4 0x04 0x17 0x00 0x9b 0x1c 0x7e
Got packet size 17
Got programmer version 1.9
SPI offset: 393216
CODE size: 8384384
Board: Unknown board @ 96000000 Hz (0xa4041700)
[1375704107.000784] Tx: 0x7e 0x02 0x2c 0x95 0x7e
[1375704107.016462] Rx: 0x7e 0x82 0xc2 0x20 0x17 0x00 0x75 0x58 0x7e
Got packet size 5
SPI flash information: 0xc2 0x20 0x17, status 0x00
Detected MX25L6445E flash
Will program sector 6 (page 1536), original offset 0x00060000
Need to program 6128 6144 bytes (24 pages)
Reading data, 6124 bytes
Computing sketch CRC (6124)
Final CRC: 5545
Settting baudrate divider to 5
[1375704107.016817] Tx: 0x7e 0x08 0x00 0x00 0x00 0x05 0x3d 0x05 0x7e
[1375704107.032527] Rx: 0x7e 0x88 0x07 0xc7 0x7e
Got packet size 1
Connecting at new speed (1000000)...
[1375704107.032590] Tx: 0x7e 0x01 0x1e 0x0e 0x7e
[1375704107.233661] Tx: 0x7e 0x01 0x1e 0x0e 0x7e
[1375704107.434793] Tx: 0x7e 0x01 0x1e 0x0e 0x7e
 
  ... Above repeated 29 times ...
 
Entering program mode
[1375704125.135058] Tx: 0x7e 0x05 0x58 0x2a 0x7e
[1375704126.137024] Tx: 0x7e 0x05 0x58 0x2a 0x7e
[1375704127.138137] Tx: 0x7e 0x05 0x58 0x2a 0x7e
Cannot enter program mode
 
---------------------------------------------------------------------------------------------------------
 
The programmer works fine for this board when running the Windows version.
 
Any thoughts?

Thanks,
Richard
Link to comment
Share on other sites

Well, partially works; gets a programming error and creates a brick. :)

 

I am able to run with a VM running WinXP on this mac and it works fine.  I also was able to load with the version before 'Zap', but I updated my serial drivers when first had trouble with 'Zap' so don't know the state of that right now.

 

I will try updating the drivers for the serial ports.

Link to comment
Share on other sites

Put together an autoconf.sh, added a "sysconf.h" (doesn't exist), modified "programmer.h" (add missing prototype), added a makeargv.c (doesn't exist in source) and I could then compile the code.  Unfortunately it gets a segmentation fault:

 

 

./zpuinoprogrammer -s 1000000 -vvv -R -d /dev/cu.usbserial-00001004B -b PhaseMeasure.cpp.bin 
Opened device '/dev/cu.usbserial-00001004B'
Connecting...
[1376062965.016544] Tx: 0x7e 0x01 0x1e 0x0e 0x7e
[1376062965.016613] Rx: 0x43
[1376062965.030355] Rx: 0x7e 0x81 0x01 0x09 0x06 0x00 0x00 0x7f 0xef 0x80 0x05 0xb8 0xd8 0x00 0xa4 0x04 0x17 0x00 0x9b 0x1c 0x7e
Got packet size 17
Segmentation fault: 11
 
I'll have to debug when I get more time.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.