Research Article
BibTex RIS Cite

FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri

Year 2025, Volume: 31 Issue: 7

Abstract

Bu çalışma, RISC-V tabanlı bir System-on-Chip (SoC) tasarımının FPGA üzerinde prototipleme sürecini ve bu süreçte entegre edilen çip üstü hata ayıklama modülünü ele almaktadır. FPGA prototipleme, sayısal tasarımların donanım seviyesinde değerlendirilmesi amacıyla FPGA üzerinde uygulanması ve test edilmesi sürecidir. Çalışmada, Raspberry Pi ve OpenOCD kullanılarak JTAG aracılığıyla gerçekleştirilen hata ayıklama işlemleri, SoC'nin çeşitli fonksiyonlarını ve performansını etkin bir şekilde test etmek için kritik bir adım olarak vurgulanmaktadır. Bu yaklaşım, geliştirme sürecinde maliyetleri düşürmeye ve pazara sunma süresini kısaltmaya katkıda bulunurken, tasarımın son silikon versiyonuna geçişte karşılaşılacak riskleri azaltmaktadır. SoC tasarımı, FPGA üzerinde çalıştırılarak fonksiyonel doğrulama kapsamında çeşitli testlere tabi tutulmuş ve başarılı sonuçlar elde edilmiştir. Fonksiyonel doğrulama, bir sayısal tasarımın beklenen davranışları sergileyip sergilemediğini kontrol etmek için uygulanan kritik bir test aşamasıdır. Kayan nokta birimi testi kapsamında sinüs fonksiyonu uygulanarak sinüs değerleri hesaplanmış ve birimin doğru çalıştığı doğrulanmıştır. I2C çevre birimi testinde, bir sensör bağlanarak sensörden elde edilen verilerin doğru şekilde alındığı ve işlendiği tespit edilmiştir. Bit manipulation testi, RISC-V bit manipülasyon komutlarının doğru çalıştığını göstermiştir. FreeRTOS uygulamasında, görev zamanlaması, kesmeler ve kaynak yönetimi başarıyla gerçekleştirilmiş ve sistemin çoklu görev yürütme sırasında hatasız çalıştığı doğrulanmıştır. Atomik işlemler ile CSR (Control and Status Registers) birimlerinin doğru işleyişi değerlendirilmiş ve beklendiği gibi çalıştığı doğrulanmıştır. Bunun yanı sıra, işlemcinin performansı CoreMark ve Dhrystone kıyaslamaları kullanılarak değerlendirilmiştir. CoreMark testinde işlemci, 41,97 iterasyon/saniye (600 iterasyon) skoruna ulaşmış ve CoreMark/MHz değeri 2,51 olarak hesaplanmıştır. Dhrystone kıyaslamasında ise işlemci, 70,582 Dhrystone/saniye performans sergilemiştir. Her bir bileşenin implementasyonu ve ilgili test tezgahları Verilog HDL ile yazılmış olup, tasarım Terasic De10-Lite FPGA üzerinde uygulanmıştır.

