questions about main_m4.cpp

151 views
Skip to first unread message

wj zhang

unread,
Jan 27, 2016, 8:15:32 PM1/27/16
to pixy_firmware_sdk
now, i have two problems need your help to solve as follows:
source code:   \pixy-master\src\device\main_m4\src\main_m4.cpp, download from  https://github.com/charmedlabs/pixy/tree/master  
loaction: the last function in main(), which is exec_loop()
1、exec_select(),   g_bMachine->selectProgram(progs, &g_program); (bool ButtonMachine::selectProgram(uint8_t progs, uint8_t *selectedProg) ), for this line code its function is that select button state machine, i understand the function is set signature (1 to  7 color) with button, am i right?
2、next while(1), it have 5 states(0、1、2,、3、4),could you tell me how to shift in this 5 states, and execute corresponding loop of (*g_progTable[g_program]->loop)()?
Reply all
Reply to author
Forward
0 new messages