[En-Nut-Discussion] sam7x + rs485 (Szemz? Andr?s)

Mingshu Wang mwang at ccontrols.com
Fri Oct 26 17:31:05 CEST 2007


Hi Andras,

To make RS485 mode work, you have to setup the uart mode register in
rs485 mode and also enable the peripheral control of RTS pin.

Here is the code I use to set UART0 as RS485 mode.
    if(NutRegisterDevice(&DEV_UART0,0,0)==-1)                               //open the 485 port
    {
        //#ifdef DBG
        printf("%s Registration failed\n",DEV_UART0_NAME);  
        //#endif
    }
	outr(PIOA_PDR, 0x8);	
    reg_value = inr(USART0_BASE + US_MR_OFF);
    outr(USART0_BASE + US_MR_OFF, reg_value | 0x1);

Mingshu

-----Original Message-----
From: en-nut-discussion-bounces at egnite.de
[mailto:en-nut-discussion-bounces at egnite.de]On Behalf Of
en-nut-discussion-request at egnite.de
Sent: Friday, October 26, 2007 3:23 AM
To: en-nut-discussion at egnite.de
Subject: En-Nut-Discussion Digest, Vol 48, Issue 15


Send En-Nut-Discussion mailing list submissions to
	en-nut-discussion at egnite.de

To subscribe or unsubscribe via the World Wide Web, visit
	http://lists.egnite.de/mailman/listinfo/en-nut-discussion
or, via email, send a message with subject or body 'help' to
	en-nut-discussion-request at egnite.de

You can reach the person managing the list at
	en-nut-discussion-owner at egnite.de

When replying, please edit your Subject line so it is more specific
than "Re: Contents of En-Nut-Discussion digest..."


Today's Topics:

   1. Re: Ethernut 5 with ARM9 ?? (Paulo Silva)
   2.  How to use Banked Memory??? (SK2209)
   3. Re: Ethernut 5 with ARM9 ?? (Curtis Maloney)
   4. Re: Ethernut 5 with ARM9 ?? (Alain M.)
   5. R:  Ethernut 5 with ARM9 ?? (Paolo Inwind)
   6. Re: R:  Ethernut 5 with ARM9 ?? (Alain M.)
   7. How to use the Banked memory (Steve Kelly)
   8. sam7x + rs485 (Szemz? Andr?s)
   9. Re: How to use Banked Memory??? (Harald Kipp)
  10. Re: building the ATMEL AT91SAM7S-EK kit	for	ethernut os
      v4.4.0 (Ole Reinhardt)


----------------------------------------------------------------------

Message: 1
Date: Thu, 25 Oct 2007 18:23:40 -0200
From: "Paulo Silva" <psilva at opensoftware-br.com>
Subject: Re: [En-Nut-Discussion] Ethernut 5 with ARM9 ??
To: "Ethernut User Chat (English)" <en-nut-discussion at egnite.de>
Message-ID: <005701c81744$f04fb670$0e00a8c0 at OpenSoftware.local>
Content-Type: text/plain;	charset="iso-8859-1"

Hi Harald,

Now we are 3, I agree with you.

As Alain I am waiting Ethernut 5 board!

