eLua on lpc1769

classic Classic list List threaded Threaded
11 messages Options
agostain agostain
Reply | Threaded
Open this post in threaded view
|

eLua on lpc1769

Hi ,

did somebody port elua to the lpc1769 board? Some hints on how to do it?  

I would really appreciate any help.

thanks,

Agostino
Thiago Naves Thiago Naves
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

Not that I'm know. But should be fairly simple to do, since we already have a lpc1768 port.

-----
Thiago

On Mar 7, 2012 11:58 PM, "agostain" <[hidden email]> wrote:
Hi ,

did somebody port elua to the lpc1769 board? Some hints on how to do it?

I would really appreciate any help.

thanks,

Agostino

--
View this message in context: http://elua-development.2368040.n2.nabble.com/eLua-on-lpc1769-tp7353017p7353017.html
Sent from the eLua Development mailing list archive at Nabble.com.
_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev

_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
jbsnyder jbsnyder
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

Correct.  The port should be dead simple, basically making
modifications for clocking and perhaps other minor differences between
the 1768 & 1769.  If I understand correctly from some other pages the
only difference may be that it's clocked at 120 MHz rather than 100
MHz

So, it may be that even the current MBED sources will run (so long as
you ignore the pio module and turn off semifs in platform_conf.h
(under src/platform/lpc17xx)).

The following file might be relevant as well:
platform/lpc17xx/system_LPC17xx.c

On Wed, Mar 7, 2012 at 9:42 PM, Thiago Naves <[hidden email]> wrote:

> Not that I'm know. But should be fairly simple to do, since we already have
> a lpc1768 port.
>
> -----
> Thiago
>
> On Mar 7, 2012 11:58 PM, "agostain" <[hidden email]> wrote:
>>
>> Hi ,
>>
>> did somebody port elua to the lpc1769 board? Some hints on how to do it?
>>
>> I would really appreciate any help.
>>
>> thanks,
>>
>> Agostino
>>
>> --
>> View this message in context:
>> http://elua-development.2368040.n2.nabble.com/eLua-on-lpc1769-tp7353017p7353017.html
>> Sent from the eLua Development mailing list archive at Nabble.com.
>> _______________________________________________
>> eLua-dev mailing list
>> [hidden email]
>> https://lists.berlios.de/mailman/listinfo/elua-dev
>
>
> _______________________________________________
> eLua-dev mailing list
> [hidden email]
> https://lists.berlios.de/mailman/listinfo/elua-dev
>



--
James Snyder
Biomedical Engineering
Northwestern University
http://fanplastic.org/key.txt
ph: (847) 448-0386
_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
agostain agostain
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

thank you .. I'll give it a shot
agostain agostain
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

Hi ,

I was able to flash the lpc1769 finally .

how do I get the elua prompt.... Is there a default UART used by elua?


agostain agostain
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

agostain wrote
Hi ,

I was able to flash the lpc1769 finally .

how do I get the elua prompt.... Is there a default UART used by elua?

I get no eLua prompt when connected to UART0 which is the default UART.

When porting to lpc1769 I followed the suggestions previously posted. Everything compiled. I commented out the mbed Pio module and use the lpc17xx one.

What am I doing wrong ?

thanks in advance
BogdanM BogdanM
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

Hi,

The UART ID is declared in platform_conf.h. Look for the CON_UART_ID definition.

Best,
Bogdan

On Tue, Mar 20, 2012 at 11:41 AM, agostain <[hidden email]> wrote:

>
> agostain wrote
>>
>> Hi ,
>>
>> I was able to flash the lpc1769 finally .
>>
>> how do I get the elua prompt.... Is there a default UART used by elua?
>>
>
>
> I get no eLua prompt when connected to UART0 which is the default UART.
>
> When porting to lpc1769 I followed the suggestions previously posted.
> Everything compiled. I commented out the mbed Pio module and use the lpc17xx
> one.
>
> What am I doing wrong ?
>
> thanks in advance
>
> --
> View this message in context: http://elua-development.2368040.n2.nabble.com/eLua-on-lpc1769-tp7353017p7388544.html
> Sent from the eLua Development mailing list archive at Nabble.com.
> _______________________________________________
> eLua-dev mailing list
> [hidden email]
> https://lists.berlios.de/mailman/listinfo/elua-dev
_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
agostain agostain
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

Hi,

I got that and it is 0


I am able to connect to the UART0 with a terminal but I don't get any lua prompt(after resetting the board ).

