Putting robotics at your service™

Free shipping on orders over $200

Basic Micro Studio - Changes in Beta from Build to build

Print view Share :
Previous topicNext topic

Page 6 of 9 [ 121 posts ]

1 ... 3, 4, 5, 6, 7, 8, 9
User avatar
Guru ( offline )
Posts: 4913
Posted: 2010-09-21 10:48 
Quick update: new hserial syntax, but not sure of all of it yet.

enablehserial - command goes away...

sethserial - Does not appear to be the command any more not sure what the replacement is...

Kurt


User avatar
Guru ( offline )
Posts: 2120
Posted: 2010-09-21 13:36 
Thanks for the info! Looks like there are some changes to be done on the Archer (Phoenix) code for the ARC-32 then.
Sounds like a good idea planning for eventual future processors.

_________________
Kåre Halvorsen, Zenta
-----------------------------------------
Zenta's blog
http://zentasrobots.com/
Zenta's YouTube channel
http://www.youtube.com/ZentaOlbaid
-----------------------------------------


User avatar
Guru ( offline )
Posts: 4913
Posted: 2010-09-22 09:49 
OK I received some email from Nathan last night.

The new build has the new HSERIAL system as I pretty well knew...
AcidTech wrote:
The new manual will have this documented. But hserial2 no longer exists. ENABLEHSERIAL etc are all gone. Still have SetHSerial2 command. If SetHSerial2 is used then the second UART will be enabled. Also SetHSerial is now SetHSerial1. This was supposed to be documented in the new manual before this release was made but I was pushed to get the release out.

So hserin and hserout have a new optional argument. If only SetHserial1 or SetHSerial2 is used it automatically uses the correct UART. If both are used there is an optional argument to specify uart1 or uart2. hserin 1,[blah,blah] hserin 2,[blah,blah].. Also on hserin the timeout and timeout label are reversed from previous versions. hserin tlabel,timeout. This was done because otherwise the uart argument could not be optional.

With this knowledge I am now able to get the Arc32 version of the phoenix code to compile again. Have not run it yet...

Kurt


User avatar
Expert ( offline )
Posts: 628
Posted: 2010-09-27 12:55 
Just so everyone knows the new hserial syntax is all Kurtes fault. He convinced Dale we needed it. :)

_________________
Basicmicro


User avatar
Guru ( offline )
Posts: 9257
Posted: 2010-09-27 13:13 
Acidtech wrote:
Just so everyone knows the new hserial syntax is all Kurtes fault. He convinced Dale we needed it. :)


Bwwwwaaaa haaaaa haaaaa haaaaaa! :shock:

_________________
Jim Frye, the Robot Guy
http://www.lynxmotion.com
I've always tried to do my best...


User avatar
Guru ( offline )
Posts: 4913
Posted: 2010-09-27 13:20 
Hi Guys, I wish I could take full credit for it :? , but the changes actually started by Dale. Here is the first message talking about it in in the New Manual posting (page 5) on the Basic Micro forum.
Quote:
Kurt,

Im on the HSERIN, HSEROUT, HSERIN2 and HSEROUT2. Its a mess to say the least. The ARC32 and ATOMPro 40 are to become the dominant platforms for Basic Micro. So I need to make these commands much simpler. We are going to break them. I did a search on Jim's forums and it seems theres only a handful of people using them. The changes I'm about to make wont break the functionality so all the things you asked Nathan for will remain intact. I just need to make it simpler for the average user.

All the changes will be documented in the new manual and the release text file.


Now I fully admit that after that I suggested, it would sure be nice if there was not HSEROUT and HSEROUT2... So personally I am happy with these changed :)


User avatar
Guru ( offline )
Posts: 4913
Posted: 2010-10-12 16:20 
This is just an FYI - Nathan had not put in the new format of the hserstat command in the previous postings. I emailed him awhile ago about the new format and thought I should share the information.

AcidTech wrote:
HSERSTAT mode arguments now include the choice of uart 1 or uart 2.

modes 0 to 7 are the same as before but are specifically for uart1. Then 8 to 15 are the same modes but for uart 2.

As HserStat was not in some of the previous manuals, Here is the information I had on it...
Quote:
The HSERSTAT command lets you check the status and/or clear the hardware serial port buffers. Before using this command you must use the SETHSERIAL command (see page 122) to set the correct baud rate.
Syntax
hserstat funct{,label}
funct is a value from 0 to 6 that determines the function of the hserstat command according to the following list:
Value Function
0 Clear input buffer
1 Clear output buffer
2 Clear both buffers
3 If input data is available go to label
4 If input data is not available go to label
5 If output data is being sent go to label
6 If output data is not being sent go to label
label is an optional argument (use with values 3 – 6) that specifies the destination jump address.