Paulo


  ----- Original Message ----- 
  From: Harald Kipp 
  To: Ethernut User Chat (English) 
  Sent: Thursday, October 25, 2007 4:56 PM
  Subject: Re: [En-Nut-Discussion] Ethernut 5 with ARM9 ??


  Hi Alain,

  I share your opinion regarding Nut/OS vs. Linux, but we both may be a 
  very small minority. :-)

  In fact the SAM9260 is overkill for a tiny system like Nut/OS. On the 
  other hand, if you want a blindingly fast and tiny system optimized for 
  a special purpose, Ethernut 5 may easily outperform larger systems 
  running at higher clock rates. I recently heard about a customer, who 
  wanted to grab 200 fps from the SAM9 ISI port. It fails, because the 
  designers simply forgot to add one more register to the ISI/PDC 
  interface, which would make this possible on Linux. With Nut/OS, this 
  should still work because of very short interrupt latency times. Image 
  processing is also my major motivation for Ethernut 5.

  I intended to publish a first schematic some weeks ago, but soemhow I 
  got stuck on the non-trivial power supply options (DC, USB and PoE).

  Nut/OS has been successfully implemented on the AT91SAM9260 Evaluation 
  Kit. You may want to take a look to the Atmel Application Note 'AT91 SAM 
  Internet Radio'.

  Regarding image processing: I purchased a kit from Omnivision, the 
  OV7720 ECX. It runs quite well via USB, but I do not know, whether this 
  sensor will work with the AT91SAM ISI. Informations about Atmel's image 
  sensor interface in the net are rare and I'd appreciate any pointer to 
  similar projects.

  Harald

  Alain M. schrieb:
  > I had a pleasant surprise of findind a reference to Ethernut 5 here 
  > <http://www.ethernut.de/en/hardware/index.html>
  >
  > How far is the devellopment gone?
  >
  > My interest is to replace one SAM7X with one ARM9 (AT91SAM9260 is my own 
  > 1st choice), and all that I see over the net for ARM9 is about Linux.
  >
  > IMHO Nut/OS is a much better option in a lot of cases (just like the one 
  > I have in mind) as I need just a simple system and I want to avoid Linux 
  > complexity.
  >
  >   

  _______________________________________________
  http://lists.egnite.de/mailman/listinfo/en-nut-discussion

------------------------------

Message: 2
Date: Thu, 25 Oct 2007 13:53:23 -0700 (PDT)
From: SK2209 <steve at planetcontrols.com.au>
Subject: [En-Nut-Discussion]  How to use Banked Memory???
To: en-nut-discussion at egnite.de
Message-ID: <13415792.post at talk.nabble.com>
Content-Type: text/plain; charset=UTF-8


Hi,

Can anyone help me out with how to use the banked memory in the Ethernut 2.
I need an additional 32k to store some structure data.
How do you initialize and use the banked memory?

I remember reading something about the PNut file system some time ago.
Problem is I am already using the XFlash for http pages and I don?t think
you can use both.

Any help would be appreciated.

Thanks Steve
-- 
View this message in context: http://www.nabble.com/How-to-use-Banked-Memory----tf4693601.html#a13415792
Sent from the MicroControllers - Ethernut mailing list archive at Nabble.com.



------------------------------

Message: 3
Date: Fri, 26 Oct 2007 09:02:47 +1000
From: Curtis Maloney <cmaloney at cardgate.net>
Subject: Re: [En-Nut-Discussion] Ethernut 5 with ARM9 ??
To: "Ethernut User Chat (English)" <en-nut-discussion at egnite.de>
Message-ID: <47212097.1050702 at cardgate.net>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Paulo Silva wrote:
> Hi Harald,
> 
> Now we are 3, I agree with you.

Keep that counter running... the specs on the ethernut5 put it squarely in our 
sights for an upcoming project or 20... :)

-- 
Curtis Maloney
cmaloney at cardgate.net



------------------------------

Message: 4
Date: Thu, 25 Oct 2007 20:50:45 -0300
From: "Alain M." <alainm at pobox.com>
Subject: Re: [En-Nut-Discussion] Ethernut 5 with ARM9 ??
To: "Ethernut User Chat (English)" <en-nut-discussion at egnite.de>
Message-ID: <47212BD5.6060801 at pobox.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Hi Harald,

> I share your opinion regarding Nut/OS vs. Linux, but we both may be a 
> very small minority. :-)

:)

> In fact the SAM9260 is overkill for a tiny system like Nut/OS.

In this particular case, I want to run just one single program! The 
speed could be an issue, so with ARM9 am sure it will not be. Also 
memory could be more than 256k, so maybe I will have 63Mb just sitting 
there heating up the atmosphere...

