logo

Could not compile stylesheet for simplistic. Using last compiled stylesheet.

Use of DSS pins as GPIOs on NY baseboard

posted in IGEP NEW YORK
Wednesday, June 19 2013, 05:53 PM
0
I have a headless igep0030 COM-based system on a NY baseboard and would like to 're-purpose' the DSS pins for use as GPIOs.

I am using x-loader v.2.5.0-2 and have edited board/igep00x0/igep00x0.c to change the MUX_VAL settings for the DSS pins from mode 0 (M0) to mode 4 (M4). I have CONFIG_OMAP_MUX set in my kernel .config file and have checked arch/arm/mach-omap2/board-igep0030.c to ensure that no DSS initialisation takes place.

My kernel boots fine but I cannot see any GPIO activity when I do (pin 22 on J22):
root@igep00x0:~# echo 70 > /sys/class/gpio/export 
root@igep00x0:~# echo out > /sys/class/gpio/gpio70/direction 
root@igep00x0:~# echo 1 > /sys/class/gpio/gpio70/value

Please could you suggest what I have done wrong?

Accepted Answer

Friday, June 21 2013, 10:08 AM - #permalink
0
The line:
buddy=base0010 buddy.revision=B

Remuxes the DSS to use the DVI or an LCD, for that reson didn't work before.
The reply is currently minimized Show
Responses (4)
  • Accepted Answer

    Thursday, June 20 2013, 09:19 AM - #permalink
    0
    Hi petej,

    Could you mount the debugfs and check how is configured this pin ?

    mount -t debugfs nodev /sys/kernel/debug
    cat /sys/kernel/debug/omap_mux/ dss_data*
    


    Thanks.
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, June 20 2013, 11:02 AM - #permalink
    0
    Here is what I see for dss_data0 (gpio70 in /sys/class/gpio):
    root@igep00x0:~# cat /sys/kernel/debug/omap_mux/dss_data0
    name: dss_data0.gpio_70 (0x480020dc/0x0ac = 0x0004), b ag22, t NA
    mode: OMAP_PIN_OUTPUT | OMAP_MUX_MODE4
    signals: dss_data0 | NA | uart1_cts | NA | gpio_70 | NA | NA | safe_mode
    

    From what I can see, the MUX setting is Mode 4 and is GPIO_70 as required. I have also tried several other DSS pins on J22 of the NY baseboard and none of them work as GPIOs.
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, June 20 2013, 12:08 PM - #permalink
    0
    You should configure mux of every pin.

    Take a look at Mux_configuration

    You could find an example of all steps at
    How_to_set_up_UART2_in_J990
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, June 20 2013, 02:13 PM - #permalink
    0
    All of the DSS pins were MUX'ed to Mode 4 outputs in my modified x-loader code. They don't need to be reMUXed. I only showed the result from dss_data0 in my previous post to save space - they were all Mode 4 outputs.

    I found a solution to the problem by commenting out the following lines in igep.ini (in the FAT32 boot partition):

    ; omapfb.mode=dvi:1024x768MR-16@60
    ; vram=40M
    ; omapfb.vram=0:12M,1:16M,2:12M
    ; buddy=base0010 buddy.revision=B
    ; omapdss.def_disp=lcd-70
    

    I can now use
    all
    the DSS pins as GPIOs :)

    I don't know enough about x-loader to understand why the removal of these lines would enable the GPIOs to work as expected.
    The reply is currently minimized Show
Your Reply

SUPPORT


This email address is being protected from spambots. You need JavaScript enabled to view it.
This email address is being protected from spambots. You need JavaScript enabled to view it.
IGEP Community Wiki
IGEP Community Forum
IGEP Community Online Chat