Kurt


User avatar
Guru ( offline )
Posts: 4124
Posted: 2010-10-12 20:50 
What's the cut-in release version for ENABLEHSERIAL going away, and the new Hserial 1, etc. to be available?

Thanks!

Alan KM6VV

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


User avatar
Guru ( offline )
Posts: 4913
Posted: 2010-10-12 20:54 
KM6VV wrote:
What's the cut-in release version for ENABLEHSERIAL going away, and the new Hserial 1, etc. to be available?

1.0.0.36 which was then changed to 2.0.0.0

Kurt


User avatar
Guru ( offline )
Posts: 4124
Posted: 2010-10-12 21:01 
That was fast. Thanks!

It's amazing how many programs I have lost recently due to switching between projects. I had a BBII or the ARC-32 running on my Micromouse 'bot, then I went to work on the 'quad. I'm still not sure which board I was working with (maybe the BasicAtomPro?) but it took quite a while to get rover code working again on the ARC32 with the RoboClaw.

It might have helped if I'd had the PS2 connected; the code stalls just before I was trying to ferret out the right serout vs. hserout statement right after that in Init. Oh well!

My Micromoose should work for a rover (Lantronix project).

I need to take better notes!

Alan KM6VV

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


User avatar
Expert ( offline )
Posts: 628
Posted: 2010-10-13 14:05 
The 2.0 change was because we just added the new library system which will be a fairly major addition. If anyone wants to submit their own projects for the library please send them to nathan@basicmicro.com.

The 2.0 release is when teh ENABLEHSERIAL/HSERVO compile time directives have need removed(wont break your code though if you leave them in) and the new HSERIAL syntax is available(whill break your old code, need to change the hserin,hserout and SetHserial commands).

_________________
Basicmicro


User avatar
Guru ( offline )
Posts: 4124
Posted: 2010-10-13 14:26 
Just a thought, but what if we had a key word (reserved word) analyzer program (like LINT?) that we could run against a BAS file? Maybe we'd specify the rev and the compiler used, or it could just identify all the reserved words, and comment on which revs/compilers the commands/words could be used by.

Get the picture? I dig up an old file (or even a new one I'm working on), run BM-LINT against it, and it tells me where the "evolving" words are, and identifies which compilers can compile the file. Or maybe which words are "wrong" for the compiler I want to use. Could even suggest the command and it's proper syntax. Seems like the new studio (only had a short time to try it out last night) does some of that. Clever!

Alan KM6VV

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


User avatar
Guru ( offline )
Posts: 4124
Posted: 2010-10-13 15:36 
Since I'm here...

Just changed code in "Rover Roboclaw" program from old format to new for the 2.0 compiler.

Compiles for 'Pro, not for Basic Atom. Compile never ends (although I can get into editor). Must exit Studio and restart.

Code:
ENABLEHSERIAL
;SetHSerial H9600,H8DATABITS,HNOPARITY,H1STOPBITS   ; pre 2.0
;hserout ["Creepy RoboCrawler",cr,lf]     

SetHSerial1 H9600,H8DATABITS,HNOPARITY,H1STOPBITS   ; 2.0 syntax
hserout 1,["Creepy RoboCrawler",cr,lf] 


Alan KM6VV

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


User avatar
Guru ( offline )
Posts: 4913
Posted: 2010-10-13 15:41 
Hi Alan,

I think I read that for the Nano and maybe the Atom, the only valid thing is the baud rate.

Try:
Code:
SetHSerial1 H9600
hserout 1,["Creepy RoboCrawler",cr,lf] 

Note: This should work on the Pro as well as all of the others are optional...
Kurt


User avatar
Guru ( offline )
Posts: 4124
Posted: 2010-10-13 15:53 
Hi Kurt,

Nope!

Still fails to complete the compile, no error messages.

For some reason, I had the BBII with the BasicAtom bolted up on the 'bot, so tried a compile for that. I should probably get more 'PRO and ARC-32's; but I like the old PIC parts!

Alan KM6VV

kurte wrote:
Hi Alan,

I think I read that for the Nano and maybe the Atom, the only valid thing is the baud rate.

Try:
Code:
SetHSerial1 H9600
hserout 1,["Creepy RoboCrawler",cr,lf] 

Note: This should work on the Pro as well as all of the others are optional...
Kurt

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


1 ... 3, 4, 5, 6, 7, 8, 9

All times are UTC - 5 hours [ DST ]. It is currently 2014-10-21 09:28
Feedback Form
Feedback Form