07-17-2014 10:00 PM
I need to implement a project in wich an equipment comunicates via bluetooth (activating the serial port in Labview smplserl.llb) and the data most be analyzed through a VI named SIGNO that receives numbers 1 2 or 3 for each finger in a hand to detect what would be the sign showed in the hand output the letter or sign into a buffer to create a conversation using a Text to speach for windows created in Labview (TTS) and execute the TTS when a certain movement is done (right now is just by pressing a button speach).
ive tried allot of things, changing the structures in the TTS VI the cycle to proceed or the form of calling the VI.
Ive tried to call the TTS VI from the Smplserl but it stops the serial input, and also to put the smprserl into the TTS when requested.
1. I need that the port always receives.
2. While it receives the sign code the TTS VI must recognize the sign and put it into the buffer that will enter to the Text To Speach programed.
can some one help me with this, some recomendations. Im not an expert on Labview but i love to execute projects with Labview.
thanks allot.
attached is a zip with the files ive been using.
07-30-2014 01:01 PM
Hola ..
La razón por la que tu código no está fncionando se debe a que eestás ocupando una estructura de eventos dentro de un sub VI. La estructura de eventos siempre se va a ir al caso timeout; pues estás ocupando eventos dinámicos, y cambiar el valor programaticamente con el botón de Talk no generará este evento.
Te sugeriría integraras tu código de una forma diferente y evites usar variables dentro de tu código ...
Primero en el VI principal puedes dejar las funciones de escritura y lectura a serial; pero el subví de tts te sugeriría lo rehcieras empleando una estructura de casos para activarla o desactivarla y colocando signo después de TTS en tu VI principal
El código de Signo.vi podrías hacerlo más eficiente así...
La forma óptima para crear tu aplicación sería empleando un ciclo productor/consumidor
En el productor deberías colocar las entradas del serial y éstas enviarlas al consumidor para ser procesadas con Signo.vi y "habladas" con TTS
Aquí un tutorial de como desarrollar un ciclo productor consumidor
Producer/ Consumer
http://www.ni.com/white-paper/3023/es/
Espero esa información te sea útil
Saludos