One stryking point is that from AT91SAM7X266 to AT91SAM9260+SDRAM the 
difference is just $5.73 (at digikey's prices)

> I intended to publish a first schematic some weeks ago, but soemhow I 
> got stuck on the non-trivial power supply options (DC, USB and PoE).

If you want an opinion, just send me something in PVT ;-)

> Nut/OS has been successfully implemented on the AT91SAM9260 Evaluation 
> Kit. You may want to take a look to the Atmel Application Note 'AT91 SAM 
> Internet Radio'.

Wow!

Thanks,
Alain


------------------------------

Message: 5
Date: Fri, 26 Oct 2007 03:35:51 +0200
From: "Paolo Inwind" <pbisiac at inwind.it>
Subject: [En-Nut-Discussion] R:  Ethernut 5 with ARM9 ??
To: "'Ethernut User Chat (English)'" <en-nut-discussion at egnite.de>
Message-ID: <007101c81770$8b37e010$2500a8c0 at ACERPORT>
Content-Type: text/plain;	charset="iso-8859-1"

Why not start with STR912FW44 ? 96KRAM, 512KFlash, Ethernet, USB,
CAN....all on board and around 7$ ! It costs less than ATMEGA and SAM7 !


Paolo Bisiach
Equadro srl
Via Pola, 2
35010 Vigonza (PD)
Tel e fax 049 9802405
email info at equadro.com


-----Messaggio originale-----
Da: en-nut-discussion-bounces at egnite.de
[mailto:en-nut-discussion-bounces at egnite.de] Per conto di Alain M.
Inviato: venerd? 26 ottobre 2007 1.51
A: Ethernut User Chat (English)
Oggetto: Re: [En-Nut-Discussion] Ethernut 5 with ARM9 ??

Hi Harald,

> I share your opinion regarding Nut/OS vs. Linux, but we both may be a 
> very small minority. :-)

:)

> In fact the SAM9260 is overkill for a tiny system like Nut/OS.

In this particular case, I want to run just one single program! The 
speed could be an issue, so with ARM9 am sure it will not be. Also 
memory could be more than 256k, so maybe I will have 63Mb just sitting 
there heating up the atmosphere...

One stryking point is that from AT91SAM7X266 to AT91SAM9260+SDRAM the 
difference is just $5.73 (at digikey's prices)

> I intended to publish a first schematic some weeks ago, but soemhow I 
> got stuck on the non-trivial power supply options (DC, USB and PoE).

If you want an opinion, just send me something in PVT ;-)

> Nut/OS has been successfully implemented on the AT91SAM9260 Evaluation

> Kit. You may want to take a look to the Atmel Application Note 'AT91
SAM 
> Internet Radio'.

Wow!

Thanks,
Alain
_______________________________________________
http://lists.egnite.de/mailman/listinfo/en-nut-discussion

__________ Informazione NOD32 2618 (20071026) __________

Questo messaggio  ? stato controllato dal Sistema Antivirus NOD32
http://www.nod32.it



------------------------------

Message: 6
Date: Thu, 25 Oct 2007 23:36:05 -0300
From: "Alain M." <alainm at pobox.com>
Subject: Re: [En-Nut-Discussion] R:  Ethernut 5 with ARM9 ??
To: "Ethernut User Chat (English)" <en-nut-discussion at egnite.de>
Message-ID: <47215295.6060708 at pobox.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

STR911FM44X6 at digikey: $17.82 and there is none available
STR912FAW44X6 at Mouser: $14.12 (in stock)

Anyway, I don't trust them. And I can say why: A friend of mine worked 
at ST (here in Brazil) and he once received an *express* order from the 
matrix: DO NOT to loose time with small clients.

I am a small client.

Alain


