New BricxCC and NBC/NXC release

Discussion specific to NXT-G, NXC, NBC, RobotC, Lejos, and more.
afanofosc
Site Admin
Posts: 1256
Joined: 26 Sep 2010, 19:36
Location: Nashville, TN
Contact:

Re: New BricxCC and NBC/NXC release

Post by afanofosc »

The only thing I changed was NXCDefs.h and NXTDefs.h and rebuilt the compiler for all platforms and BricxCC for Windows and the installer package. There were no changes to the templates in the repost of this release.

John Hansen
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
afanofosc
Site Admin
Posts: 1256
Joined: 26 Sep 2010, 19:36
Location: Nashville, TN
Contact:

Re: New BricxCC and NBC/NXC release

Post by afanofosc »

doc-helmut wrote:maybe you wish to try this test:

Code: Select all

task main(){

float  x = atof( "4.2e1is_the_answer" );
  NumOut(0,0,x);
  while (true);
}
;)
Are you saying that the behavior with this release is a regression? It is producing the correct value (42) in my testing.

John Hansen
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
mattallen37
Posts: 1818
Joined: 02 Oct 2010, 02:19
Location: Michigan USA
Contact:

Re: New BricxCC and NBC/NXC release

Post by mattallen37 »

Okay, thanks. I didn't figure so, but I also didn't want to be missing one or two templates.

Thanks a bunch for all the new features :D Now, I just need to try them all ;)
Matt
http://mattallen37.wordpress.com/

I'm all for gun control... that's why I use both hands when shooting ;)
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: New BricxCC and NBC/NXC release

Post by HaWe »

afanofosc wrote:
doc-helmut wrote:maybe you wish to try this test:

Code: Select all

task main(){

  float  x = atof( "4.2e1is_the_answer" );
  NumOut(0,0,x);
  while (true);
}
;)
Are you saying that the behavior with this release is a regression? It is producing the correct value (42) in my testing.

John Hansen
no it's all fine, all is working correctly as I expected with this test code (just for mattallen because his compiling didn't work - although mine did it)

only 1 thing I'm missing: the tetrix drivers :(
mattallen37
Posts: 1818
Joined: 02 Oct 2010, 02:19
Location: Michigan USA
Contact:

Re: New BricxCC and NBC/NXC release

Post by mattallen37 »

What are the valid numbers you can pass into "PosRegSetMax (, , );"? I know the first byte is to set the motor ports (for example, OUT_A). The second is for speed, and the third is for acceleration. What are the valid parameters for these? Is speed 0-100? 0-255? 1-n? Thanks
Matt
http://mattallen37.wordpress.com/

I'm all for gun control... that's why I use both hands when shooting ;)
mattallen37
Posts: 1818
Joined: 02 Oct 2010, 02:19
Location: Michigan USA
Contact:

Re: New BricxCC and NBC/NXC release

Post by mattallen37 »

doc-helmut wrote:...just for mattallen because his compiling didn't work - although mine did it...
It does compile now that I have the new release :)
Matt
http://mattallen37.wordpress.com/

I'm all for gun control... that's why I use both hands when shooting ;)
afanofosc
Site Admin
Posts: 1256
Joined: 26 Sep 2010, 19:36
Location: Nashville, TN
Contact:

Re: New BricxCC and NBC/NXC release

Post by afanofosc »

Sadly, I am not an expert on the new PosReg stuff. The default values are

Code: Select all

#define DEFAULT_MAX_SPEED        80
#define DEFAULT_MAX_ACCELERATION 20
0 means no limit. The default regulation time is 100ms rather than 10ms. There was quite a bit of oscillation at the regulated position with 100ms as the regulation time. If I changed it to 10ms it stopped very smoothly at the new position.

John Hansen
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
nxtreme
Posts: 246
Joined: 29 Sep 2010, 03:53
Location: 192.168.1.2

Re: New BricxCC and NBC/NXC release

Post by nxtreme »

Wow, I may just have to download BricxCC and start learning NXC! As has probably been obvious from my lack of posts the last while, I've been busy. But, it will happen sometime :P (yes Matt, it will happen). Thank you for your continued support of the Mindstorms community, Mr. Hansen. It's people like you that make this hobby worthwhile!
One King to rule them all, One King to find them,
One King to bring them all and in the darkness bind them
On Earth where Shadows lie.
mattallen37
Posts: 1818
Joined: 02 Oct 2010, 02:19
Location: Michigan USA
Contact:

Re: New BricxCC and NBC/NXC release

Post by mattallen37 »

Ok. Previously, I always used 0,0 (no limits).

As far as the regulation time, how do I adjust that? I see these functions:

Code: Select all

MotorRegulationTime()
MotorRegulationOptions()
I assume these have to do with it, but I am not sure how to use them.
Matt
http://mattallen37.wordpress.com/

I'm all for gun control... that's why I use both hands when shooting ;)
mattallen37
Posts: 1818
Joined: 02 Oct 2010, 02:19
Location: Michigan USA
Contact:

Re: New BricxCC and NBC/NXC release

Post by mattallen37 »

nxtreme wrote:Wow, I may just have to download BricxCC and start learning NXC! As has probably been obvious from my lack of posts the last while, I've been busy. But, it will happen sometime :P (yes Matt, it will happen). Thank you for your continued support of the Mindstorms community, Mr. Hansen. It's people like you that make this hobby worthwhile!
Yes, you MUST :lol:

I agree, Thank you very much John!
Matt
http://mattallen37.wordpress.com/

I'm all for gun control... that's why I use both hands when shooting ;)
Post Reply

Who is online

Users browsing this forum: Semrush [Bot] and 1 guest