Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++

Kernel reboot using LCD

Altera_Forum
Honored Contributor II
1,191 Views

Hi all, 

I am trying to use OPTREX LCD module on uclinux ( stratix II board ). 

I´m using J15 connector to avoid conficts with compact flash card. 

I have my own display driver designed using altera PIO component. 

My display driver runs without problems on a NIOS II project. 

When I put my application on uclinux the kernel reboot. 

 

Thanks for any suggestions.
0 Kudos
10 Replies
Altera_Forum
Honored Contributor II
442 Views

I'm sorry, but that's not enough information for me to help... what do you mean when you say you put your application on uClinux?

0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hello Ken, 

First I created a new 11 bit PIO and write a simple C program to run on NIOS II. 

The project has 2 files named lcd_16207.h and lcd_16207.c and I can control the LCD using this option. 

Then I created a new linux application project and put lcd_16207.* files into the new project. 

When I run the application the kernel reboot when acessing IO from LCD.
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

I'm guessing that the application compiled properly and that you got it into the filesystem on the Nios II alright. How are you doing your read and writes to the PIO in your Nios II Linux application?

0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hello Ken, 

 

I´m using IORD and IOWR macros 

 

IOWR(PIO_LCD_0_BASE,0,0); 

IORD(PIO_LCD_0_BASE,0); 

 

The problem was solved : 

I put the code on lcd_16207.c file into main file application (lcd.c) and now the LCD is OK. 

Problably Eclipse is causing the problem. 

 

Thanks for help
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Which file do you include to using IOWR/IORD? 

 

So , in my view, you builde a application software instead of "linux drivers" , isn't it ?
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hi, 

 

The include files are: 

 

nios2_system.h 

io.h 

system.h 

lcd_16207.h 

The software is an application. 

I dont know how to make a "linux driver"
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hi! 

 

Is a special driver always necessary to use a LCD, a LED or other devices under Linux? 

 

 

Bye, Lothar.
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

 

--- Quote Start ---  

originally posted by mtuxpe@Aug 26 2005, 03:18 PM 

hi, 

 

the include files are: 

 

nios2_system.h 

io.h 

system.h 

lcd_16207.h 

the software is an application. 

i dont know how to make a "linux driver" 

<div align='right'><{post_snapback}> (index.php?act=findpost&pid=9310) 

--- quote end ---  

 

--- Quote End ---  

 

 

mtuxpe, 

 

Can you show me how i can write an application to use the 16207 ? 

 

my nios2_system.h doesn&#39;t have entries on 16207 ? What do i need to do ? 

 

Some help would be good. thanks
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

dear mtuxpe 

could you post the LCD driver code ?thanks
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

show you code,Maybe someone can help you

0 Kudos
Reply