|
|
@@ -78,10 +78,10 @@ namespace VehicleControlSystem.ControlLayer.MQ
|
|
|
public int CurrentPointNo
|
|
|
{
|
|
|
get { return currentPointNo; }
|
|
|
- set
|
|
|
+ set
|
|
|
{
|
|
|
if ( SetField( ref this.currentPointNo, value ) )
|
|
|
- pub.SendMoreFrame( "CurrentPoint" ).SendFrame( value.ToString() );
|
|
|
+ pub.SendMoreFrame( "CurrentPoint" ).SendFrame( value.ToString() );
|
|
|
}
|
|
|
}
|
|
|
|
|
|
@@ -194,8 +194,7 @@ namespace VehicleControlSystem.ControlLayer.MQ
|
|
|
switch ( kind )
|
|
|
{
|
|
|
case eDataKind.Current:
|
|
|
- var currnet = (double)obj.Value * obj.Scale;
|
|
|
- this.pub.SendMoreFrame( "BatteryCurrent" ).SendFrame( currnet.ToString() ); ;
|
|
|
+ this.pub.SendMoreFrame( "BatteryCurrent" ).SendFrame( obj.Value.ToString() ); ;
|
|
|
break;
|
|
|
case eDataKind.Voltage:
|
|
|
case eDataKind.BatteryState:
|
|
|
@@ -326,10 +325,11 @@ namespace VehicleControlSystem.ControlLayer.MQ
|
|
|
}
|
|
|
|
|
|
}
|
|
|
- catch ( Exception exception)
|
|
|
+ catch ( Exception exception )
|
|
|
{
|
|
|
logger.E( exception );
|
|
|
- } }
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
private void Sub_ReceiveReady( object sender, NetMQ.NetMQSocketEventArgs e )
|
|
|
{
|