Home
User Manual
Contents
1. MMN VeeaR www veear eu Read sound Mice E 37 Be AVEO ANY RE 38 ETON OSS NR EET RR 39 Protocol header le 40 EasyvH Arduino Library Documentation egene dee eege 41 EasyVR Class Helferefi6e seien ornetur enirn rubra nuu rm X EK ERR nr ar ne R ak rn dar kyN EN enREKO rewwe uo EeVRrARPrPI SEEN FM FEAR 41 gg 5 6 o457 R 41 Public Member Functions nennen nennen nnnnn nn nnnnannnrseni sn sssna rins sea iris ssa assa ssa sss 41 R is ejie t TENERE 42 Member Enumeration Documentation eesssessssssssssesseseeee nennen nennen nnns nas r snae nnns nns 42 Constructor amp Destructor Documentation nennen nnne nnnm nn nn nnns nnns 45 Member Function Documentation elsssessssssssssssssseseeenee nennen nennen nn nsnna nnns sna snis ea irri saa sss snas 45 EasyVRBridge Class Reference A 53 UIC MGTIO Ok P UNCION nmm 53 Detaled CSC ME T m 53 Member Function Documentation cccceccccccseeceeceeeceeceeeceeceeseceeceaeceeceaeeeesaeaeceeseuceessaeeessueeeeseaeeeesaaes 54 Easy VH COMMING CE uaaciuceca onu acis AR cecus usq avs Ea 55 Getting Starea ace RC 55 Speech RECOGNItION c cecccccceescecceeceeceeeceeceeeceecsueecesseeeceeeeeeceesseeeceeseueeeessueeesseaecesssaeeeessaeecessagee
2. 1 SS SS SS SS define STS TABLE SX 1At cable entries count lt l 2 gt 10 bit table name lt 3 35 gt counted SE define STS GRAMMAR Uy Si grammars flags lt l gt word counte lt 2 gt labels lt 3 35 gt m counted strings define STS TOKEN f received sonicnet token lt 1 2 gt i 7 prorocol arguments are in the cange 0x40 1 rto 0x60 T31 imelusivye define ARG MIN 0x40 define ARG MAX 0x60 define ARG ZERO 0x41 define ARG ACK 0x20 to read more status arguments tendit PROTOCOL H A better source of information and a reference protocol implementation for the C C language and can be found in the Arduino Library source 40 EasyVR 2 0 User Manual 3 6 6 v N VeeaR www veear eu EasyVR Arduino Library Documentation EasyVR Class Reference Public Types enum Moduleld VRBOT EASYVR EASYVR2 enum WakeMode WAKE ON CHAR WAKE ON WHISTLE WAKE ON LOUDSOUND WAKE ON 2CLAPS WAKE ON 3CLAPS enum ClapSense CLAP SENSE LOW CLAP SENSE MID CLAP SENSE HIGH enum PinNumber 101 102 IO3 enum SoundVolume VOL MIN VOL HALF VOL FULL VOL DOUBLE enum SoundIndex BEEP enum GrammarFlag GF_ TRIGGER enum RejectionLevel REJECTION MIN REJECTION AVG REJECTION MAX enum ErrorCode ERR DATACOL TOO LONG ERR DATACOL TOO NOISY ERR DATACOL TOO SOFT ERR DATACOL TOO LOUD ERR DATACOL TOO SOON ERR DATACOL TOO CHOPPY ERR DATACOL BAD WEIGHTS ERR DATACOL
3. baud Sets the new communication speed You need to modify the baudrate of the underlying Stream object accordingly after the function returns successfully Parameters is one of values in Baudrate Return values if the operation is successful bool sleep int8 t mode Puts the module in sleep mode Parameters mode is one of values in WakeMode optionally combined with one of the values in ClapSense Return values true if the operation is successful bool addCommand int8 t group int8_t index Adds a new custom command to a group Parameters 0 16 is the target group or one of the values in Groups 0 31 is the index of the command within the selected group Return values true if the operation is successful bool removeCommand int8 f group int8 f index Removes a custom command from a group Parameters 0 16 is the target group or one of the values in Groups 0 31 is the index of the command within the selected group Return values true if the operation is successful bool setCommandLabel int8 t group int8 t index const char name Sets the name of a custom command Parameters Return values User Manual 3 6 6 EasyVR 2 0 47 H MN WWW Veear eu VeeaR bool eraseCommand int8 t group int8 f index Erases the training data of a custom command Parameters 0 16 is the target group or one of the values in Groups 0 31 is the index of the command within the
4. Connect the XM pin of J4 on the EasyVR module for boot mode see Flash Update for a possible circuit 3 Power ON again the EasyVR module and the Arduino board reconnect the USB cable 4 Make sure you activate bridge mode either manually or automatically or you use adapter mode 5 Open the EasyVR Commander and select the Arduino serial port 6 While disconnected choose Update Custom Data from the Tools menu see Using Custom Data Edit Sketch Tools Help New Open Ctrl O Sketchbook Examples O1 Basics Close Ctrl W 02 Digital Save Ctrl S 03 Analog Save As Ctrl Shift S 04 Communication Upload Ctrl U 05 Control Upload Using Programmer 3 Ctrl Shift U UD Sensors 07 Display 08 Strings 09 USB Preferences Ctrl Comma 10 StarterkKit ArduinolSP Page Setup Ctrl Shift P Print Ctrl P Quit Ctrl Q EasyVR EasyVRBridge TestEasyVR EEPROM Esplora Ethernet Firmata GSM LiquidCrystal Robot Control Robot Motor SD Serva SaftwareSerial SPI Stepper TFT WiFi Wire Arduino Leonardo RET 8E To test the EasyVR module with your Arduino programming IDE 1 Make sure you did not activate bridge mode manually 2 Open the example sketch TestEasyVR from your IDE menu File gt Examples gt Easy VR 3 Upload the sketch and open the Serial Monitor window 4 See comments on top of the sketch for usage details When the EasyVR Commander is connected you can also generate a template code for Arduin
5. Parameters label when the function returns Return values bool playPhoneTone int8 t tone uint8 duration Plays a phone tone and waits for completion Parameters tone is the index of the tone 0 9 for digits 10 for key 11 for key and 12 15 for extra keys A to D 1 for the dial tone duration 1 32 is the tone duration in 40 milliseconds units or in seconds for the dial tone Return values if the operation is successful bool resetAll Empties internal memory for custom commands and groups Return values if the operation is successful Note lt will take about 35 seconds for the whole process to complete and it cannot be interrupted During this time the module cannot accept any other command The sound table and custom grammars data is not affected EasyVRBridge Class Reference Public Member Functions bool check bool checkEEPROM void loop uint8 ta rx uint8 ta tx uint8 tb rx uint8 tb tx void loop Stream amp s Detailed Description An implementation of a software bridge between two series of Rx Tx pins that enables routing of the hardware serial port connected to the PC to digital I O pins used as a software serial port connected to the EasyVR User Manual 3 6 6 EasyVR 2 0 53 H AN WWW Veear eu VeeaR Member Function Documentation bool check Tests if bridge mode has been requested Return values if bridge mode should be started Note The
6. Sound Table The EasyVR module can play one of the sounds or sentences saved on its internal flash memory A predefined beep sound is also always available even when no sounds have been downloaded to the module The custom sounds are organized in a so called sound table that users can prepare and build with the special QuickSynthesis tool Please refer to this applications own manual for details about the creation of a sound table Let s summarize the basic steps here Prepare the audio files you want to include in the sound table in WAV format uncompressed 16 bit 22050Hz mono To create the sound files you may use a free software like Audacity for example http audacity sf net Open Sensory s QuickSynthesis H 5 and create a new project specifying RSC4 family Add your WAV files and specify one of the supported compression scheme see table below Optionally add sentences by combining basic WAV sounds That allows you to save memory when you have speech audio files if they share some pieces like You said One You said Two and so on Build the project with QuickSynthesis and use default settings Build linkable module Load in CONST space Load above or at 0 You will be asked to recompress new or modified sound files just confirm and proceed Now save your project and build it once again so that the EasyVR Commander will see that your build is up to date The audio comp
7. Text of label ASCII characters from A to In reply to CMD DUMP SD STS ERROR e 65h Signal recognition error 1 2 Two positive values that form an 8 bit error code error 1 16 2 see appendix In reply to CMD RECOG SI CMD RECOG SD CMD TRAIN SD CMD PLAY SX STS INVALID v 76h Invalid command or argument In reply to Any invalid command or argument STS TIMEOUT t 74h Timeout expired In reply to CMD RECOG SI CMD RECOG SD CMD TRAIN SD 30 EasyVR 2 0 User Manual 3 6 6 Y MMN VeeaR www veear eu STS_INTERR 69h Interrupted recognition In reply to CMD_BREAK while in training recognition or playback STS SUCCESS o 6Fh OK or no errors status In reply to CMD BREAK CMD DELAY CMD BAUDRATE CMD TIMEOUT CMD KNOB CMD LEVEL CMD LANGUAGE CMD SLEEP CMD GROUP SD CMD UNGROUP SD CMD ERASE SD CMD NAME SD CMD RESETALL CMD QUERY IO CMD PLAY SX STS RESULT 72h Recognized SD SV command or Training similar to SD SV command 1 Command position 0 31 In reply to CMD RECOG SD CMD TRAIN SD STS SIMILAR s 73h Recognized SI word or Training similar to SI word 1 Word index 0 31 In reply to CMD RECOG SI CMD RECOG SD CMD TRAIN SD STS OUT OF MEM m 6Dh Memory error no more room for commands or sound table not present In reply to CMD GROUP SD CMD DUMP SX STS ID X 78h Provide firmware identification 1 Version identifier 0 In reply to CMD ID STS
8. the VeeaR website ifndef PROTOCOL H define PROTOCOL H define CMD BREAK EE define CMD SLEEP s Go to power down define CMD KNOB e 7 eset si knob lt gt define CMD LEVEL 1y eert sol level lt i gt define CMD LANGUAGE uc e language lt i define CMD TIMEOUT o set timeout lt 1 gt 7 do si recog fron ws i train sd command at group lt 1 gt pos lt 2 gt insert new command at group lt 1 gt pos lt 2 gt remove command at group 1 pos lt 2 gt dersd recog ae croup eO eroe medad reset command at group lt 1 gt pos lt 2 gt label command at group 1 pos 2 with length 3 name lt 4 n gt get command count for group lt 11 gt read command data at group 1 pos lt 2 gt get active group mask reset all commands and groups get version id set transmit delay 1 log scale set baudrate 1 bit time 1 gt 115200 ECOntloure read or welte 1 0 pim lt l gt of type lt 2 gt wave table entry 1 2 10 bit playback at volume lt 3 gt play lt 1 gt 1 dial tone 2c for duration lt 3 gt dump wave table entries cumo si sertings ror ws lt l gt or IB ello we count dide 1 send sonicnet token with bits lt 1 gt index lt 2 3 gt at time lt 4 5 gt define CMD RECOG SI define CMD TRAIN SD define CMD GROUP SD define CMD UNGROUP SD define CMD RECOG SD define CMD ERASE SD define CMD NAME SD define CMD COUNT SD define CMD DUMP SD define CMD MASK SD define CM
9. BAD SETUP ERR RECOG FAIL ERR RECOG LOW CONF ERR RECOG MID CONF ERR RECOG BAD TEMPLATE ERR RECOG BAD WEIGHTS ERR RECOG DURATION ERR T2SI EXCESS STATES ERR T2SI BAD VERSION ERR T2SI OUT OF RAM ERR T2SIl UNEXPECTED ERR T2SIl OVERFLOW ERR T2SI PARAMETER ERR T2SI NN TOO BIG ERR T2SI NN BAD VERSION ERR T2SI NN NOT READY ERR T2S8l NN BAD LAYERS ERR T2SlI TRIG OOV ERR T2SI TOO SHORT ERR SYNTH BAD VERSION ERR SYNTH ID NOT SET ERR SYNTH TOO MANY TABLES ERR SYNTH BAD SEN ERR SYNTH BAD MSG ERR CUSTOM NOTA ERR SW STACK OVERFLOW ERR INTERNAL T2SI BAD SETUP Public Member Functions EasyVH Stream amp s bool detect bool stop int8 t getlD bool setLanguage int8 t lang bool setTimeout int8 t seconds bool setKnob int8 t knob bool setLevel mt t level bool setDelay uint16 t millis bool changeBaudrate int8 t baud bool sleep int8 t mode bool addCommand int8 t group int8 t index bool removeCommand int8 t group int8 t index bool setCommandLabel int8 t group int8 t index const char name bool eraseCommand int8 t group int8 t index bool getGroupMask uint32 t amp mask int8 t getCommandCount int8 t group bool dumpCommand int8 t group int8 t index char name uint8 t amp training int8 t getGrammarsCount void bool dumpGrammar int8 t grammar uint8 t amp flags uint8 t amp count bool getNextWordLabel char name User Manual 3 6 6 EasyVR 2 0 41 WWW Veear eu voi
10. Constants for choosing wake up method in sleep mode Enumerator WAKE_ON_CHAR Wake up on any character received WAKE_ON_WHISTLE Wake up on whistle or any character received WAKE ON LOUDSOUND Wake up on a loud sound or any character received WAKE ON 2CLAPS Wake up on double hands clap or any character received WAKE ON SCLAPS Wake up on triple hands clap or any character received enum ClapSense Hands clap sensitivity for wakeup from sleep mode Use in combination with WAKE ON 2CLAPS or WAKE ON 3CLAPS Enumerator CLAP SENSE LOW Lowest threshold CLAP SENSE MID Typical threshold CLAP SENSE HIGH Highest threshold User Manual 3 6 6 EasyVR 2 0 43 Y N WWW Veear eu VeeaR enum PinConfig Pin configuration options for the extra I O connector Enumerator OUTPUT LOW Pin is a low output OV OUTPUT HIGH Pin is a high output 3V INPUT HIZ Pin is an high impedance input INPUT STRONG Pin is an input with strong pull up 10K INPUT WEAK Pin is an input with weak pull up 200K enum PinNumber Available pin numbers on the extra I O connector Enumerator IO1 Pin IO1 IO2 Pin IO2 IO3 Pin 103 enum SoundVolume Some quick volume seitings for the sound playback functions any value in the range 0 31 can be used Enumerator VOL_MIN Lowest volume almost mute VOL_HALF Half scale volume softer VOL_FULL Full scale volume normal VOL_DOUBLE Double gain volume louder enum Soundindex Special sound index values always av
11. EasyVR Commander software can request bridge mode using the Serial port This method does not require to reserve EEPROM locations bool checkEEPROM d Tests if bridge mode has been requested legacy method Return values if bridge mode should be started Note The first two EEPROM locations bytes 0 1 are used for discovery and request of bridge mode from the EasyVR Commander software Do not use the same locations for other programa data void loop uint8 ta rx uint8 ta tx uint8 tb rx uint8 tb tx Performs bridge mode between port A and B in an endless loop Parameters is the Rx pin of port A is the Tx pin of port A is the Rx pin of port B is the Tx pin of port B Bridge mode internally connects Rx A to Tx B and Rx B to Tx A This is done by reading from a pin and writing to the other in a fast loop that runs until the microcontroller is reset void loop Stream amp s Performs bridge mode between the PC Serial port and the specified port in a continuos loop It can be aborted by sending a question mark Parameters is the target serial port Note You can use this alternate loop on boards that don t have a separate USB Serial adapter such as Arduino Leonardo 54 EasyVR 2 0 User Manual 3 6 6 Y MMN VeeaR WWW Veear eu EasyVR Commander The EasyVR Commander software can be used to easily configure your EasyVR module connected to your PC through an adapter board or by using the microco
12. Read used command groups request mask of groups in use XE TUE IF NOT RECEIVE k THEN ERROR read mask to 32 bits variable in 8 chunks of 4 bits each SEND mask RECEIVE A SPEND wc t mask mask RECEIVE A 2 SEND mask mask RECEIVE A 2 SEND mask mask RECEIVE A 2 Read how many commands in a group request command count of group 3 SENDER SED SUID LF NOT RECEIVE c THEN ERROR ack and read count SEND Count EE AS TF count 1 THEN count 32 Read a user defined command group dump command 0 in group 3 SEND p SENDEMDE SEND CA IF NOT RECEIVE d THEN ERROR read command data SENDERE training RECEIVE A f extract training count 2 for a completely trained command Econ Mr cA ANIL 7 extract irlags torocomblycts SD or SI EENEG read index of conflicting command same group if any SNID conflict RECEIVE A read label length SOND length RECEIVE A read label text PORC O TO lengeh 1 GH ee label i RECEIVE decode digits IF label i THEN SEND S abe ie RE Chi ECC SUAE END IF NEXT 36 EasyVR 2 0 User Manual 3 6 6 VeeaR www veear eu Use general purpose UO pins 7 set 10L pin to logie low level SEND q SEND B SEND A IF RECEIVE o THEN OK ELSE ERROR T Sert 102 pin co logie higa leyel SEND q SEND C SEND B IF RECEIVE o TH
13. User Manual 3 6 6 EasyVR 2 0 33 WWVW Veear eu Recognition of a built in or custom SI command start recognition in wordset 1 SENDERE EXE ASIE wait for reply if 5s timeout has been set wait for max 6s then abort otherwise trigger recognition could never end result RECEIVE IF result s THEN successful recognition ack and read result SEND command RECEIVE A perform actions according to command BSH Ik axesmlt tet THEN timed out no word spoken ELSE IF result e THEN error code ack and read which one SH Nae eppopc c RECEIVE lee EXE E error error RECEIVE E p perron act accore TO error ELSE invalid request or reply ERROR END IF Adding a new SD command insert command 0 in group 3 SEND g SEND D SEND A IF RECEIVE o THEN OK ELSE ERROR set command label to ARDUINO 2009 SEND g ey lio ID SEND A SEND name length 16 characters digits count twice SEND A EXEUNT SEDED SEND PU SEND 14 XENON ey aso Oa SEND Y encode each digit with a prefix followed by the digit mapped to upper case letters SENDERO VeeaR XD OL SINE ee SEND AY SENDE SEND A SENDERE SENDER IF RECEIVE o THEN OK ELSE ERROR 34 EasyVR 2 0 User Manual 3 6 6 VeeaR Training an SD command repeat the whole training procedure twice for best train command O0 in group 3 ETT k Sek DEEG SEND A wait for reply default timeout is
14. VeeaR Microphone The microphone provided with the EasyVR module is an omnidirectional electret condenser microphone Horn EM9745P 382 e Sensitivity 38dB 0dB 1V Pa 1KHz e Load Impedance 2 2K e Operating Voltage 3V e Almost flat frequency response in the range 100Hz 20kHz If you use a microphone with different specifications the recognition accuracy may be adversely affected No other kind of microphone is supported by the EasyVR module Note Vocal commands should be given from about 60cm from the microphone but you can try at greater distances by talking louder Positioning guidelines Please note that improper acoustic positioning of the microphone will reduce recognition accuracy Many mechanical arrangements are possible for the microphone element and some will work better than others When mounting the microphone in the final device keep in mind the following guidelines 1 Flush Mounting The microphone element should be positioned as close to the mounting surface as possible and should be fully seated in the plastic housing There must be no airspace between the microphone element and the housing Having such airspace can lead to acoustic resonance which can reduce recognition accuracy mc BAD 8 EasyVR 2 0 User Manual 3 6 6 H AN VeeaR www veear eu 2 No Obstructions Large Hole The area in front of the microphone element must be kept clear of obstructions to avoid interference with reco
15. data in speech file or invalid compression 80h ERR NOT A WORD recognized word is not in vocabulary The first group of codes 03h 07h is due to errors in the way of speaking to the EasyVR or disturbances in the acquired audio signal that may depend on the surrounding environment The second group 11h 13h indicates an insufficient score of the recognized word from lowest to highest Acceptance of lower score results may be allowed by lowering the knob or level settings respectively for built in and custom commands see CMD KNOB and CMD LEVEL A third group of codes 14h 17h reports errors in the stored commands that may be due to memory corruption We suggest you check power level and connections then erase all the commands in the faulty group and train them again The fourth group 4Ah 4Eh deals with errors in the compressed sound data either because the wrong version of the QuickSynthesis M tool has been used to generate the sound table or because a not supported compression scheme has been selected or data is generically corrupt The last code 80h means that a word has been recognized that is not in the specified built in sets This is due to how Speaker Independent recognition works and should be ignored User Manual 3 6 6 EasyVR 2 0 39 Y N WWW Veear eu VeeaR Protocol header file This file protocol h can be used with applications written in the C language You can download a copy from
16. opecial group numbers for recognition of custom commands Enumerator TRIGGER The trigger group shared with built in trigger word PASSWORD The password group uses speaker verification technology EasyVH 2 0 VeeaR User Manual 3 6 6 v N VeeaR www veear eu enum Wordset Index of built in word sets Enumerator TRIGGER_SET The built in trigger word set ACTION_SET The built in action word set DIRECTION_SET The built in direction word set NUMBER_SET The built in number word set enum Knob Confidence thresholds for the knob settings used for recognition of built in words or custom grammars not used for the mixed trigger group Enumerator LOOSER Lowest threshold most results reported LOOSE Lower threshold more results reported TYPICAL Typical threshold deafult STRICT Higher threshold fewer results reported STRICTER Highest threshold fewest results reported enum Level otrictness values for the level settings used for recognition of custom commands not used for the mixed trigger group Enumerator EASY Lowest value most results reported NORMAL Typical value default HARD Slightly higher value fewer results reported HARDER Higher value fewer results reported HARDEST Highest value fewest results reported enum Baudrate Constants to use for baudrate settings Enumerator B115200 115200 bps B57600 57600 bps B38400 38400 bps B19200 19200 bps B9600 9600 bps default enum WakeMode
17. selected group Return values if the operation is successful bool getGroupMask uint32_t amp mask Gets a bit mask of groups that contain at least one command Parameters mask is a variable to hold the group mask when the function returns eu O Fa S 5 lt D c o n true if the operation is successful int8 t getCommandCount int8_t group Gets the number of commands in the specified group 0 16 is the target group or one of the values in Groups integer is the count of commands negative in case of errors bool dumpCommand int8 t group int8 t index char name uint8 t amp training Retrieves the name and training data of a custom command Parameters 0 16 is the target group or one of the values in Groups 0 31 is the index of the command within the selected group points to an array of at least 32 characters that holds the command label when the function returns is a variable that holds the training count when the function returns Additional information about training is available through the functions isConflict and getWord or getCommand Return values if the operation is successful int8 f getGrammarsCount void Gets the total number of grammars available including built in and custom Return values integer is the count of grammars negative in case of errors 48 EasyVR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu bool dumpGrammar int8 t gra
18. that you can verify them before updating the module Note The projects must have been built already with the QuickSynthesis or the QuickT2SI tool before the custom data generation can be completed successfully If a recent build is not available you will receive a warning message the project files can be opened in their respective tools and a fresh build started make sure the project file has been saved before the build Once back in the EasyVR Commander the project can be reloaded by pressing the Refresh button If the process completes successfully the Download button will be enabled and the flash update process can start 62 EasyVR 2 0 User Manual 3 6 6 H AN VeeaR WWW Veear eu Build Custom Data d 3 Building custom data NL Custom data built successfully Project Filename C sers Paolo Desktopi C sers PaololDesktop F Index d Q0 WS4FASY VR 0 weg LOCK THE DOOR 1 WS5 OPEN THE WINDOW Slow Transfer 2 WS5 SWITCH THE LIGHTS 1 2 QJ Ch CS Download SND ahooga SMD alarm iK M Weg KKK Figure 11 Interface to build and download custom data The download process will connect at a higher speed to the EasyVR module so the bridge program running on your host device might not work in particular Robonova and Basic Stamp cannot be used for this purpose and you might need a true serial adapter The full speed used is 230400 bps but the option Slow t
19. the values in Groups Note The module is busy until recognition completes and it cannot accept other commands You can interrupt recognition with stop void recognizeWord int8 t wordset Starts recognition of a built in word Results are available after hasFinished returns true Parameters wordset 0 3 is the target word set or one of the values in Wordset 4 31 is the target custom grammar if present Note The module is busy until recognition completes and it cannot accept other commands You can interrupt recognition with stop User Manual 3 6 6 EasyVR 2 0 49 H AN WWW Veear eu VeeaR bool hasFinished Polls the status of on going recognition training or asynchronous playback tasks Return values if the operation has completed int8 f getCommand Gets the recognised command index if any Return values 0 31 is the command index if recognition is successful 1 if no command has been recognized or an error occurred int8 t getWord Gets the recognised word index if any from built in sets or custom grammars Return values is the command index if recognition is successful 1 if no built in word has been recognized or an error occurred int16 t getToken Gets the index of the received SonicNet token if any Return values integer is the index of the received SonicNet token 0 255 for 8 bit tokens or 0 15 for 4 bit tokens if detection was successful 1 if n
20. 1 Group index 0 trigger 1 15 generic 16 password Expected replies STS COUNT CMD DUMP SD p 70h Read SD SV command data label and training 1 Group index 0 trigger 1 15 generic 16 password 2 Command position 0 31 Expected replies STS DATA CMD MASK SD m 6Dh Request bit mask of non empty groups Expected replies STS MASK CMD RESETALL r 72h Reset all commands and groups R 52h Confirmation character Expected replies STS SUCCESS CMD ID X 78h Request firmware identification Expected replies STS ID CMD DELAY y 79h Settransmit delay 1 Time 0 10 0 10 ms 11 19 20 100 ms 20 28 200 1000 ms Expected replies STS SUCCESS User Manual 3 6 6 EasyVR 2 0 www veear eu 27 Y N WWW Veear eu VeeaR CMD BAUDRATE a 61h Set communication baud rate Speed mode 1 115200 2 57600 1 3 38400 6 19200 12 9600 Expected replies STS SUCCESS CMD_QUERY_IO q 71h Configure query or modify general purpose UO pins 1 Pin number 1 pin IO1 2 pin 102 3 pin 103 Pin mode 0 output low 1 output high 2 input 3 input strong 4 input weak High impedance input no pull up Strong means 10K internal pull up Weak means 200K internal pull up default after power up Expected replies STS SUCCESS mode 0 1 STS_PIN mode 2 4 2 CMD PLAY SX W 77h Wave table entry playback Two po
21. 2 1 amp 2008 Sensory Inc Figure 9 External tool for creating a Soundtable Note Only one Soundtable can be downloaded to the EasyVR module so make sure you include all the sounds you want to use in a single project Speaker Independent Custom Vocabularies The set of built in Speaker Independent recognition vocabularies can be expanded with custom grammars that you can create with the QuickT2S tool a separate license is required to use the software When you create a QuickT2S project you are presented with a list of words or short phrases also called commands and an optional trigger word phrase The so called trigger is a special set that contains only one word or phrase with an improved recognition performance that is used as an entry point for any vocal interaction with a device that is continuously listening to the user s voice If you need to use a trigger word it is important to carefully choose it so that it has good performance with very few unintended activations and a high recognition rate When the user says the trigger word followed by a command the system can discard unintended activations when the trigger is not followed by a command within a short amount of time usually around 3 seconds Moreover there is only one trigger word to listen to instead of a list of several commands so the chance to pick up a random command from background noise or talk is also lower when using a trigger word F
22. 3s wait for max ls more then result RECEIVE IF RECEIVE o THEN training successful OK ELSE IF result r THEN training saved but spoken command is similar another SD command read which one EET 23 command RECEIVE A may notify user and erase training or keep it ELSE IF result s THEN training saved but spoken command is similar another SI command always trigger may skip r SIBI ET command RECEIVE A may notify user and erase training or keep it BLSH IF result t THEN timed out no word spoken or heard ELSE IF result e THEN error code ack and read which one SND uo error RECEIVE A 16 SENDS error error RECEIVE A p pertozm actions according EO error ELSE invalid request or reply ERROR END IF Recognition of an SD command i rart recognition in group i iua V otv SEND ee wait for reply result RECEIVE IE result YY THEN successful recognition ack and read result SSND S command RECEIVE A perform actions according to command ELSE IF result t THEN timed out no word spoken ELSE IF result e THEN error code ack and read which one EXIRET ME error RECEIVE A 16 Sani Y 4 enroc Error RECEIVE AT perform actions according to error ELSE invalid request or reply ERROR END IF User Manual 3 6 6 EasyVR 2 0 results abort to toO eading WWW Veedr eu 35 WWW Veear eu VeeaR
23. 6 6 EasyVR 2 0 17 Y MN www veear eu VeeaR EasyVR on Arduino Mega EasyVH is compatible with the Arduino Mega Just line up A5 on the Shield with A5 on the Arduino and do the same with DO Just as shown below in the picture Then plugin the Shield as you are used to on any other Arduino board o oe SOO Sm ee vd RTR M NM M IIEMSIBINE COMMUNICATION _ EasyVR on Arduino Leonardo Please note The use of the EasyVR Commander with Arduino Leonardo is only possible for command creation training and for testing the EasyVR functions by using the bridge software included with the latest Arduino library version 1 4 and later To update the Flash memory and to load custom grammars sounds on the EasyVR you may use a normal Arduino board The EasyVR Shield can communicate with a Leonardo board the following way 1 Using Seriali on pins 0 1 and Jumper in the HW position The EasyVR Module can communicate with Arduino Leonardo the following way 1 Using Seriali on pins 0 1 2 Using any possible Soft serial setup Please refer to the following notes for more info http arduino cc de Reference SoftwareSerial 18 EasyVR 2 0 User Manual 3 6 6 v MN VeeaR WWW Veear eu EasyVR Shield for Arduino The EasyVR Shield is an Arduino shield integrating the EasyVR module designed to simplify the EasyVR management for Arduino developers Technical specifications Physical dimensions and pin assignment
24. D RESETALL define CMD ID define CMDEDETAY define CMD BAUDRATE define CMD QUERY IO define CMD PLAY SX define CMD PLAY DTMF define CMD DUMP SX define CMD DUMP SI define CMD SEND SN MOUNTS SD Duke NH HO oo mp Oe t Ss SS SS SS Dum Dum s SS 5s EM ES SEN Dux SS SS SS ES EST Dum SS Dese SS SS SS Du SS Ss Ss ES ES SS SS SS SS define CMD RECV SN f receive sonicnet token with bits lt l gt rejection 2 timeout lt 3 4 gt define STS MASK k mask of active groups 1 8 define STS COUNT Dou Ec od oi commando lt gt en number ote es define STS AWAKEN w back from power down mode define STS DATA 1e provide craining lt l gt conilict lt 2 gt command label lt 3 35 gt counted string define STS ERROR define STS INVALID define SHS EOE define STS INTERR em ND DO d 0 SN BIN SS SS Signal error code 1 2 invalid command or argument timeout expired back from aborted recognition see break Dos SS 5s SS Dese ES define STS SUCCESS oO nor errors Status define STS RESULT ia 95 recognised sd command lt l gt icraininc similar to sa lt gt define STS SIMILAR recognised si lt 11 gt in mixed si scl training similar cto si lt 11 gt define STS OUT OF MEM define STS ID define STS PIN no more available commands see group provide version id 1 return pin state
25. EN OK ELSE ERROR set IO2 pin as input with strong pull up and read state SEND q SENDERE SENDEN DE IF NOT RECEIVE oi THEN ERROR ack and read logic level SE ND at pube Jue E INS BIN NAN set IO3 pin as high impedance input SEND q SEND D SEND C IF NOT RECEIVE p THEN ERROR Use custom sound playback reading state is optional play a beep at full volume works with any or no table SEND wt SEND A SEND A RE IF RECEIVE o THEN OK ELSE ERROR play entry 13 at half volume SEND w SEND A SEND UN SENDS IF RECEIVE o THEN OK ELSE ERROR play entry 123 29 32126 at max volume SEND w re SEND AT 26 SEND AY F 31 IF RECEIVE o THEN OK ELSE ERROR Read sound table dump sound table SEND in IF NOT RECEIVE h THEN ERROR read count of entries and name length XS Y t Couine RECEIVE E S NID E Counti T E ER S CBIBGIESL VR e n SNID length RECEIVE A read name text FOR a 0 T0 le ngeh 1 SENG label i RECEIVE NEXT User Manual 3 6 6 EasyVR 2 0 37 Y MN WWW Veear eu VeeaR Built in Command Sets In the tables below a list of all built in commands for each supported language along with group index trigger or word set command index and language identifier to use with the communication protocol Language Trigger Command English r a 1 move vi ee sume ghe nee bouos 2 um o
26. I O pin connected 5V source I O pin with isolated input for safety or switching sensor such as MCU output pin circuits All these circuits assume the EasyVR pin has been configured with an internal pull up passive components value can be adjusted to account for weak or strong pull up Disabling the internal pull up could be used to put the pin in high impedance state for example to simulate a tri state or open drain output port Again you should refer to the manufacturer s datasheet when interfacing any external components and to calculate required resistors values or other passive components Flash Update The EasyVR module includes a boot loader that allows to update the firmware and to download new sound tables to the on board memory The boot mode is activated by keeping the XM signal to a high logical level at power on or reset This can be easily done with a jumper or switch taking the signal to a suitable pull up resistor To download a firmware update a sound table or a custom grammar to the EasyVR power on the module with the jumper closed For normal operation just leave the jumper open Do not change the jumper position while the module is already powered on It is safe to change XM level while the module is reset RST low User Manual 3 6 6 EasyVR 2 0 11 Y N WWW Veear eu VeeaR Internal 1KQ Pull down O O Jumper Boot mode selection circuit The pull up resistor v
27. LINE OUT A MIC IN Aref Gnd 013 012 Du pp Da 07 De D 04 03 De Di D pee ba J pe EIE Cl COU ea lt i lela 68 7 mm l a 1 il th Ge oz T EHE TTT iliiliiiiill EasyVR Exe EasyVR 410 Shield D5 SE H Chdeld Shield interface same as on Arduino Connector Number Pins 0 1 are in use when J12 is set as UP PC or HW J1 J2 J3 J4 Pins 12 13 are in use when J12 is set as SW J9 EE LINE OUT o 3 5mm stereo mono headphone jack 16Q 320 headphones Differential audio output can directly drive an 8O speaker SPEAKER Microphone input signal Microphone reference ground 03 ep jOmmdmbeme CH O General purpose I O 3 0 VDC TTL level J13 Also used for on board green LED D6 38 02 General purpose I O 3 0 VDC TTL level ui D wo General purpose I O 3 0 VDC TTL level Note the GPIO J13 2 J13 3 and J13 4 are at nominal 3 0VDC level Do not connect 5VDC directly to these pins User Manual 3 6 6 EasyVR 2 0 19 Y N WWW Veear eu VeeaR Recommended Operating Conditions The EasyVR Shield version 2 0 and earlier is compatible only with Arduino boards at 5V I O voltage levels Warning Do not connect the EasyVR Shield to systems with 3 3V I O levels You may use the EasyVR Module on systems with an incompatible I O voltage Jumper settings J12 Operating mode This jumper selects the operating mode of the EasyVR Shield and it ca
28. LOW ran out of time to process ERR T2SI PARAMETER bad macro or grammar parameter ERR T2SI NN TOO BIG layer size out of limits ERR T2SI NN BAD VERSION net structure incompatibility ERR T2SI NN NOT READY initialization not complete ERR T2SI NN BAD LAYERS not correct number of layers ERR T2SI TRIG OOV trigger recognized Out Of Vocabulary ERR T2SI TOO SHORHT utterance was too short ERR SYNTH BAD VERSION bad release number in speech file ERR SYNTH ID NOT SET obsolete bad sentence structure ERR SYNTH TOO MANY TABLES obsolete too many talk tables ERR SYNTH BAD SEN obsolete bad sentence number ERR SYNTH BAD MSG bad message data or SX technology files missing ERR CUSTOM NOTA none of the above out of grammar ERR SW STACK OVERFLOW no room left in software stack ERR INTERNAL T2SI BAD SETUP T2SI test mode error Constructor amp Destructor Documentation EasyVR Stream amp s Creates an EasyVR object using a communication object implementing the Stream interface such as HardwareSerial or the modified SoftwareSerial and NewSoftSerial Parameters S the Stream object to use for communication with the EasyVR module Member Function Documentation bool detect Detects an EasyVR module waking it from sleep mode and checking it responds correctly Return values if a compatible module has been found bool stop Interrupts pending recognition or playback operations Return values if the request is satisfied and
29. PIN P 70h Provide pin input status 1 Logic level 0 input low 1 input high In reply to CMD QUERY IO STS TABLE SX d 64h Provide sound table data 1 2 Two positive values that form a 10 bit count of entries in the sound table count 1 32 2 3 Length of table name 0 31 4 n Text of table name ASCII characters from A to In reply to CMD DUMP SX User Manual 3 6 6 EasyVR 2 0 31 Y N WWW Veear eu VeeaR STS GRAMMAR Z 7Ah Provide custom grammar data 1 Some flags for this grammar currently16 is returned for trigger grammars 0 for commands 2 Number of commands in this grammar 0 31 3 Length of first command label 0 31 4 n Text of first command label ASCII characters from A to E Repeat last two fields for all the commands in this grammar In reply to CMD DUMP SI STS TOKEN f 66h Detected a SonicNet token 1 2 Two positive values that form the index of a received token index 1 32 2 0 15 for 4 bit tokens or 0 255 for 8 bits tokens In reply to CMD RECV SN 32 EasyVR 2 0 User Manual 3 6 6 v MMN VeeaR www veear eu Communication Examples These are some examples of actual command and status characters exchanged with the EasyVR module by host programs and the expected program flow with pseudo code sequences The pseudo instruction SEND transmits the specified character to the module while RECEIVE waits for a reply character a timeout i
30. VR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu Quick start guide for using the Shield Follow these few steps to start playing with your EasyVR Shield and Arduino 1 Insert the EasyVR Shield on top of your Arduino board 2 f you want audio output either wire an 8O speaker into the screw terminals J10 or connect headphones to the 3 5mm output jack J9 3 Connect the supplied microphone to the MIC IN J11 connector 4 Install the EasyVR Arduino libraries on your PBC details at http arduino cc en Guide Libraries 5 Connect your Arduino board to your PC via USB Cerca in EasyVR Commander A oon BE EasyVR Arduino library 1 4 zip recenti uw Desktop T I Documenti i Computer Nome file EasyVR Arduino library 1 4 zip Tipo file ZIP files or folders With Arduino Leonardo Test the Shield with Arduino Make sure the jumper J12 is in the HW position Open the example sketch TestEasyVR from your IDE menu File gt Examples gt Easy VR Upload the sketch and open the Serial Monitor window Send a question mark without quotes After a few seconds you should receive an EasyVR detected message pu e Test the Shield with the EasyVR Commander 1 Make sure the jumper J12 is in the HW position 2 Close the serial monitor window in the Arduino IDE 3 Open the EasyVR Commander and connect to the Arduino serial port see Getting Started With Ardu
31. VeeaR User Manual Release 3 6 6 www veear eu Y N WWW Veear eu VeeaR Table of Contents Sy NC m 5 zijeeedBi oi m nes xsacn 5 EASY WE c n w w Gnw nnn 5 Ee in ele te en NETT EE T E UU 6 Physical dimensions arid pihi assighirrieni uuaiecuc E 6 Recommended Operating Conditions ccccccseeecececeeeeeceeeeeeeeeeeeeseeeeeeeeesaeeeeeeessaeeeeeesseaeeeeeessaageeeesssaaess 7 Seiren e e METEO TTE 7 Power Supply Heouremente nennen nennen nnns nn hann n nns snsa sinn rss na ian n rs nna n rens 7 De ZUM RIT e E E E OO OTT 7 Mlegeegon MC M ds 8 EELER ENERO m 9 ech riute 219 L 10 RUE Bere rci EE TOU 11 Quick sian Tor using the itd ON TOTO EODEM 13 EasyVR Development Board MN E E m D OUTRE 13 SEA ROM e Ugo MR TER Rem 14 doy Vr e ell et e E e Me r m 17 SES e ie Re Lu NN mmm 17 EasyVR on Arduino Mega nennen nennen nennen nnne nnns nena n rsen nn renean eres na enne a nnns nan rne 18 Eas VF Ol FOU eC nite RETE 18 Easy VR Sibel TOP FAO me 19 ES Eer eier e f RTT TOTO Tm aa 19 Physical dimensions and pin assigmnmenmt nennen nennen nn nnne nn nnn nnn nnn 19 Recommended Operating Condition
32. a ien mare were ora roume a mun om Eh rasne it ce cows a ox os RS mio sh mm regarde e so emo ten tomae nn para am o e ass me nach inks a la izquierda gauche 1 em adesa 5 mm sten aladerecha dote vers le EA em to e wer qme SE 8 dom ibaxo F shia hinunter abajo vers lebas A fowad aen W mae mp adelante en avant 8 backward indero 83 ushio r ckwirs az enambre o zo e pn ee Int oo fe 1 jme wo mm s wo jum 2 wo en m ie ien 8 mem 5 sm on rs me 4 tw quatro Ip e Ve cao age 8 ie one B o Im oe oe 6 o Im In ru se e Io 8 lom oe je an ae ri 9 oe ne a nm mm nee n 30 e dei In im zm e dk 38 EasyVR 2 0 User Manual 3 6 6 v W VeeaR www veear eu Error codes Below the list of the most useful error codes that may be returned by training or recognizing commands 03h ERR DATACOL TOO NOISY too noisy 04h ERR DATACOL TOO SOFT spoke too soft 05h ERR DATACOL TOO LOUD spoke too loud 06h ERR DATACOL TOO SOON spoke too soon 07h ERR DATACOL TOO CHOPPY too many segments too complex 11h ERR HECOG FAIL recognition failed 12h ERR RECOG LOW CONF recognition result doubtful 13h ERR RECOG MID CONF recognition result maybe 14h ERR HECOG BAD TEMPLATE invalid SD SV command stored in memory 17h ERR HECOG DURATION bad pattern durations 4Ah ERR SYNTH BAD VERSION bad release number in speech file 4Eh ERR SYNTH BAD MSG bad
33. a SonicNet token 1 Length of token 4 or 8 in bits 2 Rejection level 0 2 higher values mean fewer results 1 default 3 4 Two positive values that form a 10 bit timeout for token detection timeout 3 32 4 0 wait forever 1 1023 timeout in units of 27 46ms Expected replies STS TOKEN STS TIMEOUT User Manual 3 6 6 EasyVR 2 0 29 Y ui WWW Veear eu VeeaR Status Details Replies to commands follow this format Please note that numeric arguments of status replies are mapped to upper case letters see the related section STS MASK K Bh Mask of non empty groups 1 8 4 bit values that form 32 bit mask LSB first In reply to CMD MASK SD STS COUNT CG 63h Count of commands or total number of SI grammars 1 Integer 0 31 command grammar count 1 32 commands grammars In reply to CMD COUNT SD CMD DUMP SI STS AWAKEN W 77h Wake up back from power down mode In reply to Any character after power on or sleep mode STS DATA d 64h Provide command data Training information 1 empty 1 6 training count 8 SD SV conflict 16 SI conflict Known issues 1 In firmware ID 0 command creation deletion might cause other empty commands training count to change to 7 Treat count values of 1 O or 7 as empty training markers Never train commands more than 2 or 3 times 2 Conflicting command position 0 31 only meaningful when trained 3 Length of label 0 31 4 n
34. ailable even when no soundtable is present Enumerator BEEP Beep sound enum GrammarFlag Flags used by custom grammars Enumerator GF_TRIGGER A bit mask that indicate grammar is a trigger opposed to commands enum RejectionLevel Noise rejection level for SonicNet token detection higher value fewer results Enumerator REJECTION_MIN Lowest noise rejection highest sensitivity REJECTION_AVG Medium noise rejection medium sensitivity REJECTION_MAX Highest noise rejection lowest sensitivity enum ErrorCode Error codes used by various functions Enumerator ERR_DATACOL_TOO_LONG too long memory overflow ERR_DATACOL_TOO_NOISY too noisy ERR_DATACOL_TOO_SOFT spoke too soft ERR_DATACOL_TOO_LOUD spoke too loud ERR_DATACOL_TOO_SOON spoke too soon ERR DATACOL TOO CHOPPY too many segments too complex ERR DATACOL BAD WEIGHTS invalid SI weights ERR DATACOL BAD SETUP invalid setup ERR HRHECOG FAIL recognition failed 44 EasyVR 2 0 User Manual 3 6 6 H MAN VeeaR www veear eu ERR_RECOG_LOW_CONF recognition result doubtful ERR_RECOG_MID_CONF recognition result maybe ERR_RECOG_BAD_TEMPLATE invalid SD SV template ERR_RECOG_BAD_WEIGHTS invalid SI weights ERR_RECOG_DURATION incompatible pattern durations ERR T2SI EXCESS STATES state structure is too big ERR T2SI BAD VERSION RSC code version Grammar ROM dont match ERR T2SI OUT OF RAM reached limit of available RAM ERR T2SI UNEXPECTED an unexpected error occurred ERR T2SI OVERF
35. alue to use depends on the VCC power supply voltage For the voltage of the XM pin when the jumper is closed short the following relation holds note you have a voltage divider circuit Vey V Mm Rapai Now if you want XM to be at 3V logic high and solving for R you get Vec Rpy 1000 1000 That makes 1000 for 3 3V and around 6800 for 5V power supplies Other kinds of circuit are possible that is just an example and one of the simplest to realize To learn how to download new sound tables or custom grammars to your EasyVR 2 0 module have a look at the section Using Custom Data 12 EasyVR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu Quick start for using the module EasyVR Development Board The EasyVR DevBoard can be used to program commands and sounds into an EasyVR module and quickly test it Just put your EasyVR module on top of the DevBoard then connect the microphone and an 8 ohm speaker and you are ready to go The DevBoard features a Freescale JS8 microcontroller programmed as a USB Serial adapter to convert data sent between a PC and the EasyVH You can also write a test program on your PC using the serial port as you would on a microcontroller Also it is possible to upload new firmware and custom sound tables Everything is managed automatically by the DevBoard so there is no need to set any jumper the board enters automatically in boot loader mode when needed How fto get s
36. ble 14 15 00 00 40 89 0000 09 09 0 0 0 9 un am Figure 4 Conflicting commands The current status is displayed in the EasyVR Commander list view where groups that already contain commands are highlighted in bold The selected group of commands can also be tested by using the icon on the toolbar or the Tools menu to make sure the trained commands can be recognized successfully Note If you want to re train a command you have to erase the previous training first Note Vocal passwords group 16 are much more sensitive to environment noise and distance from the microphone be sure to train and give the password in similar conditions User Manual 3 6 6 EasyVR 2 0 57 Y WWW Veear eu VeeaR Phone Tones Generation DTMF The EasyVR module is also capable of generating DTMF sounds This feature can be tested by using the Dial Tones command in the Tools menu Dial Phone Number EasyVR DTMF Dialer Enter a phone number to dial or use the keypad Phone Keypad Tone duration ms Ettala ux Phone number 0 9 ABCD Lotte Figure 5 Interface for generating phone tones The tone duration can be specified in increments of 40 ms milliseconds The dial tone has a fixed duration of 3 seconds its duration can be modified when programming the EasyVH Testing SonicNet Another feature available from the Tools menu is the SonicNef a wireless communication protocol bas
37. d trainCommand int8 t group mp t index void recognizeCommand int8 t group void recognizeWord int8 t wordset bool hasFinished int8 t getCommand int8 t getWord int16 t getT oken int16 t getError bool isTimeout bool isConflict bool isMemoryFull bool setPinOutput int8 t pin int8 t value int8 t getPinInput int8 t pin int8 t config void detectToken int8 t bits int8 t rejection uint16 t timeout void sendTokenAsync int8 t bits uint8 t token bool sendToken int8 t bits uint8 t token bool embedToken int8 t bits uint8 t token uint16 t delay void playSoundAsync int16 t index int8 t volume bool playSound int16 t index int8 t volume bool dumpSoundTable char name int16 t amp count bool playPhoneTone int8 t tone uint8 t duration bool resetAll Detailed Description An implementation of the EasyVR communication protocol Member Enumeration Documentation enum Moduleld Module identification number firmware version Enumerator VRBOT Identifies a VRbot module EASYVH Identifies an EasyVR module EASYVR2 Identifies an EasyVR module version 2 enum Language Language to use for recognition of built in words Enumerator ENGLISH Uses the US English word sets ITALIAN Uses the Italian word sets JAPANESE Uses the Japanese word sets GERMAN Uses the German word sets SPANISH Uses the Spanish word sets FRENCH Uses the French word sets enum Group 42
38. e EasyVR Commander from your PC with the same pin configuration 2 Adapter mode You can use the Arduino board as a USB Serial adapter by holding the microcontroller in reset but you need to change the connections once you want to control the module from the microcontroller Bridge mode This is the preferred connection mode since it allows simple communication with both the Arduino microcontroller and the PC All the provided examples for Arduino manage the bridge mode automatically when the EasyVR Commander requests a connection r Sar m rmu I 1 DIGITAL PWN i oe A W Automatic bridge mode used to be supported only on Arduino boards with a bootloader implementing EEPROM programming The latest version of EasyVR Commander since 3 1 x and Arduino libraries since 1 1 does not rely on that feature anymore so it should work on all Arduino boards Note bridge mode cannot be used to download a Sound Table or to perform a flash update You need to use adapter mode or a true USB Serial adapter 14 EasyVR 2 0 User Manual 3 6 6 DH MN VeeaR WWW Veear eu Adapter mode This connection scheme has the advantage of working with any Arduino board that has an on board USB Serial adapter and not needing a spare input pin to enter bridge mode Also it does not rely on the AVR microcontroller to do any software bridge between communication pins so it can be used to check your hardware in case of connection proble
39. e used to start the recognition process e Group where you may add user defined SD commands e Password a special group for vocal passwords up to five using Speaker Verification SV technology e Wordset built in set of SI commands for instance in Figure 1 above the Wordset 1 is selected On some systems the EasyVR Commander can automatically upload the bridge program to the host board once connected That applies to Robonova controller board and Parallax Basic Stamp User Manual 3 6 6 EasyVR 2 0 55 Y N WWW Veear eu VeeaR Speech Recognition The recognition function of the EasyVR works on a single group at a time so that users need to group together all the commands that they want to be able to use at the same time When EasyVR Commander connects to the module it reads back all the user defined commands and groups which are stored into the EasyVR module non volatile memory You can add a new command by first selecting the group in which the command needs to be created and then using the toolbar icons or the Edit menu A command should be given a label and then it should be trained twice with the user s voice the user will be guided throughout this process see Figure 2 when the Train Command action is invoked Command Training Command 2 of Group 5 b TEST CMD TWO Phase 1 2 Press the Phase 1 button and say the word corresponding to the command TEST CMD TWO within 5 seconds P
40. ed on transmission and detection of special sequences of tones called tokens Two kinds of tokens can be selected a short version with up to 16 different tokens and a long version that provides up to 256 tokens Sonic Net EasyVR SonicNet Test sm Send or receive a special sound token Receive Token Timeout ms Rejection level 7 i send Token Token Length Token index Short 4 bits m Long 8 bits Delay by ms Figure 6 Interface for testing SonicNet features The EasyVR module can listen for incoming tokens continuously or for as long as about 28 seconds 58 EasyVR 2 0 User Manual 3 6 6 Y MN VeeaR WWW Veear eu specified with a granularity of around 27 5 ms Another parameter for token detection is the rejection level that specifies the receiver sensitivity higher rejection means lower sensitivity that is a lower detection rate and vice versa When the timeout parameter is set to 0 the module will listen continuously and you can use the Play button to send a token from your PC soundcard and the Stop button to stop listening Sonic Met EasyVR SonicNet Test 4m Send or receive a special sound token Receive Token Timeout ms Rejection level Lu Token Length Short 4 hits 3 Long 8 bits 0 Figure 7 Modified interface during continuous listening A prompt window will display the current state of token detection Continuos listening Rec
41. eesaeeeeeas 56 Phone Tones Generation DTMF ccccecccecccceeecceeeeeeeeeeeeeseeeeseceeeeseaeeeseceeeeeeseaessseeeeeessssaaaseeeeeeeessaaaaesss 58 Testing SonicNet H 58 Saee Dein O T E 60 OUA f 9 60 Speaker Independent Custom Vocabularies sss enne nennen nnne nennen nnns 61 Updating Custom Data RRRRRRRRREEEEEEEMEEEEEEEEEEEEEEEEEEEEEMM 62 LOG AIG UNM ANG NIE mmm 64 del EN e OU Wee ROTE Tc 64 Downloading custom data or update fails nennen nnne nnne nnne 64 FLOW TO Ke Ee e e Uu iet 65 User Manual 3 6 6 EasyVR 2 0 3 WWW Veear eu Document History Information Revision 3 6 6 3 6 5 3 6 4 3 6 3 3 6 1 3 6 3 4 2 3 4 1 3 4 3 3 Date 01 04 2014 25 11 2013 20 11 2013 18 11 2013 6 11 2013 5 11 2013 23 07 2013 14 11 2012 9 10 2012 8 10 2012 Before October 2012 VeeaR Description Updated documentation for the new Arduino Library Added software support for Arduino Leonardo Added warning for using the Shield on non 5V systems Added Arduino Mega and Arduino Leonardo Minor corrections and footnotes updated Changed connection diagram Arduino Uno BasicStamp Added more diagrams Added Arduino Pro mini Added note to function embedToken Removed Robonova Fixed cross references Updated pictures of new module version Updated Arduino Library documentation Updated docum
42. eived Token 5 Now listening Tokens may also be transmitted from the module with the Sena button An optional delay parameter can be used to indicate that the token will be mixed with the next sound played from the Soundtable after the specified amount of time since the playback begins In this case the SonicNet dialog will close to let you choose a sound to play back Note If you want to mix tokens with a compressed audio sample you must use a compression scheme with a sample rate of 9 3kHz when building the Soundtable in the QuickSynthesis tool If the delay is 0 the token is sent out immediately Other values can be specified up to around 28 seconds of delay with a granularity of around 27 5 ms Finally you can also export all the tokens of the specified length to some folder on your PC as Wave files WAV format by using the Generate button You can then use those files to embed SonicNet tokens into other software or external sound sources such as portable players CDs or DVDs etc User Manual 3 6 6 EasyVR 2 0 59 WWW Veeadr eu VeeaR Information CA Users Paolo Desktopi Easy VR with file names in th range token_000 waw to Token 015 wav zen Figure 6 Export of 4 bit tokens More details about this technology can be found in Sensory s application note 80 0307 B available at their website http www sensoryinc com support docs 80 0307 B pdf Using Custom Data
43. eless communications between modules or any other sound source Audio CD DVD MP3 Player new to EasyVR 2 0 DTMF tone generation new to EasyVR 2 0 Easy to use and simple Graphical User Interface to program Voice Commands and audio Module can be used with any host with an UART interface powered at 3 3V 5V Simple and robust documented serial protocol to access and program through the host board 3 x GPIO lines IO1 IO2 IO3 that can be controlled by new protocol commands PWM audio output that directly supports 80 speakers Sound playback of up to 9 minutes of recorded sounds or speech O En SE 0 X A QuickT2SI Lite license sold separately is required to enable creation of Speaker Independent vocabularies maximum 12 commands per set Custom Speaker Independent vocabularies SonicNet and DTMF generation are available since firmware version 2 a free update from version 1 is available for download User Manual 3 6 6 EasyVR 2 0 5 D AN WWW Veear eu VeeaR Technical specifications Physical dimensions and pin assignment 45 mm ETX ERX VCC GND Connector Number Name Type _Deseription a vCC d Voltage DC input g 8 ERX Serial Data Receive TTL level 4 ETX O Serial Data Transmit ES evel EUEER ER assum 1 MCRET Microphone reference See 2 MCN SE input signal 03 URS 1 et bremsen eng 03 M 1 Book seectiteral K pudou 4 i IO General p
44. entation for firmware version 2 additions custom grammars SonicNet and DTMF Troubleshooting Section added Troubleshooting Soundtable download Document History Information added EasyVR DK added Added CMD_COUNT_SD Added protocol examples Original Document EasyVR 2 0 User Manual 3 6 6 Y MMN VeeaR www veear eu EasyVR Module Product Description EasyVR 2 0 is a multi purpose speech recognition module designed to easily add versatile robust and cost effective speech recognition capabilities to almost any application The EasyVR 2 0 module can be used with any host with an UART interface powered at 3 3V 5V such as PIC and Arduino boards Some application examples include home automation such as voice controlled light switches locks curtains or kitchen appliances or adding hearing to the most popular robots on the market EasyVR 2 0 Features e Supports up to 28 custom Speaker Independent SI command vocabularies new to EasyVR 2 0 Supported Languages o US English UK English German French Italian LA Spanish Korean o Japanese e Supports up to 32 user defined Speaker Dependent SD triggers or commands as well as Voice Passwords SD custom commands can be spoken in ANY language e A variety of built in Speaker Independent SI commands for ready to run basic controls in the followings languages o English US o Italian o German o French o Spanish o Japanese e SonicNet technology for wir
45. gnition The diameter of the hole in the housing in front of the microphone should be at least 5 mm Any necessary plastic surface in front of the microphone should be as thin as possible being no more than 0 7 mm if possible clear area internal diaphragm 3 Insulation The microphone should be acoustically isolated from the housing if possible This can be accomplished by surrounding the microphone element with a spongy material such as rubber or foam The provided microphone has this kind of insulating foam The purpose is to prevent auditory noises produced by handling or jarring the device from being picked up by the microphone Such extraneous noises can reduce recognition accuracy BAD fastened directly absorbent material d Distance If the microphone is moved from 15 cm to 30 cm from the speaker s mouth the signal power decreases by a factor of four The difference between a loud and a soft voice can also be more than a factor of four Although the internal preamplifier of the EasyVR compensates for a wide dynamic range of input signal strength if its range is exceeded the user application can provide feedback to the speaker about the voice volume see appendix Error codes Audio Output The EasyVR audio output interface is capable of directly driving an 8Q speaker It can also be connected to an external audio amplifier to drive lower impedance loudspeakers Note Connecting speakers with lower impeda
46. hase 1 Figure 2 Guided training dialog Note after clicking on Phase 1 or Phase 2 buttons remember to start speaking only when you see this little window Speak now If any error happens command training will be cancelled Errors may happen when the user s voice is not heard correctly there is too much background noise or when the second word heard is too different from the first one Warning i Trained command is similar to existing command Keep current training anyway Figure 3 Alert dialog in case of conflict The software will also alert if a command is too similar to an existing one by specifying the index of the conflicting command in the Conflict column For example in the following Figure 4 the command 56 EasyVR 2 0 User Manual 3 6 6 Y MMN VeeaR WWW Veear eu TEST CMD ONE sounds too similar to TEST CMD ZERO i e they have been trained with a similar pronunciation Note TEST CMD ZERO and TEST CMD ONE are just examples of labels you should use label names that reflects the real command that you are going to train Only Latin characters and digits can be used for labels as well as the underscore character n EasyVR Commander v2 2 1 m File Edit Tools Help d i d cow IN ASQ e a e 4 oon Group List Group 5 Command List inie Label gt 0 TEST CMD ZERO n 1 TEST CMD ONE C 2 TEST CMD TWO Password Wordset Wordset Wordset 11 SoundTa
47. hed Parameters 4 or 8 specifies the length of received tokens rejection 0 2 specifies the noise rejection level it can be one of the values in HejectionLevel timeout 1 28090 is the maximum time in milliseconds to keep listening for a valid token or 0 to listen without time limits Note The module is busy until token detection completes and it cannot accept other commands You can interrupt listening with stop void sendTokenAsync int8 f bits uint8 t token Starts immediate playback of a SonicNet token Manually check for completion with hasFinished Parameters 4 or 8 specifies the length of trasmitted token token is the index of the SonicNet token to play 0 255 for 8 bit tokens or 0 15 for 4 bit tokens Note The module is busy until playback completes and it cannot accept other commands You can interrupt playback with stop User Manual 3 6 6 EasyVR 2 0 51 D AN WWW Veear eu VeeaR bool sendToken int8 f bits uint8 t token Plays a SonicNet token and waits for completion Parameters 4 or 8 specifies the length of trasmitted token token is the index of the SonicNet token to play 0 255 for 8 bit tokens or 0 15 for 4 bit tokens Return values if the operation is successful bool embedToken int amp _t bits uint8 t token uint16 t delay Schedules playback of a SonicNet token after the next sound starts playing Parameters 4 or 8 specifies the length of t
48. ino 2009 Uno Mega To check everything is working fine 1 Make sure the jumper J12 is in the PC position 2 Open the EasyVR Commander and connect to the Arduino serial port see Getting Started The Arduino library archive file is installed in the EasyVR Commander program folder User Manual 3 6 6 EasyVR 2 0 21 Y N WWW Veear eu VeeaR To download a new sound table 1 Make sure the jumper J12 is in the UP position 2 Open the EasyVR Commander and select the Arduino serial port 3 While disconnected choose Update Custom Data from the File menu see Using Custom Data Ctrl N Ctrl O Sketchbook Examples O1 Basics Close Ctrl W 02 Digital Save Ctrl S 03 Analog Save As Ctrl Shift S 04 Communication Upload Ctrl U 05 Control Upload Using Programmer 3 Ctrl Shift U UD Sensors 07 Display 08 Strings 09 USB Preferences Ctrl Comma lO StarterkKit ArduinoISP Page Setup Ctrl Shift P Print Ctrl P Quit Ctrl Q EasyVR EasyVRBridge TestEasyVR EEPROM Esplora Ethernet Firmata GSM LiquidCrystal Robot Control Robot Motor SD Servo SaftwareSerial SPI Stepper TFT WiFi Wire Arduino Leonardo on T 8D To test the Shield with your Arduino programming IDE 1 Set the jumper J12 in the SW position 2 Open the example sketch TestEasyVR from your IDE menu File gt Examples gt Easy VR 3 Upload the sketch and open the Serial Monitor window 4 See comments on top of
49. ins O AC MAINS Inverted Voltage OUT Switched Load Z I O pin directly driving a I O pin connected to high I O pin switching a load on a high voltage low current LED impedance 5V circuit such as line using a 12V relay MCU input pin 10 EasyVR 2 0 User Manual 3 6 6 v N VeeaR www veear eu The exact components values in these circuits may vary You need to calculate required values for your application and choice of components For example resistor value for the LED circuit can be calculated approximately as Vou B Vuen Boum LED Ios Where V gp is the LED forward voltage as reported on the LED datasheet at the driving current lop see section Electrical Characteristics Lets assume a typical low current LED has a V 1 8V at 5mA the resistor value is 2 4 1 8 Rigp 0 005 120 Ohm Now stay on the safe side and choose a slightly larger resistor such as 1500 If you want to drive higher current LEDs you need a circuit like the second one where you put the LED between the output resistor and the collector of the NPN transistor Use a pin as an input All the I O pins are inputs with weak internal pull up after power on or reset You may also configure the pin to have a strong pull up or no pull up at all see the example code Use general purpose I O pins Isolated IN optional filler o SWITCH I O pin connected to a switch
50. irmware ID 0 any other character received during recognition will prevent this command from stopping recognition that will continue until timeout or other recognition results Expected replies STS SUCCESS STS_INTERR CMD SLEEP s 73h Goto the specified power down mode Sleep mode 0 8 0 wake on received character only 1 wake on whistle or received character 2 wake on loud sound or received character 3 5 wake on double clap with varying sensitivity or received character 6 8 wake on triple clap with varying sensitivity or received character Expected replies STS SUCCESS STS AWAKEN 1 CMD KNOB K Bh Set SI knob to specified level Confidence threshold level 0 4 0 loosest more valid results 2 typical value default 4 tightest fewer valid results 1 Note knob is ignored for trigger words Expected replies STS SUCCESS CMD LEVEL v 76h Set SD level Strictness control setting 1 5 1 easy 1 2 default 5 hard A higher setting will result in more recognition errors Expected replies STS SUCCESS CMD LANGUAGE T 6Ch Set SI language Language 0 English 1 Italian 1 2 Japanese 3 German 4 Spanish 5 French Expected replies STS SUCCESS User Manual 3 6 6 EasyVR 2 0 25 WWW Veear eu CMD TIMEOUT oO 6Fh Set recognition timeout Expected replies STS SIMILAR STS TIMEOUT STS ERROR 1 Timeout 1 default O infinite 1 31 seconds Ex
51. mmar uint amp _t amp flags uint8 t amp count Retrieves the contents of a built in or a custom grammar Command labels contained in the grammar can be obtained by calling getNextWordLabel Parameters 0 31 is the target grammar or one of the values in Wordset flags is a variable that holds some grammar flags when the function returns See GrammarFlag count is a variable that holds the number of words in the grammar when the function returns Return values true if the operation is successful bool getNextWordLabel char name Retrieves the name of a command contained in a custom grammar It must be called after umpGrammar CL points to an array of at least 32 characters that holds the command label when the function returns Return values true 3 Di D if the operation is successful void trainCommand int8 t group int8 t index Starts training of a custom command Results are available after hasFinished returns true Parameters 0 16 is the target group or one of the values in Groups 0 31 is the index of the command within the selected group Note The module is busy until training completes and it cannot accept other commands You can interrupt training with stop void recognizeCommand int8 f group Starts recognition of a custom command Results are available after hasFinished returns true 5 D D 3 d FA e ji group 0 16 is the target group or one of
52. ms Using this method also allows you to download a Sound Table to the EasyVR module provided you also configure the module to start in boot mode see paragraph Flash Update TX Hemel rex Arduino This configuration with Reset shorted to GND is for connection with the EasyVR Commander To use the module from the Arduino microcontroller you need to remove the short yellow wire and move the ETX ERX connection to other pins The example code uses pin 12 for ETX and pin 13 for ERX like the above bridge mode Arduino software Follow these few steps to start playing with your EasyVR module and Arduino Connect the EasyVR module to your Arduino board as outlined before If you want audio output connect an 8O speaker to J2 header Connect the supplied microphone to the MIC J3 connector Install the EasyVR Arduino libraries on your PC details at http arduino cc en Guide Libraries Connect your Arduino board to your PC via USB E EE Pun To check everything is working fine 1 Make sure you activate bridge mode either manually or automatically or you use adapter mode 2 Open the EasyVR Commander and connect to the Arduino serial port see Getting Started The Arduino library archive file is installed in the EasyVR Commander program folder User Manual 3 6 6 EasyVR 2 0 15 Y N WWW Veear eu VeeaR To download a new sound table 1 Power OFF the EasyVR module for example removing the USB cable 2
53. n be placed in one of four positions o UP Flash update mode Use it for firmware updates or to download sound table data to the on board flash memory from the EasyVR Commander In this mode the Arduino controller is held in reset and only the embedded USB Serial adapter is used The EasyVR module is set in boot mode o PC PC connection mode Use it for direct connection with the EasyVR Commander In this mode the Arduino controller is held in reset and only the embedded USB Serial adapter is used o HW Hardware serial mode Use it for controlling the EasyVR module from your Arduino sketch through the hardware serial port using pins O 1 o SW Software serial mode Use it for controlling the EasyVR module from your Arduino sketch through a software serial port using pins 12 13 You can also connect the EasyVR Commander in this mode provided that the running sketch implements bridge mode see libraries Note on the Arduino Leonardo you can use the jumper only in the HW position both for Arduino sketches and for connection with the EasyVR Commander Please make sure you have the latest EasyVR Arduino library version 1 4 and later LEDs A green LED D6 is connected to IO1 pin and can be controlled by the user s program to show feedback during recognition tasks for example This LED is on by default after reset or power up The red LED D5 lights up when you set the shield to flash update mode see Jumper settings 20 Easy
54. nce directly to the module may permanently damage the EasyVR audio output or the whole module User Manual 3 6 6 EasyVR 2 0 9 Y N WWW Veear eu VeeaR J2 EasyVR 2 0 J1 Pinou It is possible to connect higher impedance loads such as headphones provided that you scale down the output power according to the speaker ratings for example using a series resistor The exact resistor value depends on the headphone power ratings and the desired output volume usually in the order of 10kQ Note Connecting headphone speakers directly to the EasyVR audio output may damage your hearing General Purpose UO Since the EasyVR communication interface takes two pins of the host controller a few spare I O pins are provided which can be controlled with the communication protocol to get those pins back for basic tasks such as lighting an LED The three I O pins IO1 IO3 are connected directly to the embedded microcontroller on the EasyVR module so they are referenced to the internal 3 0V regulated power supply If you need to interface to circuits using a different supply there are a number of solutions you can adopt Some of these are outlined below here IlOn indicates any one of the three I O pins of the EasyVR Use a pin as an output All the I O pins are inputs with weak internal pull up after power on You must explicitly configure a pin before you can use it as an output see the example code Use general purpose I O p
55. ntroller host board with the provided bridge program available for ROBONOVA controller board Arduino 2009 UNO Parallax Basic Stamp You can define groups of commands or passwords and generate a basic code template to handle them It is required to edit the generated code to implement the application logic but the template contains all the functions or subroutines to handle the speech recognition tasks Getting Started Connect the adapter board or a microcontroller host board with a running bridge program to your PC and then check that all devices are properly turned on and start the EasyVR Commander select the serial port to use from the toolbar or the File menu and then go with the Connect command Ele Edit Tools Help A cov amp G3 62 2 RS Ge ae ie i JC El oon m Group List Wordset 1 Command List Description Commands Trigger 0 Group Group Group Group Group Group Group Group Group Group Group gt Group Group Group Password SoundTa Wordset 2 Wordset Wordset OR KMIOTEK 1 0 0 0 0 0 0 0 0 0 Group 0 0 0 0 0 1 8 8 6 1 Ji Connected to EasyVR Shield Bridge VR Module Rev 2 _ Figure I Main application window There are four kinds of commands in the software see Figure 1 and Figure 4 e Trigger is a special group where you have the built in SI trigger word Robot and you may add one user defined SD trigger word Trigger words ar
56. o that will use the provided libraries see EasyVR Arduino Library Documentation All you need is to write actions for each recognized command and adapt the code to your needs 16 EasyVR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu EasyVR on Arduino Pro Mini The EasyVR can run on 3 3V and 5V input like the Arduino Pro Mini from Sparkfun 3 3V or 5V DC Input EasyVR 2 0 EasyVR on Basic Stamp The EasyVR module can be connected to all Basic Stamp 2 series devices following the connection scheme below This is supported by the EasyVR Commander software with a special bridge code running on the Basic Stamp which can be downloaded automatically if not present Status LED BASIC Stamp esx GND The status LED is used to signal that a recognition task is in progress and the application is listening for a voice command This is optional and can be omitted When connected with the EasyVR Commander you can add and remove custom voice commands as well as train and test them You can also generate a template PBAS C code to manage voice recognition which you can easily customize for your own application Please note the download of a sound table through any Basic Stamp 2 controller board is not supported due to limitations of this hardware setup You may use an USB Serial adapter such as the EasyVR DevBoard or another suitable configuration to update the flash memory of the EasyVR module User Manual 3
57. o token has been received or an error occurred int16 t getError Gets the last error code if any Return values 0 255 is the error code 1 if no error occurred bool tsTimeout Retrieves the timeout indicator Return values true if a timeout occurred bool isConflict Hetrieves the conflict indicator Return values true is a conflict occurred during training To know what caused the conflict use getCommand and getWord only valid for triggers bool isMemoryFull Retrieves the memory full indicator only valid after addCommand returned false Return values true if a command could not be added because of memory size constaints up to 32 custom commands can be created 50 EasyVR 2 0 User Manual 3 6 6 Y MN VeeaR WWW Veear eu bool setPinOutput int8 t pin int8 t value Configures an I O pin as an output and sets its value Parameters PinNumber 0 1 is one of the output values in PinConfig or Arduino style HIGH and LOW macros Return values int8 t getPininput int8 t pin int8 t config Configures an I O pin as an input with optional pull up and return its value Parameters 1 3 is one of values in PinNumber 2 4 is one of the input values in PinConfig Return values is the logical value of the pin void detectToken int8 t bits int8 t rejection uint76 t timeout Starts listening for a SonicNet token Manually check for completion with hasFinis
58. odule User Manual 3 6 6 EasyVR 2 0 23 Y N WWW Veear eu VeeaR Arguments Mapping Command or status messages sent over the serial link may have one or more numerical arguments in the range 1 to 31 which are encoded using mostly characters in the range of uppercase letters These are some useful constants to handle arguments easily ARG MIN 40h Minimum argument value 1 ARG MAX 60h Maximum argument value 31 ARG ZERO A 41h Zero argument value 0 ARG ACK 20h Head more status arguments Having those constants defined in your code can simplify the validity checks and the encoding decoding process For example in pseudo code encode value 5 LIVE 5 ARG ZERO decode value 5 FIVE ARG ZERO 5 validity check IF ARG lt EEN OR ARG ARG MAX THEN ERROR Just to make things clearer here is a table showing how the argument mapping works ASCII Q A B G u wi d YA T is T oy NM HEX 40 41 42 43 D 99 5A 5B 5C 5D sl SF 60 Value 1 0 1 2 i 24 25 26 2 28 29 30 31 24 EasyVR 2 0 User Manual 3 6 6 v AN VeeaR WWW Veear eu Command Details This section describes the format of all the command strings accepted by the module Please note that numeric arguments of command requests are mapped to upper case letters see above section CMD BREAK Abort recognition training or playback in progress if any or do nothing b 62h Known issues In f
59. or assistance on using the QuickT2SI Software please refer to the software help file User Manual 3 6 6 EasyVR 2 0 61 Y N WWW Veear eu VeeaR 6j TestGrammar Quick T251 3 1 7 FC3 1 6 Le File Edit Help Vocabula Tuning Settings Hardware Prompts Enter trigger phrase US English leasy vr Mine FA 0 Enter command phrases 1 lock the door 2 open the window 3 switch the lights Resources Used 9 Im HUM Size 7 Build Test Transter Figure 10 External tool for custom vocabularies Several projects can also be combined together if they are using the same acoustic model language data using the Acoustic Model Combiner included with the tool This is useful if you have many command vocabularies in order to save space in the EasyVR memory Updating Custom Data Once the sound table and or custom recognition grammars have been created they can be processed by the EasyVR Commander and downloaded to the module Note that you must first disconnect from the module and do the steps required to start it in boot mode see the section Flash Update Now the command Update Custom Data is enabled either on the toolbar or the File menu and it can be used to start the update process First you are required to list all the QuickSynthesis and QuickT2SI projects you want to use A new file containing the specified custom data will be generated and the contents will be displayed so
60. pected replies STS SUCCESS CMD RECOG SI 69h Activate SI recognition from specified word set 1 Word set index 0 3 VeeaR CMD TRAIN SD t 74h Train specified SD SV command 1 Group index 0 trigger 1 15 generic 16 password 2 Command position 0 31 Expected replies STS SUCCESS STS RESULT STS SIMILAR STS_TIMEOUT STS ERROR CMD GROUP SD g 67h Insert new SD SV command 1 Group index 0 trigger 1 15 generic 16 password 2 Position 0 31 Expected replies STS SUCCESS STS OUT OF MEM CMD UNGROUP SD Uu 75h Remove SD SV command 1 Group index 0 trigger 1 15 generic 16 password 2 Position 0 31 Expected replies STS SUCCESS CMD_RECOG_SD d 64h Activate SD SV recognition 1 Group index 0 trigger 1 15 generic 16 password Expected replies STS RESULT STS SIMILAR STS TIMEOUT STS ERROR CMD ERASE SD e 65h Erase training of SD SV command 1 Group index 0 trigger 1 15 generic 16 password 2 Command position 0 31 Expected replies STS SUCCESS 26 EasyVR 2 0 User Manual 3 6 6 VeeaR CMD NAME SD n 6Eh Label SD SV command 1 Group index 0 trigger 1 15 generic 16 password 2 Command position 0 31 3 Length of label 0 31 4 n Text for label ASCII characters from A oi Expected replies STS SUCCESS CMD COUNT SD CG 63h Request count of SD SV commands in the specified group
61. port Please feel free to contact us with any questions queries or suggestions If your question is about technical support or troubleshooting for one of our products we kindly ask you to first check our FAQ for a possible solution http www veear eu If you cannot find an existing solution on the FAQ please contact us using the contact form on our website at www veear eu The more detail you provide the better support we can give VeeaR TIGAL KG all right reserved l ai Tim All VeeaR branded boards and software are manufactured by TIGAL KG Made in Austria TIGAL KG assumes no responsibility for any errors which may appear in this manual Furthermore TIGAL KG reserves the right to alter the hardware software and or specifications detailed herein at any time without notice and does not make any commitment to update the information contained herein TIGAL KG products are not authorized for use as critical components in life support devices or systems User Manual 3 6 6 EasyVR 2 0 65
62. ransfer can be used to reduce it to 115200 for better compatibility with slower serial adapters One adapter that can go to full speed is the EasyVR DevBoard or the SmartVR DevBoard Otherwise any USB Serial adapter with TTL CMOS interface can be used for updating the flash The EasyVR Shield can be used for the download provided that the jumper J12 is in UP position Note Every download will overwrite the previously transferred custom data After the download completes a new connection can be established with the EasyVR module in normal mode and the new sounds will be displayed by the EasyVR Commander in the special group SoundTable the last one in the list with a yellow icon They can be played back and tested using the Play Sound command on the toolbar or in the Tools menu See also how to do that in your application in the code example Use custom sound playback Custom grammars will be displayed just after the built in word sets and they work exactly the same way Trigger words when specified will have their own vocabulary with only one entry You can test and use the custom trigger and command grammars as you do with the built in ones Note The built in trigger word set is handled in a special way as it is active also when recognizing from the first user defined command group This is the only case where SD and SI commands are mixed together and does not apply to custom trigger vocabularies Arduino UNO and o
63. rasmitted token token is the index of the SonicNet token to play 0 255 for 8 bit tokens or 0 15 for 4 bit tokens 1 28090 is the time in milliseconds at which to send the token since the beginning of the next sound playback Return values if the operation is successful Note The scheduled token remains valid for one operation only so you have to call playSound or playSoundAsync immediately after this function void playSoundAsync int16 t index int8 t volume Starts playback of a sound from the sound table Manually check for completion with hasFinished Parameters is the index of the target sound in the sound table 0 31 may be one of the values in SoundVolume Note The module is busy until playback completes and it cannot accept other commands You can interrupt playback with stop bool playSound int16_t index int8 f volume Plays a sound from the sound table and waits for completion Parameters index is the index of the target sound in the sound table volume 0 31 may be one of the values in Sound Volume eu di GA S S D c 0 o true if the operation is successful Note To alter the maximum time for the wait define the EASYVR PLAY TIMEOUT macro before including the EasyVH library 52 EasyVR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu bool dumpSoundTable char name int16_t amp count Hetrieves the name of the sound table and the number of sounds it contains
64. ression formats supported by the EasyVR module from highest to lowest compression rate Compression Scheme Available Time 8kHz 15 silence Available Time 9 3kHz 15 silence SX 2 8 7 minutes 7 5 minutes SX 3 7 6 minutes 6 6 minutes SX 4 6 8 minutes 5 9 minutes SX 5 6 1 minutes 5 2 minutes SX 6 5 6 minutes 4 8 minutes 4 bit ADPCM 87 seconds NA 8 bit PCM Ap seconds 38 seconds 60 EasyVR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu For audio file containing speech the SX 3 compression is usually a good choice If you need higher quality try lower compression rates Please note that due to the sampling rate used the audio files cannot contain very high frequencies less than half the sampling rate QS Sensory QuickSynthesis 5 DEMOSNDS QXP fo File Edit View Compress Play Build Tools Help Music Lipsync Target ASC4 el AA Bar Xm s EB VHP i Project Description E accor 398 D Project DemoSounds qxp S16 bytes Release 0 0 Created 10 10 2010 O54 4 4 7 _baing _ boing way _burp _ burp way Bar bytes calling whistle calling whistle way ZU bytes clock clack wav HAT bytes euplosion _ explosion wav 2833 bytes gang gang way 1065 bytes har Ion hank hom tau hank wav TIa bytes klason _klason wav 1124 bytes _photo_shutter _photo_ shutter way 269 bytes whistle _ whistle way BS bytes wolt whistle wolt whistle waw 341 bytes Sound Comment ahooga L QuickSynthesis 5 5
65. s ccccccccccccecseesssecceeeeeeeeeeeeceeeeessaaeeeeeeeeeeeesseeeseeeeeeeessaaaeeeeeees 20 Jumper SENINI qe UR RT 20 LEDO 20 Quick start guide for using the Shield eee eee eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeseeeeeeeceeseeeeeeseeeeess 21 de Beete e ue PP 21 With Arguino 2009 Dno Mega MT 21 rc ds Programming etc S nEEEnEtX R 23 SSMN PCO CON MN rm 23 Jet dee Lee WEE 23 ee leen Nappi M T H 24 C mmand Detalls mI E 25 IS ID STAM EAE 30 Communication Examples ccccccccsseseeeceeeeeceaeeeseeceeeeeceaeeeseeceeeesssaeaeeeeeeeeeeseesaseeceeeesssaeeseeceeeeessaaaaeeseeeees 33 Recommended wake up Drocechure 33 Recommended setup procedure enne nennen nnne nnnan nnn nennt nnne ss na sensns sna a ann ssi nans 33 Recognition of a built in or custom SI commande 34 elei te E Wa ER Ee ite un ne EE 34 Training an SD command WE 35 Recognition of an SD commande 35 Read how many commands in a group 36 Read a user defined command group 36 Use general purpose I O poms nennen nennen nnn n nnns nnna rni nnns sna n agar nnn rens n aa 37 Use custom sound polavback nennen nnne nnne nnns nnna nnn ness na aan n nnns naga n nnns nnns 37 2 EasyVR 2 0 User Manual 3 6 6 Y
66. s not explicitly handled for simple commands but should be always implemented if possible Also the OK and ERROR routines are not explicitly defined since they are host and programming language dependent but appropriate code should be written to handle both conditions Lines beginning with a sharp character are comments Please note that in a real programming language it would be best to define some constants for the command and status characters as well as for mapping numeric arguments that would be used throughout the program to minimize the chance of repetition errors and clarify the meaning of the code See the Protocol header file for sample definitions that can be used in a C language environment Here below all the characters sent and received are written explicitly in order to clarify the communication protocol detailed in the previous sections Recommended wake up procedure wake up or interrupt recognition or do nothing uses a timeout or max repetition count DO EXE DUIS LOOP UNTIL RECEIVE o Recommended setup procedure deccm eie SENDE IF NOT RECEIVE x THEN ERROR send ack and read status expecting id 0 e EE id RECEIVE IF id A THEN tait s a VRbOtC ELSE IF id B THEN it s an EasyVR ELSE next generation END IF set language for SI recognition Japanese uS TE SENDERE MARE C EE t set timeout 5 seconds SEND EO SEND F IF RECEIVE o THEN OK ELSE ERROR
67. sitive values that form a 10 bit index to the sound table index 1 32 2 0 built in beep 1 1023 sound index 3 Playback volume 0 31 0 min volume 15 full scale 31 double gain Expected replies STS SUCCESS STS ERROR 1 2 CMD PLAY DTMF w 77h Play a DTMF key tone or dial tone 1 Fixed to 1 2 Index of phone tone to play 0 9 for digits 10 for key 11 for key and 12 15 for extra keys A to D 1 for the dial tone 3 Tone duration minus 1 0 31 in 40ms units for keys in seconds for the dial tone Expected replies STS SUCCESS CMD DUMP SX h 68h Read wave table data Expected replies GIG TABLE SX STS OUT OF MEM CMD DUMP SI h 68h Read custom and built in grammars data 1 Index of SI grammar to read 0 31 or 1 to get the total count of SI grammars including the first 4 built in wordsets Expected replies GIG GRAMMAR STS COUNT 28 EasyVR 2 0 User Manual 3 6 6 Y MMN VeeaR WWW Veear eu CMD SEND SN h 68h Send a SonicNet token 1 Length of token 4 or 8 in bits 2 3 Two positive values that form an 8 bit token index index 2 32 3 0 15 for 4 bit tokens or 0 255 for 8 bits tokens 4 5 Two positive values that form a 10 bit delay for token output since the next sound playback delay 4 32 5 0 send immediately 1 1023 delay in units of 27 46ms Expected replies STS SUCCESS CMD RECV SN h 68h Receive
68. tarted 1 Install drivers via double click EasyVR DevKit Setup exe 2 f your Install succeeded you will see a new Virtual COM Port in your Device manager as soon as you connect the USB cable to the EasyVR Devkit J Ports COM amp LPT 2 EN Communications Port COMI ad 3 EasyVR Devkit COM26 The exact COM port number may vary 3 Now start the EasyVR Commander Software 4 Choose advised COM Port and click connect 5 Then enjoy your EasyVR Hardware Interfaces Connector J1 is a screw terminals block for differential audio output can directly drive an 8Q speaker Connector J6 is the audio input interface for connecting the microphone provided with the EasyVR module Connector J5 on the DevKit board replicate the GPIOs available on the EasyVR as follows Connector Pin Name Typ Description 13 GND Ground J5 02 ni 0 General purpose I O 3 0 VDC TTL level DevKit 3 102 VO General purpose I O 3 0 VDC TTL level A 108 General purpose I O 3 0 VDC TTL level There is also an indication LED connected to IO1 to display status which is handled for example by the EasyVR Commander to show the module is listening User Manual 3 6 6 EasyVR 2 0 13 Y MN WWW Veear eu VeeaR EasyVR on Arduino You can connect the EasyVR module to an Arduino board basically in two ways 1 Bridge mode You can control the module using a software serial library and connect to the module with th
69. the module is back to ready int8 f getID d Gets the module identification number firmware version Return values is one of the values in Moduleld User Manual 3 6 6 EasyVR 2 0 45 WWW Veear eu bool setLanguage int8 f lang Sets the language to use for recognition of built in words Parameters 0 5 is one of values in Language Return values true if the operation is successful bool setTimeout int8 t seconds Sets the timeout to use for any recognition task Parameters seconds 0 31 is the maximum time the module keep listening for a word or a command Return values true if the operation is successful bool setKnob int8 t knob Sets the confidence threshold to use for recognition of built in words Parameters knob 0 4 is one of values in Knob Return values true if the operation is successful bool setLevel int8 t level Sets the strictness level to use for recognition of custom commands Parameters level 1 5 is one of values in Level Return values true if the operation is successful bool setDelay uint16 t millis 46 Sets the delay before any reply of the module Parameters millis 0 1000 is the delay duration in milliseconds rounded to 10 units in range 10 100 and to 100 units in range 100 1000 Return values if the operation is successful VeeaR EasyVR 2 0 User Manual 3 6 6 Y N VeeaR WWW Veear eu bool changeBaudrate int8 t
70. the sketch for usage details Keep in mind that if you have a bridge code running all examples do on Arduino you can connect the EasyVR Commander leaving the jumper in the SW position just make sure the monitor window is closed When the EasyVR Commander is connected you can also generate a template code for Arduino that will use the provided libraries see EasyVR Arduino Library Documentation All you need is to write actions for each recognized command 22 EasyVR 2 0 User Manual 3 6 6 v N VeeaR www veear eu EasyVR Programming Communication Protocol Introduction Communication with the EasyVR module uses a standard UART interface compatible with 3 3 5V TTL CMOS logical levels according to the powering voltage VCC A typical connection to an MCU based host EasyVR Host MCU 3 3V 5V GND TX RX The initial configuration at power on is 9600 baud 8 bit data No parity 1 bit stop The baud rate can be changed later to operate in the range 9600 115200 baud The communication protocol only uses printable ASCII characters which can be divided in two main groups e Command and status characters respectively on the TX and RX lines chosen among lower case letters e Command arguments or status details again on the TX and RX lines spanning the range of capital letters Each command sent on the TX line with zero or more additional argument bytes receives an answer on the RX line in the form of a sta
71. ther boards with USB Serial adapter based on ATMEGA8U2 need the option Slow transfer enabled User Manual 3 6 6 EasyVR 2 0 63 D AN WWW Veear eu VeeaR Updating Firmware The EasyVR firmware can be updated in a similar way to custom data by using the command Update Firmware from the Help menu Note that you must first disconnect from the module and do the steps required to start it in boot mode see the section Flash Update The specified file will be verified as an official firmware release and basic version information will be displayed If the firmware passes the verification step then the Download button will be enabled Update Firmware di Updating firmware XL Set transfer options and download Project enami Import Remove EASYVR FW REV2 C Program Files VeeaR y Move Up Move Down Open Externally Index Label Refresh C OK Firmware Version 2 Slow Transfer Figure 12 Interface for updating EasyVR firmware Note After a new firmware is downloaded to the module the custom data already present is erased and it must be downloaded again if necessary Troubleshooting Downloading custom data or update fails 1 Double check your settings COM Port selection Jumper position 2 Try to enable the option Slow transfer 3 Use an USB to TTL adapter connected directly to the EasyVR module 64 EasyVR 2 0 User Manual 3 6 6 VeeaR www veear eu How to get sup
72. tus byte followed by zero or more arguments There is a minimum delay before each byte sent out from the EasyVR module to the RX line that is initially set to 20 ms and can be selected later in the ranges 0 9 ms 10 90 ms and 100 ms 1 s That accounts for slower or faster host systems and therefore suitable also for software based serial communication bit banging Since the EasyVR serial interface also is software based a very short delay might be needed before transmitting a character to the module especially if the host is very fast to allow the EasyVH to get back listening to a new character The communication is host driven and each byte of the reply to a command has to be acknowledged by the host to receive additional status data using the space character The reply is aborted if any other character is received and so there is no need to read all the bytes of a reply if not required Invalid combinations of commands or arguments are signaled by a specific status byte that the host should be prepared to receive if the communication fails Also a reasonable timeout should be used to recover from unexpected failures If the host does not send all the required arguments of a command the command is ignored by the module without further notification and the host can start sending another command The module automatically goes to lowest power sleep mode after power on To initiate communication send any character to wake up the m
73. urpose VO BOVDC TTL iewe 5 3 IO General purpose VO B0 VDC TTL iewe Note the GPIO J4 3 J4 4 and J4 5 are at nominal 3 0VDC level Do not connect 5VDC directly to these pins 6 EasyVR 2 0 User Manual 3 6 6 Y N VeeaR www veear eu Recommended Operating Conditions wc Voltage DC Input i Ambient Operating Temperature Range Serial Port Receive Data e Serial Port Transmit Data Electrical Characteristics These are applicable to J4 pins only including 101 3 XM and RST symbol rum wm SE NE av OW mula 91 00 ns vu i mwissemtrerorv cS RIma s 9 m Meme e a Weak 0 0 20 0 Wen EN Ve Output High Voltage loi 5 mA Output Low Voltage loi 8 mA Power Supply Requirements Audio playback current with 80 speaker mE Serial Interface The EasyVR is a slave module communicating via an asynchronous serial interface commonly known as UART interface with the following features e Baud Rate 9600 default 19200 38700 57600 115200 e Frame 8 Data bits No parity 1 Stop bit The receiver input data line is ERX while the transmitter output data line is ETX No handshake lines are used Example of a serial data frame representing character A decimal 65 or hexadecimal 41 Stop Idle OV See also chapter Communication Protocol later on this manual for communication details User Manual 3 6 6 EasyVR 2 0 7 Y N WWW Veear eu
Download Pdf Manuals
Related Search
Related Contents
960H SNAP-IT Outdoor Dome Camera Amana ND-1 User's Manual MPE 750 Turbo Marine - Closed Loop 2015 Nissan NCG2Kai2 (Murano) Navigation Book CAN - EZ - Technische Alternative Life Fitness T Series User's Manual Guide des formations 6 - Forth User Manual Transmitter Module PTM 33x / PTM 33xC Jabra JX20 Pura Copyright © All rights reserved.
Failed to retrieve file