Hi,
I'm having trouble when reading some objects in List. Server is based on gxsimulator.
All attributes can be read alone, but when in list, I got:
class [B cannot be cast to class java.lang.Number ([B and java.lang.Number are in module java.base of loader 'bootstrap')
gurux.dlms.objects.GXDLMSDemandRegister.setValue(GXDLMSDemandRegister.java:578)
gurux.dlms.GXDLMSClient.updateValues(GXDLMSClient.java:1510)
cz.vutbr.client.reader.MyReader.readMyList(MyReader.java:839)
I know, that some values are null in this object, but when every attribute alone works just fine, list should work too.
I noticed that in some other cases, but always the object on server had some values as null.
When dubbugging, i found a value for index 9 (on line 578 in demandregister). EventValue was [7, -28, 12, 6, 7, 21, 56, 8, -1, -1, -60, 0], but for this, there should be only one number.
I have this object:
<GXDLMSDemandRegister>
<LN>1.5.32.27.0.255</LN>
<Access>111133333</Access>
<MethodAccess>00</MethodAccess>
<CurrentAverageValue Type="18">0</CurrentAverageValue>
<LastAverageValue></LastAverageValue>
<Scaler>1.000000</Scaler>
<Unit>0</Unit>
<Status Type="17">0</Status>
<CaptureTime>12/06/2020 21:56:08+01:00</CaptureTime>
<StartTimeCurrent>12/06/2020 21:56:08+01:00</StartTimeCurrent>
<Period>0</Period>
<NumberOfPeriods>0</NumberOfPeriods>
</GXDLMSDemandRegister>
I guess best solution is to make better xml for server with all values specified...
Demand register attribute #9 should be UInt16 and the value that you have tried to update is wrong.
Check your code. I believe that you will found the reason from there.
Hi,
can you check list data in this file (log from our client)? https://pastebin.com/qGNsa0r0
It contains association, then reading object one attribute at the time and after that, there is list read with parsing error.
I'm not doing anything to the data. Parsing part is vanilla gurux :)
Hi,
Hi,
Demand register attribute #9 should be UInt16 and the value that you have tried to update is wrong.
Check your code. I believe that you will found the reason from there.
BR,
Mikko
Hi,
Hi,
can you check list data in this file (log from our client)? https://pastebin.com/qGNsa0r0
It contains association, then reading object one attribute at the time and after that, there is list read with parsing error.
I'm not doing anything to the data. Parsing part is vanilla gurux :)