guys tell me please what can be a problem – i send commands (sequence of bytes including bytes with most significant bit (MSB) = 1) to device through serial port, device successfully recognize the commands (so it seems all bytes are sent correct) and reply with almost correct answer. “Almost”…
Tag: linux
GitLab Ci Runner error ” bash: line 21: xcodebuild: command not found “
I hava a gitlab-ci service on Linux , here is the information I followed this tutorial https://about.gitlab.com/2016/03/10/setting-up-gitlab-ci-for-ios-projects/ , before the section How to trigger builds everything worked fine , the only different is the environment which is OS “El Capitan” and &…
Are sysfs binary attributes allowed to return more than one page of data?
I’m writing a linux device driver that, among other things, exposes a readonly binary attribute in sysfs, the interface for which is When I try to cat or hexdump the file, after the first 4096 bytes, my driver will be given a zero-sized read (It is passed 0 for size). Why is this happening, and how shou…
Linux NIC driver: what’s the UDP packet from 0.0.0.0 to 255.255.255.255?
I am playing with rhel6 and rhel 7 NIC driver. The interesting thing is, when I do “ifup eth0” (eth0 is the NIC associated with my driver), I found Linux will try to send two special UDP packets, with source address of 0.0.0.0 and destination address of 255.255.255.255. Can someone help me to unde…
Semaphores and Mutex behaviour doubts
Do semaphores and mutexes synchronize both threads and processes, or only threads, or only processes? Edit: my mistake it’s C, not shell. Since I programmed through the shell I mistook it. And one more thing: are communication and synchronization the same? Answer SysV IPC semaphores synchronize between …
Python Using Fileinput to Replace Words
I am using Python 2.7 with MAC OS X and wrote a program to replace a word in a file with another word. Any time that word shows up in that file I want it replaced with another word that the user specifies. It seems to be working but it seems to be outputting a couple extra lines on the
FFmpeg not copying all audio streams
I’m having trouble getting ffmpeg to copy all audio streams from a .mp4 file. After hours of searching online, it appears this should copy all streams (as shown in example 4 here): in.mp4 contains 3 streams: Video Audio track 1 Audio track 2 out.mp4 (which should be identical to in.mp4) contains only 2 …
Detect IP-Address change on an interface
I would like to trigger a service when a change of an ip address on a specific interface occurs. Is there a target for this or some other method I am not aware of to achieve this using systemd on Linux (Kernel 3.19)? The service would be used to send a SIGNAL to a defined process. The Linux is running
How can I put my GTK application in the desktop menus?
I started with programming a little time ago and I created my first running application with GTK 3.0. I did not use Glade, I do not know if worth highlight it. My code is working perfectly, but now I have a doubt, how can I make my own desktop menu application? I mean, I want that my application running up
install mysql 5.7 purely from bash script on Ubuntu
I want a bash script that installs a MySQL 5.7 instance without needing any manual input. I was following the tutorial on Digital Ocean and it says for 5.7 you have to run the following commands and then put commands into a prompt (screenshot below). How can I automate the installation if it requires me to us…