References

  • [1] Farooq U, Mehrez H. "Pre-Silicon Verification Using MultiFPGA Platforms: A Review". Journal of Electron Testing, 37(1), 7-24, 2021.
  • [2] Korkmaz N. "Fitzhugh-Nagumo nöron modelinin rotasyon-geçiş prosedürü ve donanım doğrulaması". Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi, 24(3), 316-323, 2024.
  • [3] Zang Z, Liu Y, Cheung RCC. "Reconfigurable RISC-V Secure Processor And SoC Integration". 2019 IEEE International Conference on Industrial Technology (ICIT), Melbourne, Australia, 13 - 15 February 2019.
  • [4] University of California, Berkeley. “RISC-V Project.” [Online]. Available: https://riscv.org/about/history/ (07.01.2024).
  • [5] Cui, Enfang & Li, Tianzheng & Wei, Qian. RISC-V Instruction Set Architecture Extensions: A Survey. IEEE Access, 2023. PP. 1-1. 10.1109/ACCESS.2023.3246491.
  • [6] RISC-V ISA Manual. Erişim adresi https://github.com/riscv/riscv-isa-manual (Erişim tarihi: 12.01.2025)
  • [7] E. Cui, T. Li and Q. Wei, "RISC-V Instruction Set Architecture Extensions: A Survey," in IEEE Access, vol. 11, pp. 24696-24711, 2023, doi: 10.1109/ACCESS.2023.3246491.
  • [8] X. Wang et al., "xBGAS: A Global Address Space Extension on RISC-V for High Performance Computing," 2021 IEEE International Parallel and Distributed Processing Symposium (IPDPS), Portland, OR, USA, 2021, pp. 454-463, doi: 10.1109/IPDPS49936.2021.00054.
  • [9] J. Chen, D. Li, Z. Mi, Y. Liu, B. Zang, H. Guan, and H. Chen, “Du-visor: a user-level hypervisor through delegated virtualization,” 2022, arXiv:2201.09652.
  • [10] Elsabbagh, Fares & Tine, Blaise & Roshan, Priyadarshini & Lyons, Ethan & Kim, Euna & Shim, Da Eun & Zhu, Lingjun & Lim, Sung & kim, Hyesoon. “Vortex: OpenCL Compatible RISC-V GPGPU”. 2020, 10.48550/arXiv.2002.12151.
  • [11] RISC-V International. “RISC-V Debug Specification”. https://riscv.org/wp-content/uploads/2019/03/riscv-debug-release.pdf (07.01.2024)
  • [12] Poli L., Saha S., Zhai X., Mcdonald-Maier K.D. "Design and Implementation of a RISC V Processor on FPGA". 2021 17th International Conference on Mobility, Sensing and Networking (MSN), Exeter, United Kingdom, 13-15 December 2021.
  • [13] Pilavendiran SA, Keshavarajan JL, Vijayakumar S. "Design and Development of JTAG Using Raspberry Pi". International Journal of Engineering Applied Sciences and Technology, 4, 75-79, 2020.
  • [14] Rico-García P, Yañez-Vargas JI, Parra-Michel R, Conde-Almada E. “Debugging and programming a RISC-V processor, using the IEEE 1149.1 standard”. Journal Applied Computing, 7(21), 1-9, 2023
  • [15] Salehi M, Degani L, Roveri M, Hughes D, Crispo B. "Discovery and Identification of Memory Corruption Vulnerabilities on Bare-Metal Embedded Devices". IEEE Transactions on Dependable and Secure Computing, pp(99):1-1, 2022.
  • [16] OpenOCD. ”Open On-Chip Debugger”. https://openocd.org/doc/pdf/openocd.pdf (20.01.2024)
  • [17] Gao S, Wu D, Xiao W, Wang Z, Yang Z, Gao W. "A novel method for on-chip debugging based on RISC-V processor". MATEC Web of Conferences, Xiamen, China, 29-30 December, 2021.
  • [18] Toker O. "A High-Level Synthesis Approach for a RISC-V RV32I-Based System on Chip and Its FPGA Implementation". 10th International Electronic Conference on Sensors and Applications, Online, 15-30 November, 2023.
  • [19] Heinz C, Lavan Y, Hofmann J, Koch A. "A Catalog and In-Hardware Evaluation of Open-Source Drop-In Compatible RISC-V Softcore Processors". 2019 International Conference on ReConFigurable Computing and FPGAs, Cancun, Mexico, 9-11 December, 2019.
  • [20] Elsadek I, Tawfik EY. "RISC-V Resource-Constrained Cores: A Survey and Energy Comparison". 19th IEEE International New Circuits and Systems Conference, Toulon, France, 13-16 June, 2021.
  • [21] EEMBC (Embedded Microprocessor Benchmark Consortium). CoreMark Benchmark. Erişim adresi: www.eembc.org (Erişim tarihi: 15.01.2025).
  • [22] Kreier, R. CoreMark Benchmarking Overview. Erişim adresi: https://kreier.github.io/benchmark/CoreMark/ (Erişim tarihi: 15.03.2025).
  • [23] R. Weicker, "Dhrystone: A Synthetic Benchmark," Communications of the ACM, vol. 27, no. 10, pp. 1013-1030, Oct. 1984.
  • [24] Mo, W., Liu, J., Wang, Y., Yan, F., Xiong, B., & Guan, J. An SDPF RISC-V Processor With 55.9% Dhrystone Improvement Using Two-Stage Pseudo-Pipelined Architecture for IoT Applications. International Journal of Circuit Theory and Applications 2025. https://doi.org/10.1002/cta.4514
  • [25] S. Bora and R. Paily, "A High-Performance Core Micro-Architecture Based on RISC-V ISA for Low Power Applications," in IEEE Transactions on Circuits and Systems II: Express Briefs, vol. 68, no. 6, pp. 2132-2136, June 2021, doi: 10.1109/TCSII.2020.3043204.
  • [26] ORCA: A RISC-V Processor for FPGA Evaluation. GitHub Repository. Erişim adresi: https://github.com/riscveval/orca-1 (Erişim tarihi: 15.03.2025).
  • [27] PicoRV32: A Size-Optimized RISC-V CPU Core. GitHub Repository. Erişim adresi: https://github.com/YosysHQ/picorv32 (Erişim tarihi: 15.03.2025).
  • [28] mmRISC-1: A Minimal RISC-V CPU Implementation. GitHub Repository. Erişim adresi: https://github.com/munetomo-maruyama/mmRISC-1 (Erişim tarihi: 01.01.2024).

FPGA Prototyping: On-chip Debug Module for RISC-V Based SoC and Testing Processes Using Raspberry Pi with OpenOCD over JTAG

Year 2025, Volume: 31 Issue: 7

Abstract

This paper presents the FPGA prototyping process of a RISC-V based System-on-Chip (SoC) design and the on-chip debug module integrated in this process. FPGA prototyping is the process of implementing and testing digital designs on an FPGA for hardware-level evaluation. In the study, debugging operations performed via JTAG using Raspberry Pi and OpenOCD are highlighted as a critical step to effectively test the various functions and performance of the SoC. This approach contributes to reduce costs in the development process and shorten time-to-market, while reducing the risks involved in the transition to the final silicon version of the design. The SoC design was executed on FPGA and subjected to various tests within the scope of functional verification and successful results were obtained. Functional verification is a critical testing phase to check whether a digital design exhibits the expected behavior. Within the scope of the floating point unit test, sine values were calculated by applying the sine function and the correct operation of the unit was verified. In the I2C peripheral test, a sensor was connected and it was determined that the data obtained from the sensor was received and processed correctly. The bit manipulation test showed that the RISC-V bit manipulation instructions worked correctly. In the FreeRTOS implementation, task scheduling, interrupts, and resource management were successfully implemented, and the system was verified to be error-free during multitasking. The correct operation of atomic operations and CSR (Control and Status Registers) was evaluated and verified to work as expected. In addition, the performance of the processor was evaluated using CoreMark and Dhrystone benchmarks. In the CoreMark test, the processor achieved a score of 41.97 iterations/second (600 iterations) and the CoreMark/MHz value was calculated as 2.51. In the Dhrystone benchmark, the processor performed 70.582 Dhrystones/second. The implementation of each component and the corresponding testbenches were wri tten in Verilog HDL and the design was implemented on a Terasic De10-Lite FPGA.

References

  • [1] Farooq U, Mehrez H. "Pre-Silicon Verification Using MultiFPGA Platforms: A Review". Journal of Electron Testing, 37(1), 7-24, 2021.
  • [2] Korkmaz N. "Fitzhugh-Nagumo nöron modelinin rotasyon-geçiş prosedürü ve donanım doğrulaması". Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi, 24(3), 316-323, 2024.
  • [3] Zang Z, Liu Y, Cheung RCC. "Reconfigurable RISC-V Secure Processor And SoC Integration". 2019 IEEE International Conference on Industrial Technology (ICIT), Melbourne, Australia, 13 - 15 February 2019.
  • [4] University of California, Berkeley. “RISC-V Project.” [Online]. Available: https://riscv.org/about/history/ (07.01.2024).
  • [5] Cui, Enfang & Li, Tianzheng & Wei, Qian. RISC-V Instruction Set Architecture Extensions: A Survey. IEEE Access, 2023. PP. 1-1. 10.1109/ACCESS.2023.3246491.
  • [6] RISC-V ISA Manual. Erişim adresi https://github.com/riscv/riscv-isa-manual (Erişim tarihi: 12.01.2025)
  • [7] E. Cui, T. Li and Q. Wei, "RISC-V Instruction Set Architecture Extensions: A Survey," in IEEE Access, vol. 11, pp. 24696-24711, 2023, doi: 10.1109/ACCESS.2023.3246491.
  • [8] X. Wang et al., "xBGAS: A Global Address Space Extension on RISC-V for High Performance Computing," 2021 IEEE International Parallel and Distributed Processing Symposium (IPDPS), Portland, OR, USA, 2021, pp. 454-463, doi: 10.1109/IPDPS49936.2021.00054.
  • [9] J. Chen, D. Li, Z. Mi, Y. Liu, B. Zang, H. Guan, and H. Chen, “Du-visor: a user-level hypervisor through delegated virtualization,” 2022, arXiv:2201.09652.
  • [10] Elsabbagh, Fares & Tine, Blaise & Roshan, Priyadarshini & Lyons, Ethan & Kim, Euna & Shim, Da Eun & Zhu, Lingjun & Lim, Sung & kim, Hyesoon. “Vortex: OpenCL Compatible RISC-V GPGPU”. 2020, 10.48550/arXiv.2002.12151.
  • [11] RISC-V International. “RISC-V Debug Specification”. https://riscv.org/wp-content/uploads/2019/03/riscv-debug-release.pdf (07.01.2024)
  • [12] Poli L., Saha S., Zhai X., Mcdonald-Maier K.D. "Design and Implementation of a RISC V Processor on FPGA". 2021 17th International Conference on Mobility, Sensing and Networking (MSN), Exeter, United Kingdom, 13-15 December 2021.
  • [13] Pilavendiran SA, Keshavarajan JL, Vijayakumar S. "Design and Development of JTAG Using Raspberry Pi". International Journal of Engineering Applied Sciences and Technology, 4, 75-79, 2020.
  • [14] Rico-García P, Yañez-Vargas JI, Parra-Michel R, Conde-Almada E. “Debugging and programming a RISC-V processor, using the IEEE 1149.1 standard”. Journal Applied Computing, 7(21), 1-9, 2023
  • [15] Salehi M, Degani L, Roveri M, Hughes D, Crispo B. "Discovery and Identification of Memory Corruption Vulnerabilities on Bare-Metal Embedded Devices". IEEE Transactions on Dependable and Secure Computing, pp(99):1-1, 2022.
  • [16] OpenOCD. ”Open On-Chip Debugger”. https://openocd.org/doc/pdf/openocd.pdf (20.01.2024)
  • [17] Gao S, Wu D, Xiao W, Wang Z, Yang Z, Gao W. "A novel method for on-chip debugging based on RISC-V processor". MATEC Web of Conferences, Xiamen, China, 29-30 December, 2021.
  • [18] Toker O. "A High-Level Synthesis Approach for a RISC-V RV32I-Based System on Chip and Its FPGA Implementation". 10th International Electronic Conference on Sensors and Applications, Online, 15-30 November, 2023.
  • [19] Heinz C, Lavan Y, Hofmann J, Koch A. "A Catalog and In-Hardware Evaluation of Open-Source Drop-In Compatible RISC-V Softcore Processors". 2019 International Conference on ReConFigurable Computing and FPGAs, Cancun, Mexico, 9-11 December, 2019.
  • [20] Elsadek I, Tawfik EY. "RISC-V Resource-Constrained Cores: A Survey and Energy Comparison". 19th IEEE International New Circuits and Systems Conference, Toulon, France, 13-16 June, 2021.
  • [21] EEMBC (Embedded Microprocessor Benchmark Consortium). CoreMark Benchmark. Erişim adresi: www.eembc.org (Erişim tarihi: 15.01.2025).
  • [22] Kreier, R. CoreMark Benchmarking Overview. Erişim adresi: https://kreier.github.io/benchmark/CoreMark/ (Erişim tarihi: 15.03.2025).
  • [23] R. Weicker, "Dhrystone: A Synthetic Benchmark," Communications of the ACM, vol. 27, no. 10, pp. 1013-1030, Oct. 1984.
  • [24] Mo, W., Liu, J., Wang, Y., Yan, F., Xiong, B., & Guan, J. An SDPF RISC-V Processor With 55.9% Dhrystone Improvement Using Two-Stage Pseudo-Pipelined Architecture for IoT Applications. International Journal of Circuit Theory and Applications 2025. https://doi.org/10.1002/cta.4514
  • [25] S. Bora and R. Paily, "A High-Performance Core Micro-Architecture Based on RISC-V ISA for Low Power Applications," in IEEE Transactions on Circuits and Systems II: Express Briefs, vol. 68, no. 6, pp. 2132-2136, June 2021, doi: 10.1109/TCSII.2020.3043204.
  • [26] ORCA: A RISC-V Processor for FPGA Evaluation. GitHub Repository. Erişim adresi: https://github.com/riscveval/orca-1 (Erişim tarihi: 15.03.2025).
  • [27] PicoRV32: A Size-Optimized RISC-V CPU Core. GitHub Repository. Erişim adresi: https://github.com/YosysHQ/picorv32 (Erişim tarihi: 15.03.2025).
  • [28] mmRISC-1: A Minimal RISC-V CPU Implementation. GitHub Repository. Erişim adresi: https://github.com/munetomo-maruyama/mmRISC-1 (Erişim tarihi: 01.01.2024).
There are 28 citations in total.

Details

Primary Language Turkish
Subjects Electrical Engineering (Other)
Journal Section Research Article
Authors

Sezen Bal

Hayriye Korkmaz

Doğukan Biçer

Eren Kale

Eray Kayailli This is me

Armağan Bi

Early Pub Date November 2, 2025
Publication Date November 19, 2025
Submission Date December 6, 2024
Acceptance Date May 2, 2025
Published in Issue Year 2025 Volume: 31 Issue: 7

Cite

APA Bal, S., Korkmaz, H., Biçer, D., … Kale, E. (2025). FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi, 31(7). https://doi.org/10.5505/pajes.2025.95694
AMA Bal S, Korkmaz H, Biçer D, Kale E, Kayailli E, Bi A. FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi. November 2025;31(7). doi:10.5505/pajes.2025.95694
Chicago Bal, Sezen, Hayriye Korkmaz, Doğukan Biçer, Eren Kale, Eray Kayailli, and Armağan Bi. “FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü Ve Raspberry Pi Ile OpenOCD JTAG Üzerinden Test Süreçleri”. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi 31, no. 7 (November 2025). https://doi.org/10.5505/pajes.2025.95694.
EndNote Bal S, Korkmaz H, Biçer D, Kale E, Kayailli E, Bi A (November 1, 2025) FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi 31 7
IEEE S. Bal, H. Korkmaz, D. Biçer, E. Kale, E. Kayailli, and A. Bi, “FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri”, Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi, vol. 31, no. 7, 2025, doi: 10.5505/pajes.2025.95694.
ISNAD Bal, Sezen et al. “FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü Ve Raspberry Pi Ile OpenOCD JTAG Üzerinden Test Süreçleri”. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi 31/7 (November2025). https://doi.org/10.5505/pajes.2025.95694.
JAMA Bal S, Korkmaz H, Biçer D, Kale E, Kayailli E, Bi A. FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi. 2025;31. doi:10.5505/pajes.2025.95694.
MLA Bal, Sezen et al. “FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü Ve Raspberry Pi Ile OpenOCD JTAG Üzerinden Test Süreçleri”. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi, vol. 31, no. 7, 2025, doi:10.5505/pajes.2025.95694.
Vancouver Bal S, Korkmaz H, Biçer D, Kale E, Kayailli E, Bi A. FPGA Prototipleme: RISC-V Tabanlı SoC İçin Çip Üstü Hata Ayıklama Modülü ve Raspberry Pi ile OpenOCD JTAG Üzerinden Test Süreçleri. Pamukkale Üniversitesi Mühendislik Bilimleri Dergisi. 2025;31(7).

ESCI_LOGO.png    image001.gif    image002.gif        image003.gif     image004.gif