MyFirstApp example : does not work
Posted: Mon Oct 23, 2017 10:01 pm
Hi,
I did all the preparations which are explained here: http://redpitaya.readthedocs.io/en/late ... stApp.html
So 'myFirstApp' was created.
Then I tried to follow these instructions: http://redpitaya.readthedocs.io/en/late ... EDbut.html
FIRST QUESTION (WEB UI section):
I pasted the code for the button in index.html, but where do I have to paste the following code?
< div id='led_off'>LED Off</div>
< div id='led_on'>LED On</div>
The button is displayed, but the above code appears right behind the button. Do I have to put that code somewhere else?
The instructions are not clear about this point for me.
2ND QUESTION (WEB UI section / file app.js):
I pasted the code for APP.LED_State = false just above the $function{} line in app.js
I have no idea if this is OK. The instructions are not mentionning where exactly these lines need to be pasted.
3TH QUESTION (Section 'Controller')
I opened src/main.cpp
Where do I have to paste the code "CBooleanParameter ledState("LED_STATE", CBaseParameter::RW, false, 0);"
I pasted the ledstate.update() code at the end of main.cpp, just above the list of void procedures.
Is that OK?
4TH QUESTION
The instructions tell me not to forget to initApp() and release it elsewhere (rp_app_init() etc...)
Where? How?
Then I compiled the application (not the congtroller??) in ...MyFirstApp directory using the make INSTALL_DIR command.
message from syste:: nothing to be done for 'all'
Button is visible, but no led is switched on/off
Any help is welcome.
Best regards,
Herman.
I did all the preparations which are explained here: http://redpitaya.readthedocs.io/en/late ... stApp.html
So 'myFirstApp' was created.
Then I tried to follow these instructions: http://redpitaya.readthedocs.io/en/late ... EDbut.html
FIRST QUESTION (WEB UI section):
I pasted the code for the button in index.html, but where do I have to paste the following code?
< div id='led_off'>LED Off</div>
< div id='led_on'>LED On</div>
The button is displayed, but the above code appears right behind the button. Do I have to put that code somewhere else?
The instructions are not clear about this point for me.
2ND QUESTION (WEB UI section / file app.js):
I pasted the code for APP.LED_State = false just above the $function{} line in app.js
I have no idea if this is OK. The instructions are not mentionning where exactly these lines need to be pasted.
3TH QUESTION (Section 'Controller')
I opened src/main.cpp
Where do I have to paste the code "CBooleanParameter ledState("LED_STATE", CBaseParameter::RW, false, 0);"
I pasted the ledstate.update() code at the end of main.cpp, just above the list of void procedures.
Is that OK?
4TH QUESTION
The instructions tell me not to forget to initApp() and release it elsewhere (rp_app_init() etc...)
Where? How?
Then I compiled the application (not the congtroller??) in ...MyFirstApp directory using the make INSTALL_DIR command.
message from syste:: nothing to be done for 'all'
Button is visible, but no led is switched on/off
Any help is welcome.
Best regards,
Herman.