Fix mscv warnings

Change-Id: Icb8d8bd0a756acda12b7fb392f199f9216aebd7a
This commit is contained in:
Hans-Erik Floryd
2025-07-08 17:58:24 +02:00
parent 5827f10baa
commit c40fd2c98c
2 changed files with 2 additions and 2 deletions

View File

@@ -53,7 +53,7 @@ void ec_sync(int64 reftime, int64 cycletime, int64 *offsettime)
}
timeerror = -delta;
integral += timeerror;
*offsettime = (timeerror * pgain) + (integral * igain);
*offsettime = (int64)((timeerror * pgain) + (integral * igain));
}
/* RT EtherCAT thread */

View File

@@ -286,7 +286,7 @@ ec_mbxbuft *ecx_getmbx(ecx_contextt *context)
int ecx_dropmbx(ecx_contextt *context, ec_mbxbuft *mbx)
{
ec_mbxpoolt *mbxpool = &context->mbxpool;
int item = mbx - &(mbxpool->mbx[0]);
int item = (int)(mbx - &(mbxpool->mbx[0]));
EC_PRINT("dropmbx item:%d mbx:%p\n\r", item, mbx);
if ((item >= 0) && (item < EC_MBXPOOLSIZE))
{