Code Monkey home page Code Monkey logo

Comments (3)

ufrisk avatar ufrisk commented on May 18, 2024

I don't know if this is the error, I'm unfortunately not very knowledgeable about OpenOCD, but I know others had problems with not powering the PCIeScreamer via PCIe or barrel jack. The power that the JTAG flash cable provides alone isn't enough. Power via PCIe should be fine though.

Also make sure you flash the PCILeech bitstream, I don't know if this is the case, but if you flash the LambdaConcept bitstream it will blink the LEDs on the PCIeScreamer.

After a flash the board have to be power cycled for the changes to take effect.

from pcileech-fpga.

CuriosoCat avatar CuriosoCat commented on May 18, 2024

Thanks for the advice, @ufrisk! Just an update, I managed to overcome those problems by rebuilding openocd with an appended --enable ftdi to the ./configure command and installing lib-usb dependencies. I also updated the openocd rules file to /etc/udev/rules.d in Linux. I'm now facing the output below:

$ sudo openocd -f flash_screamer.cfg
Open On-Chip Debugger 0.10.0+dev-00631-ga15c11d (2018-12-26-14:04)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
none separate
Info : auto-selecting first available session transport "jtag". To override use 'transport select '.
adapter speed: 10000 kHz
Info : ftdi: if you experience problems at higher adapter clocks, try the command "ftdi_tdo_sample_edge falling"
Info : clock speed 10000 kHz
Info : JTAG tap: xc7.tap tap/device found: 0x0362d093 (mfg: 0x049 (Xilinx), part: 0x362d, ver: 0x0)
loaded file bscan_spi_xc7a35t.bit to pld device 0 in 0s 219832us
Info : JTAG tap: xc7.tap tap/device found: 0x0362d093 (mfg: 0x049 (Xilinx), part: 0x362d, ver: 0x0)
Info : Found flash device 'micron n25q256 3v' (ID 0x0019ba20)
Warn : device needs paging or 4-byte addresses - not implemented
flash 'jtagspi' found at 0x00000000
auto erase enabled
Info : Found flash device 'micron n25q256 3v' (ID 0x0019ba20)
Warn : device needs paging or 4-byte addresses - not implemented
Info : Found flash device 'micron n25q256 3v' (ID 0x0019ba20)
Warn : device needs paging or 4-byte addresses - not implemented
Info : Found flash device 'micron n25q256 3v' (ID 0x0019ba20)
Warn : device needs paging or 4-byte addresses - not implemented
Info : sector 0 took 0 ms
Info : sector 1 took 0 ms
Info : sector 2 took 0 ms
Info : sector 3 took 1 ms
Info : sector 4 took 0 ms
Info : sector 5 took 0 ms
Info : sector 6 took 0 ms
Info : sector 7 took 1 ms
Info : sector 8 took 0 ms
Info : sector 9 took 0 ms
Info : sector 10 took 0 ms
Info : sector 11 took 1 ms
Info : sector 12 took 0 ms
Info : sector 13 took 0 ms
Info : sector 14 took 0 ms
Info : sector 15 took 1 ms
Info : sector 16 took 0 ms
Info : sector 17 took 0 ms
Info : sector 18 took 0 ms
Info : sector 19 took 1 ms
Info : sector 20 took 0 ms
Info : sector 21 took 0 ms
Info : sector 22 took 0 ms
Info : sector 23 took 1 ms
wrote 1572864 bytes from file pcileech_pciescreamer_top.bin in 9.611363s (159.811 KiB/s)
Info : Found flash device 'micron n25q256 3v' (ID 0x0019ba20)
Warn : device needs paging or 4-byte addresses - not implemented
read 1512368 bytes from file pcileech_pciescreamer_top.bin and flash bank 0 at offset 0x00000000 in 1.291909s (1143.209 KiB/s)
contents differ
diff 0 address 0x00000085. Was 0x10 instead of 0x30
diff 1 address 0x0000009f. Was 0x01 instead of 0x13
diff 2 address 0x000000a0. Was 0x20 instead of 0x30
diff 3 address 0x000000a2. Was 0x00 instead of 0x80
diff 4 address 0x000000a3. Was 0x00 instead of 0x01
diff 5 address 0x000000a7. Was 0x01 instead of 0x09
diff 6 address 0x000000a8. Was 0x00 instead of 0x20
diff 7 address 0x000000ae. Was 0x80 instead of 0xc0
diff 8 address 0x000000b6. Was 0x80 instead of 0xa0
diff 9 address 0x000000ba. Was 0x00 instead of 0x05
diff 10 address 0x000000bb. Was 0x00 instead of 0x01
diff 11 address 0x000000be. Was 0x00 instead of 0xc0
diff 12 address 0x000000c2. Was 0x00 instead of 0x10
diff 13 address 0x000000c4. Was 0x20 instead of 0x30
diff 14 address 0x000000c5. Was 0x00 instead of 0x03
diff 15 address 0x000000c7. Was 0x00 instead of 0x01
diff 16 address 0x000000ca. Was 0x00 instead of 0x10
diff 17 address 0x000000e8. Was 0x00 instead of 0x20
diff 18 address 0x000000ee. Was 0x00 instead of 0x20
diff 19 address 0x000000f4. Was 0x20 instead of 0x30
diff 20 address 0x000000f6. Was 0x00 instead of 0x80
diff 21 address 0x000000f7. Was 0x00 instead of 0x01
diff 22 address 0x000000fb. Was 0x00 instead of 0x01
diff 23 address 0x000000fc. Was 0x00 instead of 0x20
diff 24 address 0x00000100. Was 0x00 instead of 0x30
diff 25 address 0x00000102. Was 0x00 instead of 0x41
diff 26 address 0x00000103. Was 0x00 instead of 0x94
diff 27 address 0x0000011b. Was 0x00 instead of 0x84
diff 28 address 0x00000127. Was 0x00 instead of 0x0a
diff 29 address 0x000001be. Was 0x00 instead of 0x08
diff 30 address 0x000001c3. Was 0x00 instead of 0x88
diff 31 address 0x000001c6. Was 0x00 instead of 0x08
diff 32 address 0x000001cb. Was 0x00 instead of 0x88
diff 33 address 0x000001cf. Was 0x00 instead of 0x47
diff 34 address 0x00000352. Was 0x00 instead of 0x40
diff 35 address 0x00000357. Was 0x00 instead of 0x60
diff 36 address 0x0000035a. Was 0x00 instead of 0x40
diff 37 address 0x0000035f. Was 0x00 instead of 0x60
diff 38 address 0x00000362. Was 0x00 instead of 0x10
diff 39 address 0x00000363. Was 0x00 instead of 0x40
diff 40 address 0x000004f6. Was 0x00 instead of 0x15
diff 41 address 0x000004f7. Was 0x00 instead of 0x7c
diff 42 address 0x00000534. Was 0x00 instead of 0x08
diff 43 address 0x0000054b. Was 0x00 instead of 0x80
diff 44 address 0x0000057b. Was 0x00 instead of 0x40
diff 45 address 0x000005ab. Was 0x00 instead of 0x40
diff 46 address 0x00000754. Was 0x00 instead of 0x30
diff 47 address 0x00000756. Was 0x00 instead of 0x80
diff 48 address 0x00000757. Was 0x00 instead of 0x01
diff 49 address 0x0000075b. Was 0x00 instead of 0x02
diff 50 address 0x0000075c. Was 0x00 instead of 0x20
diff 51 address 0x00000760. Was 0x00 instead of 0x20
diff 52 address 0x00000764. Was 0x00 instead of 0x20
diff 53 address 0x00000768. Was 0x00 instead of 0x20
diff 54 address 0x0000076c. Was 0x00 instead of 0x20
diff 55 address 0x00000770. Was 0x00 instead of 0x20
diff 56 address 0x00000774. Was 0x00 instead of 0x20
diff 57 address 0x00000778. Was 0x00 instead of 0x20
diff 58 address 0x0000077c. Was 0x00 instead of 0x20
diff 59 address 0x00000780. Was 0x00 instead of 0x20
diff 60 address 0x00000784. Was 0x00 instead of 0x20
diff 61 address 0x00000788. Was 0x00 instead of 0x20
diff 62 address 0x0000078c. Was 0x00 instead of 0x30
diff 63 address 0x0000078d. Was 0x00 instead of 0x01
diff 64 address 0x0000078e. Was 0x00 instead of 0x40
diff 65 address 0x0000078f. Was 0x00 instead of 0x08
diff 66 address 0x000007b0. Was 0x00 instead of 0x30
diff 67 address 0x000007b2. Was 0x00 instead of 0x20
diff 68 address 0x000007b3. Was 0x00 instead of 0x01
diff 69 address 0x000007b7. Was 0x00 instead of 0x08
diff 70 address 0x000007b8. Was 0x00 instead of 0x30
diff 71 address 0x000007b9. Was 0x00 instead of 0x01
diff 72 address 0x000007ba. Was 0x00 instead of 0x40
diff 73 address 0x000007bb. Was 0x00 instead of 0x04
diff 74 address 0x000007cc. Was 0x00 instead of 0x30
diff 75 address 0x000007ce. Was 0x00 instead of 0x20
diff 76 address 0x000007cf. Was 0x00 instead of 0x01
diff 77 address 0x000007d3. Was 0x00 instead of 0x0a
diff 78 address 0x000007d4. Was 0x00 instead of 0x30
diff 79 address 0x000007d5. Was 0x00 instead of 0x01
diff 80 address 0x000007d6. Was 0x00 instead of 0x40
diff 81 address 0x000007d7. Was 0x00 instead of 0x04
diff 82 address 0x000007e8. Was 0x00 instead of 0x30
diff 83 address 0x000007ea. Was 0x00 instead of 0x20
diff 84 address 0x000007eb. Was 0x00 instead of 0x01
diff 85 address 0x000007ef. Was 0x00 instead of 0x14
diff 86 address 0x000007f0. Was 0x00 instead of 0x30
diff 87 address 0x000007f1. Was 0x00 instead of 0x01
diff 88 address 0x000007f2. Was 0x00 instead of 0x40
diff 89 address 0x000007f3. Was 0x00 instead of 0x04
diff 90 address 0x00000804. Was 0x00 instead of 0x30
diff 91 address 0x00000806. Was 0x00 instead of 0x20
diff 92 address 0x00000807. Was 0x00 instead of 0x01
diff 93 address 0x0000080b. Was 0x00 instead of 0x1a
diff 94 address 0x0000080c. Was 0x00 instead of 0x30
diff 95 address 0x0000080d. Was 0x00 instead of 0x01
diff 96 address 0x0000080e. Was 0x00 instead of 0x40
diff 97 address 0x0000080f. Was 0x00 instead of 0x04
diff 98 address 0x00000820. Was 0x00 instead of 0x30
diff 99 address 0x00000822. Was 0x00 instead of 0x20
diff 100 address 0x00000823. Was 0x00 instead of 0x01
diff 101 address 0x00000827. Was 0x00 instead of 0x1b
diff 102 address 0x00000828. Was 0x00 instead of 0x30
diff 103 address 0x00000829. Was 0x00 instead of 0x01
diff 104 address 0x0000082a. Was 0x00 instead of 0x40
diff 105 address 0x0000082b. Was 0x00 instead of 0x04
diff 106 address 0x0000083c. Was 0x00 instead of 0x30
diff 107 address 0x0000083e. Was 0x00 instead of 0x20
diff 108 address 0x0000083f. Was 0x00 instead of 0x01
diff 109 address 0x00000843. Was 0x00 instead of 0x22
diff 110 address 0x00000844. Was 0x00 instead of 0x30
diff 111 address 0x00000845. Was 0x00 instead of 0x01
diff 112 address 0x00000846. Was 0x00 instead of 0x40
diff 113 address 0x00000847. Was 0x00 instead of 0x04
diff 114 address 0x00000858. Was 0x00 instead of 0x30
diff 115 address 0x0000085a. Was 0x00 instead of 0x20
diff 116 address 0x0000085b. Was 0x00 instead of 0x01
diff 117 address 0x0000085f. Was 0x00 instead of 0x23
diff 118 address 0x00000860. Was 0x00 instead of 0x30
diff 119 address 0x00000861. Was 0x00 instead of 0x01
diff 120 address 0x00000862. Was 0x00 instead of 0x40
diff 121 address 0x00000863. Was 0x00 instead of 0x04
diff 122 address 0x00000874. Was 0x00 instead of 0x30
diff 123 address 0x00000876. Was 0x00 instead of 0x20
diff 124 address 0x00000877. Was 0x00 instead of 0x01
diff 125 address 0x0000087b. Was 0x00 instead of 0x24
diff 126 address 0x0000087c. Was 0x00 instead of 0x30
diff 127 address 0x0000087d. Was 0x00 instead of 0x01
More than 128 errors, the rest are not printed

Does this mean that the device is not properly flashed with the pcileech bitstream? When I tried to run a pcileech probe command, an error occurs to state that there is no device found. Is this due to the warning in which the card has not implemented paging?

For now, it only seems that LD3 is lit up, and pressing SW3 has no effect.

LD2, which indicates PCIe link activity is not lit up. Is the flashing unsuccessful because of this? I've checked using lspci with linux and the device manager but am unable to see a Xilinx ethernet adapter (according to other issues posted).

Edit: I've tried reseating the pciescreamer card into other x1 slots and another x16 slot. Still no sign of LD2. I've also tried to update my BIOS to the latest version but still the issue occurs. I've checked the power pins to make sure it's configured to PCIe and the SW2 switches are on, off, off. Virtualization features are also disabled in the BIOS.

from pcileech-fpga.

CuriosoCat avatar CuriosoCat commented on May 18, 2024

Just an update, I managed to flash the card but i'm still unable to read the memory of the machine.

The updated lambdaconcept instructions at http://blog.lambdaconcept.com/doku.php?id=products:jtagserial_programmer#spi_flash_programming have shown that you can apply a git patch to resolve the contents differ problem. This might be useful for anyone facing this problem. I still faced errors erasing the flash and I only managed to flash it with the Xilinx programming cable.

I'm now facing a similar issue to the errors shown at https://github.com/ufrisk/pcileech-fpga/issues/4 https://github.com/ufrisk/pcileech/issues/31.

From the card, LD2 and LD3 are lit up when powered on. LD1 lights up when I press SW3 too.

The result of a pcileech probe:
pcileech.exe probe

Memory Map:
START END #PAGES
(No memory successfully read yet)

Current Action: Probing Memory
Access Mode: DMA (hardware only)
Progress: 7744 / (unknown)
Speed: 430 MB/s
Address: 0x00000001E3FFF000
Pages read: 0
Pages failed: 1982464

The result of a pcileech dump:
C:\PCILeech\pcileech-master\pcileech_files>pcileech dump -v

FPGA: Device Info: SP605 / FT601 PCIe gen1 x1 [400,175,500] [v0.0,0300]
Memory Map:
START END #PAGES
(No memory successfully read yet)

Current Action: Dumping Memory
Access Mode: DMA (hardware only)
Progress: 16 / (unknown)
Speed: 16 MB/s
Address: 0x0000000001000000
Pages read: 0
Pages failed: 4096
Memory Dump: Failed. Cannot dump any sequential data in 16MB - terminating.

Other results:
C:\PCILeech\pcileech-master\pcileech_files>pcileech.exe display -vv -pcie_gen1

Memory Display: Failed reading memory at address: 0x0000000000000000.

Another result
C:\PCILeech\pcileech-master\pcileech_files>pcileech.exe display -min 0x1000 -v

FPGA: Device Info: SP605 / FT601 PCIe gen1 x1 [400,175,500] [v0.0,0300]
Memory Display: Failed reading memory at address: 0x0000000000001000.

Any ideas what is wrong and how do i fix it?

I've tried verifying the flash contents using Vivado. l've ensured that anything inhibiting DMA is not on e.g. virtualization and SGX?.

Also: The LEDs are not reliably lighting up and I need to power cycle and press SW1 at times to see if LD3 lights up and if LD2 lights up when booting up.

from pcileech-fpga.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.