BasicMicroUK - Forums

www.basicmicro.co.uk
It is currently Sat Jan 20, 2018 7:57 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: easyVr code not working. Help GREATLY appreciated.
PostPosted: Mon Feb 06, 2012 5:01 pm 
Offline
Citizen

Joined: Fri Jun 24, 2011 2:29 am
Posts: 27
Hello: I have lost way to much hair trying to get easyvr to work with the basic atom 24. I am trying to play the built in beep sound and cannot get this to work. I suspect timing problems, or not sending and receiving characters properly. The atom now uses microsecond precision, so I presume I have the timeout setting correct at 20000 but I am not even sure about this.
I am not sure if I am receiving and sending ascii characters with the serial commands either. Finally, I will need a bridge program between the atom and the easyVR. It is supposed to be a simple serial transfer program, but... I cant even find a parallax example. The code is automatically downloaded into the stamps from the easyVr software, so I cannot even view it as an example :(
I would GREATLY appreciate some assistance, I have been going bald for way to long with this problem. I am attaching the entire test program I have written, and apologize for the length.

-stampee
-------------------


Attachments:
File comment: vr_sound_test program
vr_sound_test.bas [4.25 KiB]
Downloaded 347 times
Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Mon Feb 06, 2012 6:03 pm 
Offline
Master

Joined: Tue Nov 21, 2006 5:34 pm
Posts: 662
I don't have this hardware so can not help much. One thing I noticed is that your serouts to the device are using the baud mode of 9600, which is probably not correct. It should probably be either n9600 or i9600 (like you do outputting do IO port 1). The baud mode is not simply a baud rate, but instead it has the baud rate encoded into it. You can encode your own rates, but it is much easier to use the predefined ones like I mentioned.

Good Luck
Kurt


Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Tue Feb 07, 2012 1:30 pm 
Offline
Citizen

Joined: Fri Jun 24, 2011 2:29 am
Posts: 27
Kurt: Thank you. I will try that. yes i do have i9600 for my lcd, but I thought just writing 9600 was defaulted to the n9600. I will do as you suggested, I wound up being very busy at work, so will try this in the next few days. and repost how I made out.
-Stampee


Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Wed Feb 08, 2012 4:47 am 
Offline
Citizen

Joined: Fri Jun 24, 2011 2:29 am
Posts: 27
Kurt: I tried the n9600 to no avail. the code hangs in the vr_wakup unless I comment out the line to bypass the wait. I set my lcd to show the value of vra and it comes back 0 so something is wrong.
Oh well, thank you for the help. I uploaded my latest version for what it is worth.
-Stampee


Attachments:
File comment: vr_sound_test
vr_sound_test.bas [4.31 KiB]
Downloaded 324 times
Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Wed Feb 08, 2012 4:56 am 
Offline
Site Admin
User avatar

Joined: Thu Mar 01, 2001 7:00 pm
Posts: 1316
Location: Temecula, CA
Just to be clear, i9600 and n9600 are predefined constants. There actual values are not 9600. (600 is a number. If you use it for the baudmode you will not get 9600bps communications. The baudmode format is documented in the manual. If you want to define your own baud mode you need to follow that. Most people just use the predefined constants. If you haven't tried i9600 where you tried n9600 yet then you should.

_________________
Tech Support
Basic Micro - Robotic Technology Evolved


Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Thu Feb 09, 2012 2:21 am 
Offline
Citizen

Joined: Fri Jun 24, 2011 2:29 am
Posts: 27
Nathan: I do not understand what you are saying. I am using n9600 which is listed in the manual as a standard baud mode. Why do you say I am redefining my own baud mode? I use i9600 for my serial lcd display and that works properly.
According to the easyVR manual they state the following "The initial configuration at power on is 9600 baud, 8 bit data, No parity, 1 bit stop. "

How would I send at the easyVR rate of n9600 if I do not enter n9600? All of your example codes in the manual use i9600 what do I have to do than to send n9600?
Thank you for clarification on this.
-Stampee


Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Thu Feb 09, 2012 4:25 am 
Offline
Citizen

Joined: Fri Jun 24, 2011 2:29 am
Posts: 27
Nathan: I have it working at i9600, I just cant find why I thought it had to be n9600 communications. You may delete my last post if you wish. I still have other problems, but I think the easyvr manual is incorrect now on a sound problem and I shall deal with them.
Thank you very very much for your assistance.
-Stampee


Top
 Profile  
 
 Post subject: Re: easyVr code not working. Help GREATLY appreciated.
PostPosted: Tue Feb 14, 2012 6:03 pm 
Offline
Site Admin
User avatar

Joined: Thu Mar 01, 2001 7:00 pm
Posts: 1316
Location: Temecula, CA
I was talking about the "9600" Lurt said you originally had for the baudmode. Yes you definitely want to use "n9600" or "i9600" I was trying to explain the "9600" is not 9600bps.

Glad you got it working. Let us know if you need any more help.

_________________
Tech Support
Basic Micro - Robotic Technology Evolved


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

phpBB SEO