Forum: ARM programming with GCC/GNU tools NutOs and eeproms

Author: Przemyslaw Grzesiowski (pgp)
Posted on:

Rate this post
0 useful
not useful
Hi , I'm a new on this forum. I'm interesed in ARM - SAM7x256 but I'm a
beginner in that subject. Does anyone use NutOs and EEprom ?  I would
like to use some EEprom because SAm7x256 doesn't have any inside.
NutOs's documantation mentioned only ATmel flash and intersill eeprom
with RTC - NutOS has drivers to it. But I wold like to use another
eeprom (maybe ATmel eeprom ) and I don't now if it is possible to
program it on low level (SAM7x256 Registers, One wire or SPI etc.). How
to do it (low level - processor register programming) on NUTOs ??

Author: Clifford Slocombe (clifford)
Posted on:

Rate this post
0 useful
not useful
You have made a bizarre assumption that your readers were aware of what
"NutOs" is. I assume you mean Nut/OS
(http://www.ethernut.de/en/software.html). You should probably always
post a link to any third party tool (i.e. not supplied with
WinARM/ARM-GCC distributions)

I would not expect any RTOS to prevent you from directly accessing
hardware registers, so there are no particular issues with using one and
doing low-level hardware access I/O is the job of your application not
particularly that of an RTOS, which is primarily concerned with
scheduling and communicating between tasks.

What you do need to be wary of however is mutual exclusion. When one
task is accessing a resource (such as an EEPROM or interface used to
communicate with one), other tasks must be prevented from doing so. The
usual method is to use an RTOS mutex semaphore. Nut/OS has
non-preemptive cooperative multi-threading, so you will not need to use
a mutex - just make sure an operation is complete before yielding, or
use flag to prevent access is an operation must yield mid-operation. The
simple approach is merely to restrict all access to the resource to a
single thread. Where multiple threads require the resource, you can use
a "server thread" that receives requests from other threads to access
the resource in a controlled and sequential manner.

Now how you actually communicate with your device is not possible to say
until you decide what device to use and how to connect it to your
processor. But is is a matter of reading the data sheet for both and
connecting the appropriate interface. Serial EEPROMS are typically
either I2C (TWI) or SPI devices.


Author: Przemyslaw Grzesiowski (pgp)
Posted on:

Rate this post
0 useful
not useful
Yes, of course it is Nut/Os (ethernut) - http://www.ethernut.de


Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]

Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.