+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 20 of 40

[HowTo] Jtag connection

This is a discussion on [HowTo] Jtag connection within the Modding & Development forums, part of the Meizu M8 category; Hello fellow M8 owners, Hereby a dedicated topic on Jtag for M8/SE, since i have not yet been able to ...

  1. #1
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts

    [HowTo] Jtag connection

    Hello fellow M8 owners,


    Hereby a dedicated topic on Jtag for M8/SE,
    since i have not yet been able to test it myself on M8,
    this first post will be rewritten in the near future to contain all important information.

    So where to start?


    Jtag Pinout :





    Jtag cables :

    The slowest working cable but easiest to build is the unbufffered cable.
    You need a few resistors, a lpt plug (parallel port) and wires shorter then 15 cm to avoid noise and problems.
    Unbuffered cable

    JTAG-to-LPT mapping

    TDI - DATA0 - pin 2
    TDO - SELECT - pin 13
    TMS - DATA2 - pin 4
    TCK - DATA1 - pin 3

    One of the most used cables is a buffered, a fabricated version will costs around 100~200 euro, a home made around 30~50 euro.
    The price gives you faster data transport, ability for longer cables and less problems with noise or other.
    Buffered cable (aka :wiggler)


    JTAG-to-LPT mapping

    TDI - DATA3 - pin 5
    TDO - BUSY - pin 11
    TMS - DATA1 - pin 3
    TCK - DATA2 - pin 4
    nSRST - DATA0 - pin 2
    nTRST - DATA4 - pin 6


    Software :

    for windows users you can try OpenOcd or SJF6410 (samsung´s tool)
    for Linux users try OpenOcd patch or Jtag Tools

    Last edited by evow04; 10-23-2009 at 08:08 PM.

  2. #2
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    So let us begin :-)
    what we need,
    witch prebuild cables can be used on m8,
    how will we easily hold the pins to the M8 printboard.. etc.

  3. #3
    Passing By
    Join Date
    May 2009
    Posts
    3
    Thanks
    2
    Thanked 0 Times in 0 Posts
    There are some wiggler compatible JTAG interfaces, for example:
    Development and Prototype boards and tools for PIC AVR and MSP430
    (Click on ARM -> ARM JTAG)

    The parallel port version is quite cheap (relative to the more than 100 $/€ devices):
    ARM AVR MAXQ MSP430 PIC LOW COST DEVELOPMENT BOARDS PRICES PRICES

    Here are some schematics for USB-to-JTAG self-build devices:
    USB to JTAG Interface

  4. #4
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Thanks man!
    that seems very interesting, will have a look onto it!

  5. #5
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Zeerix,

    ive been looking to your links (thanks again)

    Think those are interesting :
    ARM-USB-TINY-H (+-40 euro)


    Amontec JTAGkey-Tiny (+- 29 euro)


    EP-OPENOCD-01 OpenOCD USB Adapter (+-39 euro)

    The last one seems to have jtag ánd RS232 serial connection,
    so for those who do not have it yet : interesting!

    For myself i am thinking that the second one could be very interesting
    (not to high pricetag)


  6. #6
    Passing By
    Join Date
    May 2009
    Posts
    3
    Thanks
    2
    Thanked 0 Times in 0 Posts
    The second one is nice and should work with OpenOCD, but the shipping cost is a cheek. It's > 20 € unless you are from switzerland.
    The third one is cheaper if you consider shipping.
    Check if you find a shop in your country and/or with low shipping.

  7. #7
    Member
    Join Date
    Nov 2008
    Location
    Germany
    Posts
    152
    Thanks
    8
    Thanked 12 Times in 8 Posts
    i have to say, that i have no experience with jtag.... so how to do it? i mean, what do i have to do when a have a jtag adapter ?!

    raoul

    edit: can anyone verify that this works?
    http://cgi.ebay.com/JTAG-programmer-...13169005r21573
    Last edited by raangu; 10-25-2009 at 08:22 PM.

  8. #8
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Zeerix,
    thanks again for the feedback!

    At the moment i still do not have my m8 back,
    so i am investigating my options at the moment
    (the real shame is that i can not find a local shop in belgium that sells it
    ).

    raangu, like you noticed it is been a while ago for me that i used jtag.
    Normaly you should:

    *connect jtag to m8
    *connect to pc
    *run the jtag software
    => then read and dump firmware to pc
    => or write firmware to m8
    => or debug software from m8

    Now for the first 2 things any jtag cable should do since you only need
    TDI - TDO - TMS - TCK connections
    for the last one (debug) you need a jtag that can speak to the other pin´s.

    Now to read/write the best thing we could have is openocd support (very often used ) or the sjf tools.

    about the cable, i am also interested in itbut not sure if it fully supports m8, maybe best thing to do is contact the seller and ask if it would support the pins mentioned in the layout?

  9. #9
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Guys,

    could anyone of you with an m8 make a real size draw from the battery
    and take note of the exact size & distances for the pinout?
    example :

    The idea after this :
    then you would be able to make a 'fake' battery in plexiglass,
    cut out a socket for the sim holder and drill holes where the jtag pinout is located. Then we could place pogo-pins in those holes and there would be no need for soldering jtag to M8.. since the "holder" would fit in like a battery and does not move around .. but can be removed anytime:-)

    Good idea isnt? I am sure it makes life easier while jtagging M8!

    For those who do not know pogo-pins, it are pressure pins, this lets you make a good contact with the M8 pcb.
    example :


    edit: can anyone verify that this works?
    http://cgi.ebay.com/JTAG-programmer-...13169005r21573
    some research shows it is a fake ulink, look here for the original.
    I assume it would work for writing and debugging,
    and the ebay one has a good price
    (one of the cheapest incl. shippingcost for this kind device)

    Features:
    • Connects your PC or notebook's USBport to your target ARM hardware allowing you to debug C programmesrunning on the target board
    • Allows you to debug and Flash programme ARM chips
    • On-chip debugging via on-chip JTAG
    • 28KB/s memory read/write speed
    • 15KB/s Flash write speed
    • Supports JTAG clock speeds of up to 1MHz
    • Supports µVision IDE/Debugger
    • Unlimited RAM breakpoints
    • Supports ARM7, ARM9 and Cortex-M3 device families
    • Supports multiple breakpoints
    • LED indicator light and USB powered
    i also found this one :
    USB BUFFERED ALL IN ONE FTA JTAG PANSAT 3500/2500/2700

    it does not have debugger, but same seller has pogo-pins..



    EDIT

    Main reason i did not yet buy new jtag is due the slow replacement proces for my M8. However this give me time to investigate jtag adapter.
    I contacted reseller from the 3 jtag cables in the above post, but non of them answers my questions.
    For now myself i am mostly interested the jtagkey-tiny.
    I found the following schematic pdf : AESOP 6410 (by googling this way)
    You will notice at the jtag pinout the following :
    xRTCK - xTDO - xTDI - xTCK - xTMS - xTRSTn
    So this means whe have on m8 pinout the following leftover:
    CTS - NRESET - 3Volt (i do not count Ground with it)
    Nreset is linked to the reset system in the SOC m8 uses
    and cts seems to be found in the uart part.
    so i wil investigate more soc schematics to be sure, but ATM i think if you have the first pinout i just mentionned you jtag should work perfect.


    now will check this pdf
    Last edited by evow04; 11-02-2009 at 06:54 PM.

  10. #10
    Valued Member
    Join Date
    Sep 2009
    Location
    Germany
    Posts
    1,309
    Thanks
    249
    Thanked 200 Times in 145 Posts
    Hi, here are my findings on the M8 SE 8GB:

    first my old measurement:
    Quote Originally Posted by Loonix View Post
    Well, here are my measurements



    and again as text
    01: 2,85
    02: 0,04
    03: 0,04
    04: 0,04
    05: 0,01
    06: 0,80
    07: 4,13 - 4,16
    08: 3,06
    09: 0,00 (GND? )
    10: 3,04
    11: 0,00
    12: 0,35 - 0,38
    13: 0,16 - 0,19
    14: 3,04
    15: 0,15 - 0,19
    16: 3,04
    17: 0,17 - 0,19
    18: 0,00
    19: 0,00 (had written down a 3,04 first but may have ben misstaken)
    20: 0,29 - 0,36
    21: 0,00
    22: GND? (<- this is the pin i measured from)
    and then my 'new' test measured from the - pole of the battery
    01: 2,85v
    02: 0,03v | 65 - 70K-Ohm
    03: 0,03v | 65 - 70K-Ohm
    04: 0,03v | 65 - 70K-Ohm
    05: 0,00v | 39 - 41K-Ohm
    06: 0,78v - 0,78v
    07: 4,11v - 4,14v
    08: 3,04v
    09: 0,00v | 0,3-0,4ohm (GND? )
    10: 3,02v
    11: -0,01v | 10,5 - 10,7K-Ohm
    12: 0,50v - 0,54v
    13: 0,20v - 0,22v
    14: 3,02v
    15: 0,16v - 0,19v
    16: 3,02v
    17: 0,31v - 0,35v
    18: -0,01v | 29,3Ohm
    19: 3,02v (o.O the 0,00 value is gone, must have been a testing error or something)
    20: 0,30v - 0,34v
    21: -0,01v | 28,9 - 29,1Ohm
    22: -0,01v 0,3-0,4Ohm (GND? )

    Where i gave no Ohm value it was beyond the M-Ohm range.
    I hope someone who knows his way around JTAG can do something with these values!
    Meizu M8 SE - FW 0.9.9.18 (dao89 n450) Dualboot LBE A11 Android 2.2

  11. #11
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Great!
    pin 1 - 8 - 10 - 14 - 16 - 19 could be the 3v jtag pin.

    About the others, if someone with normal m8 would post his measurements about it, it would be an easy comparisation between them...

  12. #12
    Passing By
    Join Date
    Nov 2009
    Posts
    3
    Thanks
    0
    Thanked 2 Times in 2 Posts
    Hi!

    Great stuff!
    This tool and hardware (buffered LPT-adaptor) could also be very useful:
    http://www.mt-system.ru/documents/sj...1_20071206.zip

    As far as i remember there's also some modified SJF code at the aesop site.

    Keep on hacking

    scholbert

  13. Member who thanked scholbert for the post:


  14. #13
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Quote Originally Posted by evow04 View Post
    About the others, if someone with normal m8 would post his measurements about it, it would be an easy comparisation between them...
    No one that is willing to meassure the jtag pins to help loonix further?

  15. #14
    Senior Member
    Join Date
    Sep 2009
    Posts
    380
    Thanks
    3
    Thanked 138 Times in 53 Posts
    i will see when i have freetime i will do a measurement

    Here they are. Just our 8 pins in the order
    SIM
    1234
    5678
    measured with powerd on m8 over usb line against bat -
    0 3.02 0.03 0.27-0.33 0
    0 3.02 2.99-3.00 3.02 3.02
    Last edited by r3wDy; 11-09-2009 at 07:10 PM.

  16. Member who thanked r3wDy for the post:


  17. #15
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    cool!
    that is eliminating a few pins, but then again , there are a few that could be the same :s

  18. #16
    Member
    Join Date
    Mar 2009
    Posts
    130
    Thanks
    1
    Thanked 113 Times in 35 Posts
    I got 50 nude pogo-pins two weeks ago.
    and I ordered some blank PCB today.
    I'll try to make my connector this weekend.

  19. #17
    Valued Member
    Join Date
    Aug 2008
    Location
    Belgium
    Posts
    2,434
    Thanks
    127
    Thanked 189 Times in 130 Posts
    Great! it is nice to see how professionally you are doing all this!
    I am really interested in your progress and new findings once jtag works!

    ps Banxian, did you manage to get usb (with ttl) on the M8SE working like on m8?

  20. #18
    Passing By
    Join Date
    May 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    M8SE

    Hi, veterans! this pinout is just for M8 but is not for M8SE.
    Anybody knows how to get the JTAG pinout for M8SE?
    Thanks!
    Attached Images

  21. #19
    Member
    Join Date
    Mar 2009
    Posts
    130
    Thanks
    1
    Thanked 113 Times in 35 Posts
    Two failed connector Board for M8 (not SE).
    I think I can make a fine borad this week.
    Attached Images
    Last edited by banxian; 06-13-2010 at 11:03 PM.

  22. 3 members have thanked banxian:


  23. #20
    Passing By
    Join Date
    May 2010
    Posts
    12
    Thanks
    0
    Thanked 4 Times in 2 Posts
    @banxian
    big up!


 

Similar Threads

  1. [HowTo] Create UI-Themes for M8
    By crimson05 in forum M8 Skinning & Themes
    Replies: 7
    Last Post: 12-13-2010, 01:33 PM
  2. [HowTo] Configure GPRS & MMS in 0.9.2.7
    By crimson05 in forum M8 Firmware
    Replies: 58
    Last Post: 04-09-2010, 09:56 PM
  3. HOWTO: Maps with Meizu
    By member in forum Video and Imaging
    Replies: 37
    Last Post: 10-19-2008, 09:52 AM
  4. HowTo access the player while charging?
    By phazer in forum music card M3
    Replies: 2
    Last Post: 06-25-2007, 08:14 AM
  5. HowTo for installing skins?
    By wolffsed in forum Modifications and Skins
    Replies: 2
    Last Post: 01-24-2007, 01:32 PM