On Wednesday, March 21, 2012 1:18:55 AM UTC+2, Alan Fitch wrote:
> On 20/03/12 17:41, Kleric wrote:
> > On Monday, March 19, 2012 2:04:26 AM UTC+2, Alan Fitch wrote:
> >> On 17/03/12 14:51, Kleric wrote:
> >>> On Saturday, March 17, 2012 1:32:52 PM UTC+2, Alan Fitch wrote:
> >>>> On 17/03/12 10:27, Kleric wrote:
> >>>>> On Saturday, March 17, 2012 9:16:47 AM UTC+2, Bart Fox wrote:
> >>>>>> Am 16.03.12 15:45, schrieb Kleric:
> >>>>>>> When I replace this line with this:
> >>>>>>> wait on clock until clock = '1';
> >>>>>>> It compiles.
> >>>>>>> But it doesn't work, my graph stays the same all time.
> >>>>>> Your clock is not the problem (but I also prefer the rising_edge function).
> >>>>>> Your problem is: You have no point in your code, where current_state is
> >>>>>> updated with next_state.
> >>>>>>
> >>>>>> You have a synchronous process. I would suggest to use only one "state"
> >>>>>> signal:
> >>>>>>
> >>>>
> >>>> <snip>
>
> > Hi, thank you for the help.
> >
> > http://www.box.com/s/129cbfc83b936f275292
> >
> > What could the problem be, it still doesn't get anywhere in the graph.
> >
> > You talked about this
> > "1 0 0 8 4 8 6 9
> > That number represents the bit position in the 10 bit input vector that
> > is set (IMPORTANT!)"
> >
> > Is there something wrong with my represantion?
> > if input = "0000000001" then
> > state <= 2;
>
>
> Yes, I think there is.
>
> 1 means bit position 1, 2 means bit position 2 and so on up to 9 meaning
> it position 9. For instance:
>
> 9876543210 <-- bit position 1
> "0000000010"
>
> Similarly, 6 means
> "0001000000" <-- bit position 6
>
> You seem to be coding the value in binary, which of course only uses the
> bottom four bits of the 10 bit input vector.
>
> That's why I think 10084869 should be represented as
>
> 0000000010 <--1
> 0000000000 <-- button released
> 0000000001 0
> 0000000000 button released
> 0000000001
> 0000000000
> 0100000000
> 0000000000
> 0000010000
> 0000000000
> 0100000000
> 0000000000
> 0001000000
> 0000000000
> 1000000000
>
> regards
> Alan
>
>
> --
> Alan Fitch
Oh, I get it. They are positions.
Updated
http://www.box.com/s/129cbfc83b936f275292
The graph still doesn't show anything.
Maybe someone could just fix it. I can't figure it out.
I can't change the testbench.
I have used reset, clock, output, input.
Can't find where am I mistaken.