Skip to content

GUISlice example ex40_ard_ctrls_small_seesaw.ino with ard-shld-adafruit_18_joy.h config works but not my own from GUIslice Builder does not #528

Answered by Dowster64
Dowster64 asked this question in Q&A
Discussion options

You must be logged in to vote

If any one else has the same issue the error was simple. The button mapping has to occur after function gslc_init() has been called. Here is the button mapping I used. If you put it in the arduino .ino file setup() function those lines go here (after the function defined in the auto generated header from builder) :

// ------------------------------------------------
  // Create graphic elements
  // ------------------------------------------------
  InitGUIslice_gen();

  gslc_InitInputMap(&m_gui, m_asInputMap, MAX_INPUT_MAP); 
  gslc_InputMapAdd(&m_gui, GSLC_INPUT_PIN_ASSERT,   GSLC_PIN_BTN_A,  GSLC_ACTION_FOCUS_PREV, 0);
  gslc_InputMapAdd(&m_gui, GSLC_INPUT_PIN_ASSERT,   GSLC_PIN_BTN_B…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by Dowster64
Comment options

You must be logged in to vote
1 reply
@Dowster64
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants