Hi Guillaume,
The problem is that the way thin step is drawn, it does the vertical first, and then the horizontal. So, you would expect to get (0,5) (0,2) (1,2) as your drawn points. To get (0,5) (1,5) (1,2), add an extra value to the front of your array that is a copy of the first value and increment your array size by 1:
Categ = {5,5,2,1}
PlotWaveform (Pnl, PNL_GRAPH, Categ, 4, VAL_UNSIGNED_INTEGER,
1, 0, 0, 1,
VAL_THIN_STEP, VAL_NO_POINT, VAL_SOLID, 1, VAL_BLACK)
Then, you should see that it will go in the order of points that you would normally expect in a histogram. The reason is that from point 0 to point 1 (5 to 5), you show that there is no vertical movement, and so it will go across (0,5) to (1,5). Then from point 1 to point
2 (5 to 2), it will go down from (1,5) to (1,2), then across to (2,2), etc. Hope this helps!
Jeremy L.
National Instruments
Jeremy L.
National Instruments