This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Calculated jump in C

Here's a tiny fragment of an 8051 Assembler-program
witch does a calculated Jump:

        *
        MOV     A,Menue
        ADD     A,Menue
        ADD     A,Menue ;LJMP xyz => 3Bytes
        MOV     DPTR,#Jump_tab_menue
        JMP     @A+DPTR
Jump_tab_menue:
        LJMP    Screen_toggle
        LJMP    Brightness
        LJMP    Bargraph
        LJMP    Yt_writer
        LJMP    Temperatur_100
        LJMP    Temperatur_120
        LJMP    Speaker_on_off
        LJMP    Calibrate
        LJMP    ...

Can anybody give me a concrete example how this could be look like in C?

Thank's in advice

0