2018-02-11 06:40 AM
Hello I am Üzeyir. I use stm32f4 discovery. I should read analog value on simulink. I made a basic application. My application is that i use potansiyometre because of channing of analog value. If ADC is upper 500 , PD12 and PD13 will activated. otherwise PD15 and PD15 digital outputs will be activated. Digital outputs ara activated according to analog value. But ı cannot not drawed on simulink or read. . I tried a lot ways.
But ı taken a errors which is''Error reported by S-function 'amg_usbconverter_n_connect' in 'analog_okuma/Host Serial Rx':
Error: timeout occur while waiting for Rx data.''How can i read analog value?
null2018-02-14 07:06 PM
Hello,
Ãœzeyir
.Could you please give me more information?
for example:
- Simulink file.
- Hardware setup
For more information about UART you can see tutorial from these links:
http://aimagin.com/blog/how-to-use-uart-communication-port/
http://aimagin.com/blog/using-hardware-in-the-loop-with-waijung/
In addition, you can ask Aimagin's support team any questions about Waijung Blockset at
.Best regards,
2018-02-19 07:07 PM
Hi,
Ãœzeyir
.
Firstly, you need to separate as Target and Host. Target is MCU and Host is Simulink monitoring.
In the Target you must to use UART block in On-chip Peripherals and if you want to send data to MCU p
lease change UART Rx to Non-blocking transfer mode because in blocking mode your MCU doesn't do not thing while waiting for Rx data.
In the Host(PC) use Host Serial for receiving data from MCU.
Best regards,
2018-02-20 12:35 AM
You can use
http://www.st.com/en/development-tools/stm32-mat-target.html
in External mode as show in picture below.However,
stm32f4 discovery
require VCP(Virtual Com Port) for External mode (
http://www.st.com/en/development-tools/stm32-mat-target.html
) andcommunicate with .So, you need to setup your hardware like picture below. For detail you can see in this
https://community.st.com/0D50X00009XkX71SAF
.source:
http://aimagin.com/blog/using-hardware-in-the-loop-with-waijung/
Best regards,
2018-02-20 02:38 AM
I have this error. How can i solve this error?
Best Regards
2018-02-20 10:36 GMT+03:00 Aimagin Co., Ltd. <st-microelectronics@jiveon.com
>:
STMicroelectronics Community
<https://community.st.com/?et=watches.email.thread>
Re: How can I read analog to send computer on serialPort by using uart?
reply from Aimagin Co., Ltd.
<
and Audio* - View the full discussion
<https://community.st.com/0D70X000006Sw9jSAC
________________ Attachments : timeout occured while waiting for Rx data.PNG : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HxxX&d=%2Fa%2F0X0000000b2o%2F6nnS_QvJ0CRahIoXpu5RxDoAba8X2UXZeXYmXW8.FI8&asPdf=false2018-02-20 04:11 AM
Could you please give me more information?
for example:
- Simulink file.
- Hardware setup
Thank you.
2018-02-20 04:14 AM
I use stm32f407VG and usb tll converter
2018-02-20 14:11 GMT+03:00 Aimagin Co., Ltd. <st-microelectronics@jiveon.com
>:
STMicroelectronics Community
<https://community.st.com/?et=watches.email.thread>
Re: How can I read analog to send computer on serialPort by using uart?
reply from Aimagin Co., Ltd.
<
and Audio* - View the full discussion
<https://community.st.com/0D70X000006T00ISAS
________________ Attachments : uart.mdl.zip : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HxsP&d=%2Fa%2F0X0000000b2g%2FtC2Jqq5rVnpu9Iwa01NIciK1kRPUSUVe1jTMRUqAwQ4&asPdf=falseanalog_okuma.mdl.zip : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006Hxx7&d=%2Fa%2F0X0000000b2d%2FzqCxB5V2fxHCZgB7F7j8cxwDV9blXGMwPgOlfI0PhSU&asPdf=false2018-02-20 04:34 AM
Error cause from your Host didn't get data from Target.
Have you check your
usb tll converter connecting pin is correctly?
Target: USART3 Tx/Rx Pin D8/D9
Host: Which Serial com port you use? Please check for make sure in Device Manager.