Im working on a project with Nextion HMI and STM32 F334R8. When I try to send string to Nextion with STM, UART doest shown in the category section in CubeIDE(This board has 3 USARTs but no UARTs). Is there a mistake Im making or my STM doest normally have any UART(if thats possible)?
Where can I select UART? (https://i.stack.imgur.com/4fpuU.png)
You can use USART instead, in setting parameters choose Mode: Asynchronous (it will be the same as UART).
Related
I want to run my code on raspberry pi which has a touchscreen attached to it. The GUI is made using pyqt5 and I want to pop up the system onscreen keyboard when the entry is focused.
tried many things but didn't get how to use this.
my problem is solved, this is for the future in case anyone has doubt in pyqt, you can use qlineedit selectionchanged object, for eg. mobile_entry.selectionChanged.connect(self.create_keyboard). and in create keyboard function you should do this >> subprocess.Popen(["onboard"], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
my code is getting stuck inside the HAL_Delay() of my code. On doing the step-into I found out that it is getting inside the hardfault_handler and because of which my code gets stuck inside the HAL_Delay().
Now the issue is that I am not able to get why my code is getting inside the hardfault_handler, I have not invoked any other interrupt, I also tried creating a project again and then running a simple blink led sketch but still, that does not work out and my code is getting stuck in hardfault_handler whenever I use HAL_Delay().
The controller I am using is STM32F103 Cortex M3.
Any valuable suggestions???? on how to solve this thing.
I'm trying to see if there's a way to use the display block in EV3 as a basic print function. I'm working from home and don't have a brick to test the code with so was hoping to just use the display preview option to output variables but I haven't been able to find a way. It will only show the standard 'Wired_1FAC2752-7229-46'. I've tried putting a wait block after it, putting it in a loop and clearing the display first but the preview never displays anything.
Thanks in advance
What about trying a "virtual" brick to run your programm?
Have a look at the "Virtual Robotics Toolkit": https://www.virtualroboticstoolkit.com/
It's not perfect and its not free but maybe a good workaround if you don't have any hardware at Home.
I have a machine with a lot of emergency buttons and for each one I have a signal to the PLC saying it is pressed. So I know which button is pressed.
I also have a KRC4 on the security and I do not have any signal from it to the PLC saying that it's emergency is pressed.
I could go by elimination, if none was pressed, so the robot is. But is not the best option because maybe I just have wire from the buttons disconnected and I will assume that is the robot that is in emergency.
I was thinking about getting a system variable that says it is pressed, but I could not find one. Does someone know how to know if the emergency is pressed programmatically?
maybe this helps:
The following predefined data lists exist in the KR C...:
$MACHINE.DAT
is a predefined data list with exclusively predefined system variables. The machine data
serve the purpose of adapting the controller to the connected robot (kinematic
information, control parameters, etc.). There is a $MACHINE.DAT in both the control
system and the robot system. You cannot create new variables or delete existing ones.
Examples:
$ALARM_STOP Signal for Emergency Stop (controller--specific)
Select (assuming that you have 'English' as selected language) Display-> Input/Outputs->External Automatic. This will open up a window where you can connect almost any event or state in the controller to one of the outputs that you have mapped to your PLC. The events or states are more or less self explanatory. Select one and press Configure and Edit to change the output from a default value to the one you desire.
There is no need for a restart afterwards. Just close the wizard and you are good to go. This is also where you can set up inputs for a remote start of the robot. Post a question if you need more details on this topic. Good luck!
I use EFL library to develop applications for Tizen platform. I need to implement event handler for hardware button "Back".
In native Tizen API it is done pretty simple. But I have no idea how can I do this in EFL library.
I tried to do it using the following way:
evas_object_event_callback_add( obj, EVAS_CALLBACK_KEY_DOWN, on_key_down, NULL );
But it doesn't work.
Could anyone help me?
Instead of EVAS_CALLBACK_KEY_DOWNandevas_object_event_callback_add()`,
use ea_object_event_callback_add
use EA_CALLBACK_BACK for back button
and EA_CALLBACK_MORE for menu button
but you need to include one header file, unfortunately I forgot the header file name
some thing efl-util.h or something, you can make a search in header files
AFAIK the thing is that EFL uses queues for processing events. That means that callbacks are called one by one: the first should return PASS_ON (or something) for the next callback for the same event to be run.
So, there may be another callback that does not allow the dispatch of the event.
Try
Ecore_Event_Handler *handler;
handler = ecore_event_handler_add(ECORE_EVENT_KEY_DOWN, hardware_key_down_cb, NULL);
In hardware_key_down_cb() callback function, check for key name 'XF86Stop' Ecore_Event_Key to handle back key event.
use eext_object_event_callback_add(Evas_Object * obj,eext_callback_type type,callback_fun,NULL)
and in call back function you can write your requirement