I disabled the mbed_pio module in order to use the platform specific pio functions...(in platform_conf.h)


// The name of the platform specific libs table
#define PS_LIB_TABLE_NAME   "mbed"

#define LUA_PLATFORM_LIBS_ROM\
  _ROM( AUXLIB_PIO, luaopen_pio, pio_map )\
  _ROM( AUXLIB_UART, luaopen_uart, uart_map )\
  _ROM( AUXLIB_PD, luaopen_pd, pd_map )\
  _ROM( AUXLIB_TMR, luaopen_tmr, tmr_map )\
  ADCLINE\
  _ROM( AUXLIB_TERM, luaopen_term, term_map )\
  _ROM( AUXLIB_PACK, luaopen_pack, pack_map )\
  _ROM( AUXLIB_BIT, luaopen_bit, bit_map )\
  _ROM( AUXLIB_CPU, luaopen_cpu, cpu_map )\
  _ROM( AUXLIB_PWM, luaopen_pwm, pwm_map )\
  _ROM( LUA_MATHLIBNAME, luaopen_math, math_map )\
  _ROM( AUXLIB_ELUA, luaopen_elua, elua_map )
 /* _ROM( PS_LIB_TABLE_NAME, luaopen_platform, platform_map )*/ <------- commented this


BogdanM BogdanM
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

On Tue, Mar 20, 2012 at 3:24 PM, agostain <[hidden email]> wrote:

> Hi,
>
> I got that and it is 0
>
>
> I am able to connect to the UART0 with a terminal but I don't get any lua
> prompt(after resetting the board ).
>
> I disabled the mbed_pio module in order to use the platform specific pio
> functions...(in platform_conf.h)
>
>
> // The name of the platform specific libs table
> #define PS_LIB_TABLE_NAME   "mbed"
>
> #define LUA_PLATFORM_LIBS_ROM\
>  _ROM( AUXLIB_PIO, luaopen_pio, pio_map )\
>  _ROM( AUXLIB_UART, luaopen_uart, uart_map )\
>  _ROM( AUXLIB_PD, luaopen_pd, pd_map )\
>  _ROM( AUXLIB_TMR, luaopen_tmr, tmr_map )\
>  ADCLINE\
>  _ROM( AUXLIB_TERM, luaopen_term, term_map )\
>  _ROM( AUXLIB_PACK, luaopen_pack, pack_map )\
>  _ROM( AUXLIB_BIT, luaopen_bit, bit_map )\
>  _ROM( AUXLIB_CPU, luaopen_cpu, cpu_map )\
>  _ROM( AUXLIB_PWM, luaopen_pwm, pwm_map )\
>  _ROM( LUA_MATHLIBNAME, luaopen_math, math_map )\
>  _ROM( AUXLIB_ELUA, luaopen_elua, elua_map )
>  /* _ROM( PS_LIB_TABLE_NAME, luaopen_platform, platform_map )*/ <-------
> commented this

I'm sorry, I don't know what to tell you. It might be that simply
compiling the code is not enough, you also need some code changes for
LPC1769. This isn't easy to debug, I'm afraid.

Best,
Bogdan

>
>
>
>
> --
> View this message in context: http://elua-development.2368040.n2.nabble.com/eLua-on-lpc1769-tp7353017p7389129.html
> Sent from the eLua Development mailing list archive at Nabble.com.
> _______________________________________________
> eLua-dev mailing list
> [hidden email]
> https://lists.berlios.de/mailman/listinfo/elua-dev
_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
agostain agostain
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

In reply to this post by agostain
I don't have a way to debug with jtag so I use the uart port to debug ...

in the /src/main.c

I succesfully initialize the platform with platform_init()

// Initialize platform first
  if( platform_init() != PLATFORM_OK )
  {
    // This should never happen
    while( 1 ) ;
  }

 while(1) platform_uart_send(0,0x55); <---- I am able to write to the uart

this is not the case after executing dm_init() and dm_register consequently...


// Initialize device manager
  dm_init();
 
  while(1) platform_uart_send(0,0x55);
 
  // Register the ROM filesystem
  dm_register( romfs_init() );

  // Register the MMC filesystem
  dm_register( mmcfs_init() );

....


What could be the problem of this? Hope somebody can help me with that ...

cheers,

Agostino

agostain agostain
Reply | Threaded
Open this post in threaded view
|

Re: eLua on lpc1769

Ok it were compiler issues ... elua runs on the lpc1769 with the suggestions given on top ...

thanks for your support