I have some problems with the MotorBridgeCape. I have all my software and I found most of it at GitHub.com at github.com/Seeed-Studio/MotorBridgeCapeforBBG_BBB and at their Wiki at seeedstudio.com/wiki/Motor_Bridge_Cape_v1.0. Here is my issue. I connect my battery, two motors, and I run the .py file for DC Mo…
ls to list matches in specified directory
How do I list matched results in a specified directory? On my Ubuntu server if I list the contents of a directory it correctly lists it. My working directory is /var/crash. Let’s say I want to list all files that contain ‘tar’. In this example there should only be one match i.e. start.txt Al…
How to create an archive and chmod it
I should create a file inside this file an archive. When I create it, I should use chmod so that the archive should have 757 rights. I did this but I failed, is this right or wrong? : Answer Use touch command first:
resend packets via RAW sockets in linux
It’s needed to read raw data from one interface and send it via another. open&&config(the same for sock_raw_outer): then in cycle: then, if I catch on sock_raw_inner any packet(arp request, for example), it sended on sock_raw_inner again and again by sendto. What’s wrong? Thanks. Answer Yo…
Shell: How to move multiple files to a directory and zip that directory with different name?
Fore example, I have some files in my project, structure could be like this I want to zip some files from my project and I can do that using ZIP command (build folder and some other files are excluded from zip) After this new file is created: In Mac Finder when I double click on this file it becomes unzipped
Undefined reference to process(std::__cxx11::basic_string … ) when compiling affdex linux sample applications
I encountered the following error when I tried to compile affdex sdk sample applications I’m using GCC 5.2.1 Answer My initial suspicion was that the problem is attempting to compile the apps using a newer GCC or rather GLIBCXX than what the sdk is compiled with (gcc v4.8). The error msg refers to an un…
basic linux x86 assembly minimum number returns incorrectly
I wrote this basic linux x86 assembly app. I expect it to return 3 when I do echo $? however the status is always 0. What am I doing wrong? Note: %ebx always contains the status code, and it should contain the min value by exit time. Fixed: Answer The issue is that the terminating zero also participates in th…
How to compile C code on Linux/GCC without deprecated functions being available?
There are old functions such as index, rindex which have now been superseded by strchr and strrchr. Is there a way to configure the compiler or defines so these functions aren’t available? It can cause confusing warnings when: accidentally using index name outside of scope for eg – or worse, not w…
Site with underscore at the end of 4th level domain name can’t be reached
We have our devel server in our company. Since 2006 we have this rule – if the project is finished and moved to production we have to append an underscore to the project name in the filesystem. So the url is changed from to I’m a linux user since 2008 but I was never able to open this site. It
MySQL code causes PHP script to crash at popen/exec
I have the following PHP 5.6.19 code on a Ubuntu 14.04 server. This code simply connects to a MySQL 5.6.28 database, waits a minute, launches another process of itself, then exits. Note: this is the full script, and it’s purpose is to demonstrate the problem – it doesn’t do anything useful. …