rameloni / tywaves-chisel-demo

A repository that implements Tywaves: enabling a type-based waveform debugging for Chisel and Tydi-Chisel. Mapping from Chisel level code to values dumped by simulators is now possible thanks to Tywaves!
Apache License 2.0
16 stars 0 forks source link

Unable to include any parts of tywaves #27

Closed HakamAtassi closed 1 week ago

HakamAtassi commented 1 week ago

I have been able to install and include tywaves into my project using "com.github.rameloni" %% "tywaves-chisel-api" % "0.3.0-SNAPSHOT",

but trying to include

import tywaves.simulator._
import tywaves.simulator.ParametricSimulator._
import tywaves.simulator.simulatorSettings._

has been largely unsuccessful. SBT claims that there is no "simulator" member in tywaves.

rameloni commented 1 week ago

I checked it, it happens when chisel3._ is imported before anything of tywaves. It happens because of a conflict with the package names of the backend. I'll fix it and push an update in a few days. It is something that shouldn't occur.

For now, I'd recommend moving the import of tywaves before any others. Let me know if this fixes your error.

rameloni commented 1 week ago

Import sequence causing error.

import chisel._

import tywaves.simulator._
import tywaves.simulator.ParametricSimulator._
import tywaves.simulator.simulatorSettings._

Temporary fix revert order.

import tywaves.simulator._ 
import tywaves.simulator.ParametricSimulator._
import tywaves.simulator.simulatorSettings._ 

import chisel3._
HakamAtassi commented 1 week ago

Ah yeah that seemed to fix the issue. Glad it was an easy fix. Thanks for the response.

rameloni commented 1 week ago

Issue reopened since the error shouldn't happen. Even though it has an easy fix, the user should be able to import chisel and tywaves packages in any order and without any confusion.

The issue will be closed once the package name in chisel3 will be changed and the respective sbt dependency updated.