Forum Discussion
Altera_Forum
Honored Contributor
16 years agoinclude a selfwritten driver
Hello again, I just got another problem :) I have got a selfwritten driver, which is located at nios-linux/linux-2.6/drivers/misc/lcd_driver.cpp & .h (it works - I can put strings on the lcd). ...
Altera_Forum
Honored Contributor
16 years agoYou don't usually access a driver directly from a program (like including the header). You create a file system node under /dev for the device and write to it as a character device. Assuming you implemented your driver as a character device, you can add it to vendors/Altera/nios2/device_table.txt (or whatever your vendor directory is). Say you make /dev/lcd, then you should be able to `echo abcd>/dev/lcd` and have that show up. Or open the file from a program and write to it.