Paolo Inwind escreveu:
> Why not start with STR912FW44 ? 96KRAM, 512KFlash, Ethernet, USB,
> CAN....all on board and around 7$ ! It costs less than ATMEGA and SAM7 !
> 
> 
> Paolo Bisiach
> Equadro srl
> Via Pola, 2
> 35010 Vigonza (PD)
> Tel e fax 049 9802405
> email info at equadro.com
> 
> 
> -----Messaggio originale-----
> Da: en-nut-discussion-bounces at egnite.de
> [mailto:en-nut-discussion-bounces at egnite.de] Per conto di Alain M.
> Inviato: venerd? 26 ottobre 2007 1.51
> A: Ethernut User Chat (English)
> Oggetto: Re: [En-Nut-Discussion] Ethernut 5 with ARM9 ??
> 
> Hi Harald,
> 
>> I share your opinion regarding Nut/OS vs. Linux, but we both may be a 
>> very small minority. :-)
> 
> :)
> 
>> In fact the SAM9260 is overkill for a tiny system like Nut/OS.
> 
> In this particular case, I want to run just one single program! The 
> speed could be an issue, so with ARM9 am sure it will not be. Also 
> memory could be more than 256k, so maybe I will have 63Mb just sitting 
> there heating up the atmosphere...
> 
> One stryking point is that from AT91SAM7X266 to AT91SAM9260+SDRAM the 
> difference is just $5.73 (at digikey's prices)
> 
>> I intended to publish a first schematic some weeks ago, but soemhow I 
>> got stuck on the non-trivial power supply options (DC, USB and PoE).
> 
> If you want an opinion, just send me something in PVT ;-)
> 
>> Nut/OS has been successfully implemented on the AT91SAM9260 Evaluation
> 
>> Kit. You may want to take a look to the Atmel Application Note 'AT91
> SAM 
>> Internet Radio'.
> 
> Wow!
> 
> Thanks,
> Alain
> _______________________________________________
> http://lists.egnite.de/mailman/listinfo/en-nut-discussion
> 
> __________ Informazione NOD32 2618 (20071026) __________
> 
> Questo messaggio  ? stato controllato dal Sistema Antivirus NOD32
> http://www.nod32.it
> 
> _______________________________________________
> http://lists.egnite.de/mailman/listinfo/en-nut-discussion
> 
> 


------------------------------

Message: 7
Date: Fri, 26 Oct 2007 06:26:07 +1000
From: "Steve Kelly" <steve at planetcontrols.com.au>
Subject: [En-Nut-Discussion] How to use the Banked memory
To: <en-nut-discussion at egnite.de>
Message-ID:
	<2F9C72A3A690334FAEB25E0054A898592CFE0C at planet.planetcontrols.com.au>
Content-Type: text/plain;	charset="us-ascii"

Hi,

 

Can anyone help me out with how to use the banked memory in the Ethernut
2.

I need an additional 32k to store some structure data.

How do you initialize and use the banked memory?

 

I remember reading something about the PNut file system some time ago.

Problem is I am already using the XFlash for http pages and I don't
think you can use both.

 

Any help would be appreciated.

 



Kind Regards,

Steve Kelly
Projects and Systems Development Engineer

36 Costin Street
Fortitude Valley Qld  4006
Ph: (07) 3852 1255
Fax: (07) 3852 1272
Mob: 0402350818
Email: steve at planetcontrols.com.au


------------------------------

Message: 8
Date: Fri, 26 Oct 2007 08:54:17 +0200
From: Szemz? Andr?s <saam at kometa.hu>
Subject: [En-Nut-Discussion] sam7x + rs485
To: <en-nut-discussion at egnite.de>
Message-ID: <003501c8179d$06d33b30$0a01000a at saamnote>
Content-Type: text/plain;	charset="iso-8859-2"

hi,
 
