Re: [myhdl-list] Conversion of Signal(intbv(False))
Brought to you by:
jandecaluwe
From: Felton C. <chr...@gm...> - 2009-01-18 03:53:44
|
>> >> >> This can be worked around by adding bit width, Signal(intbv(False) >> [1:]). But if this is done the code (or at least the example below) >> doesn't work, because the intbv type insn't a bool anymore. Once the >> bit width is added it becomes an integer and the conditions will fail >> for a non-bool type. > > What exactly doesn't work about that? Conversion seems to work fine, > and I don't immediately see what would be wrong with the Verilog or > VHDL > code. > > Also, before going into the depth of the matter, what's against > simply using Signal(False) for the boolean signals? > Sorry this is my error, I was thinking only type intbv was convertible and didn't cross my mind to use Signal(bool). Quick look through the manual and some past work didn't remind my brain. You are absolutely correct, in my case I should be using Signal(bool) and the intbv(bool) that I posted about is not relevant. Thanks for the help as always! |