EV3 BCC / C software problem(s)

Discussion specific to NXT-G, NXC, NBC, RobotC, Lejos, and more.
totokan
Posts: 45
Joined: 28 Sep 2013, 04:22

Re: EV3 BCC / C software problem(s)

Post by totokan »

You need to understand makefiles to understand your problem, I think. The only thing bricxCC is going to do is generate the makefile, and you have to add the stuff you want to that generated makefile (or the generation template, which is under edit>preferences>compiler>ev3)
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: EV3 BCC / C software problem(s)

Post by HaWe »

I need a guidance for idiots, I have no idea how make file works.

I just press ctrl+F5, and my program is expected to run on the brick.
That's why I have been using BCC and NQC/NXC so far, and so did my Borland C++.

(but actually most BCC users which I know have the same elaborated skills like me)
4) where and how can I induce BCC to compile and link with -pthread ?

so 4) is left...
Last edited by HaWe on 25 Oct 2013, 16:06, edited 1 time in total.
totokan
Posts: 45
Joined: 28 Sep 2013, 04:22

Re: EV3 BCC / C software problem(s)

Post by totokan »

I think if you can understand how pthreads work you can understand how a makefile works. Luckily, everything in GNU/linux world has a manual! http://www.gnu.org/software/make/manual/make.html
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: EV3 BCC / C software problem(s)

Post by HaWe »

4) where and how can I induce BCC to compile and link with -pthread ?

so 4) is left...
even Xander don't know the answer...
pepijndevos
Posts: 175
Joined: 28 Dec 2011, 13:07
Location: Gelderland, Netherlands
Contact:

Re: EV3 BCC / C software problem(s)

Post by pepijndevos »

As people already said:

The only way is to modify the makefile. Just add the effing flag to the file.

Threads are hard to use correctly. You would be better of using a single loop to control the screen and the motors.

The EV3 C stack is very much alpha, so IMO you should not use it if you don't want to touch a terminal or makefiles.

If you insist on using threads for doing what you want to do, I suggest buying a few books about Linux and C. Also, copious amounts of mutexes on any shared state. But better still is no shared state at all.
-- Pepijn
http://studl.es Mindstorms Building Instructions
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: EV3 BCC / C software problem(s)

Post by HaWe »

I already have some books about C but I surely won't buy books about Linux.
I am only working with Windows crosscompilers, the targeting ev3 Linux issues have to be handled by the compiler's IDE completely. Finally also the NXT fw details or bytecode compiler or interpreter or SDK or HDK stuff never ever had to affect me.
modify the makefile..add the effing flag to the file
yes, but how to modify it by BCC?
what means "add the effing flag to the file" ?
what flag? what file?
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: EV3 BCC / C software problem(s)

Post by HaWe »

to make it clear once more, you (and some more dudes over here) are supposed to be a professional programmer and used to use Linux, but you are talking to me as a hobby-programmer who is just using letters instead of icons for programming the bricks.

It's like if I as a professional physician and pharmacist told you how to make a Whipple operation (pancreaticoduodenectomy) or a HPTLC (high-performance thin-layer chromatography) or a DNA sequencing acc. to Sanger. You might understand single words, but you would (probably) not be able to follow the instructions in detail, practically. It even would not help you if I told you "buy some books about surgery or pharmaceutical analytics or molecular biology".

This is exactly my problem by following your instructions.

See my point?
totokan
Posts: 45
Joined: 28 Sep 2013, 04:22

Re: EV3 BCC / C software problem(s)

Post by totokan »

doc-helmut wrote:to make it clear once more, you (and some more dudes over here) are supposed to be a professional programmer and used to use Linux, but you are talking to me as a hobby-programmer who is just using letters instead of icons for programming the bricks.

It's like if I as a professional physician and pharmacist told you how to make a Whipple operation (pancreaticoduodenectomy) or a HPTLC (high-performance thin-layer chromatography) or a DNA sequencing acc. to Sanger. You might understand single words, but you would (probably) not be able to follow the instructions in detail, practically. It even would not help you if I told you "buy some books about surgery or pharmaceutical analytics or molecular biology".

This is exactly my problem by following your instructions.

See my point?
If you can't follow the instructions on the level we've provided them, then you are incapable of properly utilizing the libraries you are asking about. If you don't know what a mutex is, you can't use threads, and if you are unwilling to get a book and learn these things, then there is nothing we can do to help you.
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: EV3 BCC / C software problem(s)

Post by HaWe »

you have not contributed any useful information about what I asked - maybe you have not read closely enough.
Smart-aleck wisecracking gets us nowhere.
And you don't need to citate my whole previous post before you reply, it simply fits if you just reply.
try it again:
4) where and how can I induce BCC to compile and link with -pthread ?

so 4) is left...
mightor
Site Admin
Posts: 1079
Joined: 25 Sep 2010, 15:02
Location: Rotterdam, Netherlands
Contact:

Re: EV3 BCC / C software problem(s)

Post by mightor »

Everyone,

Either answer the question being asked or just don't add to the thread.

So keep it relevant, or don't post, it's that simple.

= Xander
| My Blog: I'd Rather Be Building Robots (http://botbench.com)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests