ModBus fixes from Freddie Chopin

git-svn-id: http://svn.code.sf.net/p/nuttx/code/trunk@5351 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
patacongo 2012-11-14 14:29:01 +00:00
parent 372c7ce012
commit 81caf90b8d
2 changed files with 7 additions and 1 deletions

View File

@ -106,6 +106,10 @@ ifeq ($(CONFIG_EXAMPLES_MM),y)
CONFIGURED_APPS += examples/mm
endif
ifeq ($(CONFIG_EXAMPLES_MODBUS),y)
CONFIGURED_APPS += examples/modbus
endif
ifeq ($(CONFIG_EXAMPLES_MOUNT),y)
CONFIGURED_APPS += examples/mount
endif

View File

@ -399,10 +399,12 @@ eMBPoll( void )
ucMBFrame[usLength++] = ( uint8_t )( ucFunctionCode | MB_FUNC_ERROR );
ucMBFrame[usLength++] = eException;
}
#ifdef CONFIG_MB_ASCII_ENABLED
if( ( eMBCurrentMode == MB_ASCII ) && CONFIG_MB_ASCII_TIMEOUT_WAIT_BEFORE_SEND_MS )
{
vMBPortTimersDelay( CONFIG_MB_ASCII_TIMEOUT_WAIT_BEFORE_SEND_MS );
}
#endif
eStatus = peMBFrameSendCur( ucMBAddress, ucMBFrame, usLength );
}
break;