Hi David,

These functions are there (see apps/modbus/mb.c for instance).

Did you follow this video tutorial:
https://www.youtube.com/watch?v=FmJLrG4Ldow

Best Regards,

Alan

On Tue, Apr 23, 2024 at 12:41 PM David Welshon <david.wels...@gmail.com>
wrote:

> I am trying to get modbus mastermode rs485 example working on
> nucleo-f4x1re following the example on the youtube channel.  I am getting
> undefined reference errors during linking and am not sure if I need to
> modify source or am missing a configuration option.  The device I am
> interacting with is set at a baudrate of 9600 with no parity instead of the
> baudrate in the video. But other than that I believe I followed the video
> closely.
>
> I started modifying the nsh config up to this point and have zerocross and
> gpio working, but I am stuck at the moment on this rs485 bit.  Appreciate
> any help.
> Also, I have not participated in many mailing lists, so if I am in the
> wrong place or I am breakin any etiquette rules I apologize in advance and
> appreciate your help finding any etiquette rules or posts to straighten me
> out.
>
> Attached is my build output and config file and below is a small build
> output snippet.
>
> include -D__NuttX__ -DNDEBUG -D__KERNEL__ -I
> /home/david/nuttxspace/nuttx/arch/arm/src/chip -I
> /home/david/nuttxspace/nuttx/arch/arm/src/common -I
> /home/david/nuttxspace/nuttx/arch/arm/src/armv7-m -I
> /home/david/nuttxspace/nuttx/sched
> /home/david/nuttxspace/nuttx/boards/arm/stm32/nucleo-f4x1re/scripts/f401re.ld
> -o
> /home/david/nuttxspace/nuttx/boards/arm/stm32/nucleo-f4x1re/scripts/f401re.ld.tmp
>
> echo "LD: nuttx"
>
> LD: nuttx
>
> arm-none-eabi-ld --entry=__start -nostdlib --gc-sections --cref
> -Map=/home/david/nuttxspace/nuttx/nuttx.map
> -T/home/david/nuttxspace/nuttx/boards/arm/stm32/nucleo-f4x1re/scripts/f401re.ld.tmp
> -L /home/david/nuttxspace/nuttx/staging -L
> /home/david/nuttxspace/nuttx/arch/arm/src/board \
>
> -o /home/david/nuttxspace/nuttx/nuttx \
>
> --start-group -lsched -ldrivers -lboards -lc -lmm -larch -lxx -lapps -lfs
> -lbinfmt -lboard -lboard
> /usr/lib/gcc/arm-none-eabi/10.3.1/thumb/v7e-m/nofp/libgcc.a
> /usr/lib/gcc/arm-none-eabi/10.3.1/../../../arm-none-eabi/lib/thumb/v7e-m/nofp/libm.a
> --end-group
>
> arm-none-eabi-ld:
> /home/david/nuttxspace/nuttx/staging/libapps.a(modbus_main.c.home.david.nuttxspace.apps.examples.modbus_1.o):
> in function `modbus_pollthread':
>
> modbus_main.c:(.text.modbus_pollthread+0x56): undefined reference to
> `eMBInit'
>
> arm-none-eabi-ld: modbus_main.c:(.text.modbus_pollthread+0x82): undefined
> reference to `eMBSetSlaveID'
>
> arm-none-eabi-ld: modbus_main.c:(.text.modbus_pollthread+0x98): undefined
> reference to `eMBClose'
>
> arm-none-eabi-ld: modbus_main.c:(.text.modbus_pollthread+0x9e): undefined
> reference to `eMBEnable'
>
> arm-none-eabi-ld: modbus_main.c:(.text.modbus_pollthread+0xbe): undefined
> reference to `eMBPoll'
>
> arm-none-eabi-ld: modbus_main.c:(.text.modbus_pollthread+0xc4): undefined
> reference to `eMBDisable'
>
> arm-none-eabi-ld: modbus_main.c:(.text.modbus_pollthread+0xc8): undefined
> reference to `eMBClose'
>
> make[1]: *** [Makefile:211: nuttx] Error 1
>
> make[1]: Leaving directory '/home/david/nuttxspace/nuttx/arch/arm/src'
>
> make: *** [tools/Unix.mk:546: nuttx] Error 2
>
> "make all" terminated with exit code 2. Build might be incomplete.
>

Reply via email to