SPI to MX25L4006E Flash PROM


Today 08:45
Forum: The Lounge
Starter: normnet
Views: 0
Replies: 2
Yesterday 15:38
Forum: Proton Plus Compiler v3
Starter: gdesantis
Views: 0
Replies: 4
+ Reply to Thread
Results 1 to 10 of 10

Thread: SPI to MX25L4006E Flash PROM181 days old

  1. #1
    Junior Member mjturner's Avatar
    Join Date
    Dec 2003
    Posts
    70
    Thumbs Up
    Received: 8
    Given: 0
    Total Downloaded
    392.84 MB

    0 Not allowed!

    Default SPI to MX25L4006E Flash PROM

    I've been trying to get a PIC to read data from the MX25L4006E but I'm getting so frustrated! I've connected it via SPI and I've tried via both the hardware SPI and by manually bit-banging it in my own code. Each command I send gets a response that is in line with my expectations around response length, it is reliable in that if I issue a certain command I always get the same reply. However the reply content is not what I am expecting!

    By way of an example - when querying the identifier via RDID using command 0x9F the expected output is C22013 (b110000100010000000010011). What I actually get is 700700 (b011100000000011100000000), the bits could be shifted by 1 here, but the same bit pattern results from using the hardware SPI as well. If I continue reading it repeats itself, which is exactly what the documentation describes will happen. So I am reading something, it just isn't what I expect. The same goes for data programmed in to the device, I can read it with my programmer just fine, it looks perfect, but when I read it using commands I get completely different data - but again it is always the same data stream.

    Happy to share code, but given that I get the same bit sequence from bit-bang and SPI, and I've tried all 4 SPI modes just in case.... I'm honestly stuck. Is there something up with this version of chip? I'm quite happily reading other devices on the same SPI bus, such as an RFID reader. I've tried testing with and without the RFID reader on the bus. Any suggestions on what I can do to find out why this isn't working?

  2. #2
    Senior Member Henk57's Avatar
    Join Date
    Jan 2014
    Posts
    401
    Thumbs Up
    Received: 40
    Given: 35
    Total Downloaded
    192.60 MB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    I haven't the answer your looking for, but I will advise you to buy a LA there are many, starting with $10
    Logic Analyzer with 8 channels and 24MHz sample rate will do, but ZeroPlus LA-C 16128 is almost unbeatable $$$.

    Visit (sigrok.org) and (sigrok.org/wiki/Supported_hardware) their software PulseView (incl. SPI) works fine with Windows OSX and Linux.

    Henk.

  3. #3
    Prolific Poster towlerg's Avatar
    Join Date
    Mar 2012
    Posts
    1,857
    Thumbs Up
    Received: 163
    Given: 162
    Total Downloaded
    3.24 GB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    I'm sure the ZeroPlus LA-C 16128 is a great bit of kit but a bit expensive. You can buy a Salea clone on ebay for 5 and free delivery here . You don't even need to feel quilty about using a clone, Saleae don't sell that model anymore but there latest (try the beta it has some nice features) software will run just fine.
    George

  4. #4
    Fanatical Contributor Les's Avatar
    Join Date
    Feb 2002
    Posts
    3,021
    Thumbs Up
    Received: 315
    Given: 120
    Total Downloaded
    1.51 GB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    Be careful with the Chinese Salea clones. They don't work!

    Salea changed their PC app and the firmware inside the Chinese clones is not recognised. I know, because I bought one, and it's been in the cupboard ever since, because it does not work.
    For more example programs for Proton and Proton24 or updates, please visit: Proton WIKI or Proton Files

  5. #5
    Prolific Poster towlerg's Avatar
    Join Date
    Mar 2012
    Posts
    1,857
    Thumbs Up
    Received: 163
    Given: 162
    Total Downloaded
    3.24 GB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    I bought one recently (4 months) to replace my hand built clone, it works perfectly. The trick the Salea used to detect clones was the external EEPROM. In the original design (which by the way is lifted directly from the Cypress reference design, as is USBEE) a small EEPROM was used which is now expensive than larger ones so they obviously used the cheaper one. Current clones reverted to the use of the smaller one and bob's your uncle.

    Anyway it's 5 so what have you got to lose. Even if you're unlucky and get old stock you can still run the version before they implemented the EEPROM check which will decode your SPI a just fine.

    By the way, contrary to what you may have read on the internet, you won't brick it. All that happens is the PID/SID in the EEPROM gets overwritten. I seem to remember there is a Cypress utility that lets you write to the EEPROM.

    Trust me, it's the best value you'll ever get for 5, the only real downside is the 6 weeks you have to wait to get it.

    BTW you can download the latest software from Saleae.com and it will run in demo mode.
    George

  6. #6
    Junior Member mjturner's Avatar
    Join Date
    Dec 2003
    Posts
    70
    Thumbs Up
    Received: 8
    Given: 0
    Total Downloaded
    392.84 MB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    Thanks - I'll take a look, sadly 6 weeks wait isn't going to cut it for the time I need to get this ready and working. Frustratingly - I know I did have some form of cheap logic analyser somewhere. It is one of those things where I didn't need it at the time, so it is in a box somewhere.... I've never used a logic analyser, any tips on how to use it to diagnose the issue I'm seeing?

  7. #7
    Prolific Poster towlerg's Avatar
    Join Date
    Mar 2012
    Posts
    1,857
    Thumbs Up
    Received: 163
    Given: 162
    Total Downloaded
    3.24 GB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    Once you see what's actually coming and going all will become clear (well you never know your luck). Anyway atleast the LA will decode the signals for you.

    I'm sure you can find a UK (or whereever you are) supplier of Saleae clones, you'll just have to pay a bit more.
    George

  8. #8
    Member GAMBOA's Avatar
    Join Date
    Nov 2004
    Posts
    364
    Thumbs Up
    Received: 15
    Given: 0
    Total Downloaded
    105.11 MB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    An other option is:

    http://www.pctestinstruments.com/index.htm
    386USD

    Regards,
    Gamboa

  9. #9
    Fanatical Contributor Les's Avatar
    Join Date
    Feb 2002
    Posts
    3,021
    Thumbs Up
    Received: 315
    Given: 120
    Total Downloaded
    1.51 GB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

    Excellent info George, thanks.

    I'll take a look and make some changes. Now.... Every penny counts.
    For more example programs for Proton and Proton24 or updates, please visit: Proton WIKI or Proton Files

  10. #10
    Junior Member Dave Purola's Avatar
    Join Date
    Jul 2004
    Posts
    33
    Thumbs Up
    Received: 9
    Given: 0
    Total Downloaded
    68.55 MB

    0 Not allowed!

    Default Re: SPI to MX25L4006E Flash PROM

  11. I have been using a LOGICPORT 34 channel for about 2 years or so and it works great. It helped me find a flaw in the 3D printer software for the system I built running on an ARDUINO. It was loosing steps and come to find out it was the software. I have since gone to a Smoothieboard 4xC board with out any problems. Thanks LOGICPORT....

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. New Microchip 1.8v SPI flash memory
    By normnet in forum New devices and techniques
    Replies: 0
    Last Post: 13th June 2014, 11:59
  2. New Microchip 1.8v SPI flash memory
    By normnet in forum The Lounge
    Replies: 0
    Last Post: 13th June 2014, 11:59
  3. SPI - (Can't belive a search on SPI yields no results?)
    By Peter Truman in forum Proton Plus Compiler v3
    Replies: 12
    Last Post: 30th September 2012, 10:12
  4. Trying to use FRAM Prom
    By stevewidg in forum Proton Plus Compiler v3
    Replies: 9
    Last Post: 14th February 2008, 16:26

Members who have read this thread since 3rd December 2018, 19:07 : 0

Actions :  (Set Date)  (Clear Date)

You do not have permission to view the list of names.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts