E-ISSN: 2587-0351 | ISSN: 1300-2694
FPGA Prototyping: On-chip Debug Module for RISC-V Based SoC and Testing Processes Using Raspberry Pi with OpenOCD over JTAG [Pamukkale Univ Muh Bilim Derg]
Pamukkale Univ Muh Bilim Derg. Ahead of Print: PAJES-95694 | DOI: 10.5505/pajes.2025.95694

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

Sezen Bal1, Hayriye Korkmaz2, Doğukan Biçer3, Celal Alperen Bayar2, Eren Kale2, Eray Kayailli2, Armağan Bi2
1Marmara University, Vocational School Of Technical Sciences, Department Of Computer Technologies, Istanbul
2Marmara University, Faculty Of Technology, Department Of Electrical And Electronics Engineering, Istanbul
3Marmara University, Institute Of Science And Technology, Department Of Electrical And Electronics Engineering, Istanbul

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.

Keywords: RISC-V Processor, FPGA, Debug, System on Chip

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

Sezen Bal1, Hayriye Korkmaz2, Doğukan Biçer3, Celal Alperen Bayar2, Eren Kale2, Eray Kayailli2, Armağan Bi2
1Marmara Üniversitesi, Teknik Bilimler Meslek Yüksekokulu, Bilgisayar Teknolojileri Bölümü, İstanbul
2Marmara Üniversitesi, Teknoloji Fakültesi, Elektrik-Elektronik Mühendisliği Bölümü, İstanbul
3Marmara Üniversitesi, Fen Bilimleri Enstitüsü, Elektrik-Elektronik Mühendisliği Bölümü, İstanbul

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.

Anahtar Kelimeler: RISC-V İşlemci, FPGA, Hata Ayıklama, Çip üstü Sistem

Corresponding Author: Sezen Bal, Türkiye
Manuscript Language: Turkish
×
APA
MLA
Chicago
Copied!
CITE
LookUs & Online Makale