Programming with Lejos-OSEK would require fairly intimate knowledge of interrupt handling and other low level programming tricks. I don't think that is your cup of tea, judging from previous conversations

I read sth about this some weeks ago as I was looking for some segway programs.But my English actually is not good enough, and so I still don't understand the software architecture, and also other things I didn't understand quite right.[EDIT:] actually - this really seems to be a C compiler ...

Quote:

nxtOSEK uses LEJOS NXJ low level device driver written in C/Assembly, but it is NOT another Java VM implementation for NXT. nxtOSEK is an RTOS(Real-Time Operating System) for LEGO MINDSTORMS NXT and user can write native application in ANSI C/C++ by using GCC tools.

But more important than this is:how big is the variable memory? (very important! 15k are much too poor!)how big are stack and heap? (heap: very important for dynamic memory allocation!)(indeed it got a stack: STACKSIZE = 512; /* Stack size */ used in a task control; but what is maximum variable stack?are fully recursive functions possible? (very important if different functions call each other)may the memory be extended by external memory, e.g. SD cards via I²C (maybe even RS485)? (very important e.g. maps for navigation, a-star...) and to the current dicussion: has it got a RS485 network protocol? (very important for RS485 Smux/Mmux remote access and co-calculation)(MT is featured as I found)

Those related imperfections are the reason why I'm looking for a "real C" compiler w/o any Lego firmware limitations. About this I still haven't found all the answers - could you plz help me with this?

hi,I just got some answers to my questions from the nxtOSEK developer:

Takashi Chikamasa <takashic@cybernet.co.jp> wrote:

Hi,

Thank you for your questions.I am trying to answer your questions with my best effort:

> how big is the variable memory / stack? (very important! 15k of RobotC are > much to poor!)nxtOSEK provides two ways of program execution.1. In case of using enhanced NXT standard firmwareIn this case, user available memory/stack is max. 64Kbytes.All user program (includes ROM/RAM memory) has to be less than 64Kbytes.If enhanced NXT stadard firmware was used for program download, userprogram has be executed from SRAM in the NXT. 2. In case of using NXT BIOSIn this case, user available memory/stack is as followsROM: max. 224KbytesRAM: max. 50KbytesNXT BIOS is a simple program bootloader, so user can use all most fullmemory space of ARM7 in the NXT.

> what is maximum variable heap? (very important for dynamic memory > allocation!)I haven't tested dynamic memory allocation features provided by GCC, butit should be OK up to the above resrictions.

> are fully recursive functions possible? (very important if different > functions call each other)No problem. GCC is a real C/C++ compiler and it has been used for millions of complex software (e.g. Linux) in the computer industory.GCC for NXT(ARM7) is essentially same as GCC which is used for Linux.I believer that you can write your program in C as you like.

> may the memory be extended by external memory, e.g. SD cards via I2C (or by > RS485)?> (very important e.g. maps for navigation, a-star...)> has it got a RS485 full or half duplex network protocol? (very important to > control "slave nxt's" by RS485 as sort of Smux/Mmux remote> access to and co-calculation maybe for navigation calculations or a neural > net runnung on 2-4 connected nxt's)Currently, nxtOSEK does not support RS-485 comm. and I haven'tinvestigated it. Sorry.

> how does I2C communication work for third party (e.g., POB-eye cam) or > homebrewed motor and sensor multiplexers?Yes. nxtOSEK supports various types of third party I2C sensors. (e.g.HiTechnic Accel, LATTEBOX NXTe...) and I2C API is also published.

> multitasking is elementary (but as I understood, it's actually featured by nxtOSEK)?Yes. nxtOSEK provides preemptive multitasking features. This is one of themost valuable features for real-time control. This OSEK technology is come from from Europian automotive industorysuch as BMW, Mercedes, Siemens, Bosch...

hi Ford,thx for your post!I even sent your question to the forums, but they don't seem to be very high frequented but most of your questions heve been answered, and this

Quote:

In this case, user available memory/stack is as followsROM: max. 224KbytesRAM: max. 50Kbytes

is really amazing!

Mon Sep 01, 2008 4:45 am

elemes

Expert

Joined: Fri Nov 09, 2007 4:51 amPosts: 121Location: Hungary, Europe

Re: programming the nxt ARM7 µC by a MT-capable C++ compiler?

Yeah, I suppose I will exploit Ford's findings sooner or later, however, at my stage of development I prefer the environment of RobotC. The resulting code can be ported to the "final" environment easily. I hope

Who is online

Users browsing this forum: No registered users and 1 guest

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