Is there anybody, who used successfully at91sam7x uart in rs485 mode? If I
read the datasheet correctly, I need only setup the uart mode register in
rs485 mode.
(at least on at91rm9200 it's working in this way). I did that, but the RTS
pin isn't toggling as expected.
 
Another thing is I'm trying to add xyssl lib to the sam7x. Anybody does some
work on it, or has some experience, performace tests?
 
One more ask, is there anybody who have ported the AHDLC driver to the
SAM7X?
 
 
Thanks.
 
Best Regards,
Andras

----
Kometa 99 ?lelmiszeripari ZRt.
Sz?khely: 7400 Kaposv?r, P?csi u. 67-69., Levelez?si c?m: 7401 Kaposv?r, Pf. 58
C?gsz?m: Somogy Megyei B?r?s?g mint C?gb?r?s?g 14-10-300239
Ad?sz?m: 13749619-2-44
Telefon: 82/502-400, Fax: 82/502-415
http://www.kometa.hu




------------------------------

Message: 9
Date: Fri, 26 Oct 2007 10:19:15 +0200
From: Harald Kipp <harald.kipp at egnite.de>
Subject: Re: [En-Nut-Discussion] How to use Banked Memory???
To: "Ethernut User Chat (English)" <en-nut-discussion at egnite.de>
Message-ID: <4721A303.5050409 at egnite.de>
Content-Type: text/plain; charset=UTF-8; format=flowed

SK2209 schrieb:
> Can anyone help me out with how to use the banked memory in the Ethernut 2.
>   
http://www.ethernut.de/en/hardware/enut2/memmap.html
(See note 5)

Also helpful
http://www.ethernut.de/pdf/enmem21e.pdf

Here's a simple API
nut/os/bankmem.c

It's used by
nut/app/playmp3/playmp3.c

The PNUT file system also uses banked RAM
nut/fs/pnutfs.c

Harald



------------------------------

Message: 10
Date: Fri, 26 Oct 2007 10:22:57 +0200
From: Ole Reinhardt <ole.reinhardt at embedded-it.de>
Subject: Re: [En-Nut-Discussion] building the ATMEL AT91SAM7S-EK kit
	for	ethernut os v4.4.0
To: "Ethernut User Chat (English)" <en-nut-discussion at egnite.de>
Message-ID: <1193386977.7098.14.camel at platon>
Content-Type: text/plain; charset=ISO-8859-15

Hello,

> And I copy file by file from the ethernut.cvs.sourceforge.net to the nut
> os directory v4.4.0 files jonger than 2 weeks (I don't know of ther are
> a better way to do it)

Just checkout a new working copy from CVS. You won't need to copy them
over your existing tree.

> And I have a error see log file (ther no memory card on the kit maby
> disable the function , how?) 

If you want to disable mmc you could do so in the NutOs configurator 

Architecture/Arm/AT91_SPI_MMC_ACCESS

> Have somebody some solutions to fix it?

Yes. I looked into arch/arm/at91_spimmc.c and found the reason:

Line 90:

#else   /* MCU_AT91SAM7X256 */
#warning "MMC SPI mode not supported on this MCU"
#endif

Sorry, I do not own a sam7S board, so I can not fix it on my own. But it
should be quite simple. Simply copy the configuration for AT91SAM7X256 a
few lines above. They are 

#ifndef MMC_CS_BIT
#define MMC_CS_BIT      SPI0_NPCS1_PA13A
#endif
#define MMC_DATAOUT_BIT SPI0_MISO_PA16A
#define MMC_DATAIN_BIT  SPI0_MOSI_PA17A
#define MMC_CLK_BIT     SPI0_SPCK_PA18A

and modify for your your needs. You will find the correct pins in the
SAM7S datasheet.

If you got it working please send me a patch so I could add it to the
mainline sources.

Bye,

Ole Reinhardt

-- 
 _____________________________________________________________
|                                                             |
| Embedded-IT          Hard- und Softwarel?sungen             |
|                                                             |
| Ole Reinhardt        Tel. / Fax:        +49 (0)271  7420433 |
| Luisenstra?e 29      Mobil:             +49 (0)177  7420433 |
| 57076 Siegen         eMail:    ole.reinhardt at embedded-it.de |
| Germany              Web:         http://www.embedded-it.de |
|                      UstID / VAT:       DE198944716         |
|_____________________________________________________________|



------------------------------

_______________________________________________
http://lists.egnite.de/mailman/listinfo/en-nut-discussion


End of En-Nut-Discussion Digest, Vol 48, Issue 15
*************************************************



More information about the En-Nut-Discussion mailing list