This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
spi_at91_set_npcs doesn't work
- From: "Jaws" <jaws75 at tiscali dot it>
- To: <ecos-discuss at sources dot redhat dot com>
- Date: Sat, 15 Jul 2006 20:05:35 +0200
- Subject: [ECOS] spi_at91_set_npcs doesn't work
Hi all,
I noticed that the funciton spi_at91_set_npcs doesnt' work because use
the chip select as active high.
a possible change could be
HAL_ARM_AT91_GPIO_PUT(spi_bus->cs_gpio[ctr], ((val & (1<<ctr))!=0) ? 0 : 1);
any one has experimented the same problem?
I'm also working on my board and I noticed strange behaviour (under
investigation) related to the macro provided in
hal\arm\at91\var\current\var_io.h, it seems they don't take any effect on
the PIO controller.
In my application I defined a function to inizialize the hardware platform
(hal_plf_hardware_init) that is called during the hal_hardware_init
funciton.
If with the gdb look at the memory at the address 0xFFFEC000 (PIOA) at the
begin of the function and during the execution of the marco
HAL_ARM_AT91_PIO_CFG or HAL_ARM_AT91_GPIO_CFG_DIRECTION no changes appear on
the PIO_SR register. Why? What's wrong? It's the first time that I'm using
this macros I'm forgetting something very importnt?
Thanks in advance
Jaws
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss