Hi Elecrow the reason I did not fill out the events is because I was hoping you would suggest a working function. All the functions I added did not work or gave me errors. I spent lots of time and am at the give-up stage.
Attach a file of the latest code. I done it different to get it working. I done all the events code in ino section and it is working. I don't know if there is a better method but that was the only way to get going. I will play around to see if I can get it less complicated. I am still open for suggestions.
But it's implemented by enumeration, so the return value you get won't be the result you want, I suggest you modify the value inside the structure directly.
I modified the event functions of the buttons, and I put all the button events into ui.c. I think it will be easier for you to read the source code, for each button event, there is a special function AdjustingStringX( ) that handles the information, and the functions that are used to handle the information, I put them all into ui_events.c.
Also, after the button events have been modified, you need to associate the events with the buttons, you need to use the lv_obj_add_event_cb function, which is normally generated automatically by Squareline, maybe your buttons 1 to 12 are generated manually, so this part of the code needs to be added manually as well.
I have tested it here and the values within the myData structure can be modified.
Hi thanks for your assistance I really appreciate. It's working now. You saved me lots of time. I might ask you for assistance later as I still need to add Time and Date as well as a frequency input. But I will first see if I can do it.
The project I am working on is, I am building my second Electro Steel guitar. Steel Guitars are all mechanical for the last 80 years, so I decide to build the first ever Electro steel where the strings are pulled by servo motors. After a year and a halve it's still running as new.
My second and current Electro Steel Guitar I use Stepper Motors to do the pulling and add the screen display to do a couple of add-ons like auto-Tuning, manual tuning and more.
Hi again. I am urgently seeking for help. Unfortunately I had to modify the Squareline code to complete the project. Firstly all worked but very slow and sometimes not. I used different methods to solve the issue and manage to load up successful but do not receive data on receiver end.
I would appreciate assistance if you can help please.
The structure is a Master unit with the Elecrow display and 3 receiver modules. I will attach code.
Thanks in advance
So I found the issue with communication. The WIFI I used for updating the time and date clashed with esp_now. The question then is how do I update the date and time?
Comments
Hi Elecrow the reason I did not fill out the events is because I was hoping you would suggest a working function. All the functions I added did not work or gave me errors. I spent lots of time and am at the give-up stage.
Hi roquestrongo. Its not to say I received faulted units. As I am still relatively new to coding, I could have damaged it.
Attach a file of the latest code. I done it different to get it working. I done all the events code in ino section and it is working. I don't know if there is a better method but that was the only way to get going. I will play around to see if I can get it less complicated. I am still open for suggestions.
@jdebruyn
Refering to documentation provided by LVGL:
https://docs.lvgl.io/master/API/core/lv_obj.html#_CPPv416lv_obj_get_statePK8lv_obj_t
https://docs.lvgl.io/master/API/core/lv_obj.html#_CPPv411_lv_state_t
you will found the return value of the function
lv_obj_get_state()
is _lv_state_tBut it's implemented by enumeration, so the return value you get won't be the result you want, I suggest you modify the value inside the structure directly.
I modified the event functions of the buttons, and I put all the button events into ui.c. I think it will be easier for you to read the source code, for each button event, there is a special function
AdjustingStringX( )
that handles the information, and the functions that are used to handle the information, I put them all into ui_events.c.Also, after the button events have been modified, you need to associate the events with the buttons, you need to use the
lv_obj_add_event_cb
function, which is normally generated automatically by Squareline, maybe your buttons 1 to 12 are generated manually, so this part of the code needs to be added manually as well.I have tested it here and the values within the
myData
structure can be modified.Hi thanks for your assistance I really appreciate. It's working now. You saved me lots of time. I might ask you for assistance later as I still need to add Time and Date as well as a frequency input. But I will first see if I can do it.
The project I am working on is, I am building my second Electro Steel guitar. Steel Guitars are all mechanical for the last 80 years, so I decide to build the first ever Electro steel where the strings are pulled by servo motors. After a year and a halve it's still running as new.
My second and current Electro Steel Guitar I use Stepper Motors to do the pulling and add the screen display to do a couple of add-ons like auto-Tuning, manual tuning and more.
Hi again. I am urgently seeking for help. Unfortunately I had to modify the Squareline code to complete the project. Firstly all worked but very slow and sometimes not. I used different methods to solve the issue and manage to load up successful but do not receive data on receiver end.
I would appreciate assistance if you can help please.
The structure is a Master unit with the Elecrow display and 3 receiver modules. I will attach code.
Thanks in advance
The display is very very slow. To speed up the module can we use the sd to store and upload data?
Hi I really need help with the above code. I tried all methods.
So I found the issue with communication. The WIFI I used for updating the time and date clashed with esp_now. The question then is how do I update the date and time?