Posts Tagged ‘developed countries’

Linux record audio from console / terminal with rec, arecord and ffmpeg

Monday, January 14th, 2013

 

Recording sound input from microphone linux penguin holding microphone

Recording from microphone input on Linux is possible, through multiple programs.

1. Recording microphone input using SoX's rec

 The classical old-school way is through a little proggie called sox. Back in the day I remember we recorded with sox with a friend from the school years necroleak – mirror of his website is on kenamick.pc-freak.net, trying to make save vox for one of his Tracked Songs. The experiments was not very succesful as both the PC microphone was low quality one, as well as the the state of recording microphone sound streams on Linux was terrible, but at least I learned about sox.

sox is not so popular and mainstream as it used to be back in the day but for anyone willing to investigate into the roots of GNU / Linux sound capturing make sure you have installed sox, alsa-utils and lame package. The package is available across virtually all main stream Linux distributions, depending on the distro to INSTALL sox do:

 

apt-get install --yes sox alsa-utils lame 
....

 (On Debian, Ubuntu, Arch, Xubuntu … )

yum -y install sox  alsa-utils lame
....

 (on Fedora, CentOS, RHEL …)

 slapt-get install sox ; swaret install sox alsa-utils lame
.....

(on Slackware and derivatives)

Before continuing it is a good idea to check, the microphone is not muted in alsamixer, amixer or aumix

The SoX package provides 4 binaries;

dpkg -L sox|grep -i /usr/bin/
/usr/bin/sox
/usr/bin/rec
/usr/bin/play
/usr/bin/soxi

sox -is tool to apply effects to recorded sound streams

rec – is historically among the first sound recorder tool to make records from microphone (even form the days of OSS – Open Sound System)

play – play is tiny .WAV and some other native classical sounds formats with a beautiful ASCII art (text) equalizer

soxi – gives information on recorded sound stream header (info)

rec -r 8000 -c 1 record_microphone_input.wav

rec is unfortunately made to use the old and now obsolete /dev/dsp sound interface, so on many Linux distributions, recording sound with it might pose problems.

Another problem of rec is it usually records with a lot of noise, thus reducing the noise later with sox cmd is almost necessery, to mitigate the noise you will have to experiment with its options. For some better quality of recording use arg -r 22050.

A little shell script with plenty of example use cases of rec and post sox effect applied as synchronization record_and_normalize_from_mic_with_rec_and_sox_on_linux.sh is here

Generally I mentioned rec for historical reasons, nowadays it is quite obsolete so you probably better stick to the newer alsa native arecord.

2. Recording sound from microphone using alsa-utils arecord

alsa-utils package has bunch of tools to record, play and tune sound;

dpkg -L alsa-utils |grep -i /usr/bin/
/usr/bin/aplaymidi
/usr/bin/aplay
/usr/bin/aconnect
/usr/bin/amixer
/usr/bin/alsamixer
/usr/bin/aseqdump
/usr/bin/arecordmidi
/usr/bin/speaker-test
/usr/bin/iecset
/usr/bin/amidi
/usr/bin/aseqnet
/usr/bin/arecord

One of tools included arecord is able to capture sound from microphone. arecord, can record into .WAV, but as .WAVs are not compressed and most people prefer to save the input to some more wide recognized format as .MP3 it should be invoked in conjunction with lame;

arecord -D plughw:0,0 -f S16_LE -c1 -r22050 -t raw | lame -r -s 22.05 -m m -b 64 - mic-input.mp3


Writting this long and hard to remember command line and arguments is tough, so I created a tiny shell script wrapper which accepts as 1-st argument a file name and saves .WAV and converts it to .MP3. The script linux_record_from_microphone.sh is here

3. Recording from microphone input using ffmpeg

I've earlier blogged on how to use ffmpeg to capture Microphone sound here.

For those lazy to read my previous post the skele syntax is;

ffmpeg -f alsa -ac 2 -i pulse -acodec pcm_s16le -vcodec libx264 -vpre lossless_ultrafast -threads 0 -y myVOICE.wav 

To later convert WAV to MP3 use lame;

 lame -r -s 22.05 -m m -b 64 myVOICE.wav  mic-input.mp3

Color Psychology – Color Mind Programming or how big companies boost their sales and make up your mind

Thursday, June 21st, 2012

Colors Programming Color mind Programming, how big companies boost their sales and make up your mind

As I've pointed earlier there is plenty of "secretly" kept and less known by public research on how colors influence us daily. The biggest companies are heavily taking advantage of what is found and known for colors impact on our minds (psyche). Actually there is a whole branch in psychology which deals with impact of colors perception on us.Besides companies, many modern governments are well aware of the many facts on how citizens percept colors and use this in color 'installment' in government offices and government institutions.

There is no universal knowledge on how colors completely affect us as every human on earth is very unique and saying this or that color has this or that impact on indivirual or group is not 100% accurate. However there are general traits nowdays formed especially with globalization and unification of TV ads and big companies corporate image, a unification started on how different nationality people perceive colors.

Nowdays in developed countries there are more and more people who perceive certain colors in similar fashion. Therefore every serious top marketer should carefully study colors and their relation with ancient time people believes and understanding on what each of the 'rainbow' colors symbolize. Most likely because there is no completely unified understanding of colors between various individuals may companies like Google and Microsoft started using all the rainbow colors in their basic company logos and branding for more on this topic please check my previous blog post Color trick Microsoft and Google use to keep their users loyal

Another large industry area, where color programming is very heavy is Computer and Video Games. You certainly still remember large portions of the games like Sega’s Sonic the HendgeHog or Mario Super Bros. or even the old arcade machines with games like Punisher or Cadillacs and Dinosaurs, Street Fighter etc.
All this old arcade games have a big portion of Color programming embedded in and this is one of the main reasons we remember them for a long time and playing them evoked such a strong feelings in youth.

This trend of using colors to make up our minds is being observed for many other physical goods as well as is starting to get more and more heavy adoption by websites branding on the internet.
Actually those with most succesful businesses on the internet have already integrated some kind of color programming scheme. An example for this would be the Internet top domain names seller GoDaddy. The have adopted a green scheme as a primary color combined with some other ones to create in the customer a feeling of ecology, naturality, peace and solitude.

The study of color programming is one major field to be known by anyone truly willing to understand why certain big store chainslike Carrefour, Lidl, Billa, MediaMarkt – in western europe or TechnoMarket, TechnoPolis (MediaMarkt copied tech equipment by shops here in Bulgaria) are decorated inside the way they are. I personally didn't like the concept of color programming since from Spiritual point of view it is a big evil. Trying to manipulate people perception to do something you would like to in general is very evil from spiritual point of view. A mixture of rainbow colors in a natural environment for example flowers in the wood or wild mountain place is one thing, but making it artificial and placing it in certain pre-desired order is totally another. Besides that the colors in the natural environment are natural and therefore the impact on us even if colorful is very much better than if it is done with a certain intention like in the big supermarkets stores, fast just food companies – McDonalds, Burger King etc.

The research on color mind influcence – Color mind programming is a controversial science. Nowdays many big businesses however use this as a granted science, even whole business sects with some mambo-jambo believes universities, children garden and schools in modern countries have employed the use of some type of color programming aiming to influence their pupils, students (organizational members – you call it).
Color mind programming and heavy use on advertisements on the TV, the Internet, Stores and mostly everywhere are however starting to took their tolls. The high increase in mental problems and dumbness in developed and some undeveloped countries as well as the increased number of people who go insane because of too much color programming is reality. The believe that mental programming is one of the ultimate tools to influence somebody and push him to do things you want like consome more of a product or generally consume (buy) more goods creates another severe issue it makes people to constantly over-consume (eat more than the body needs) and this increases the number of over-consumption evoked diseases …

But color programming doesn't stop with just the material (physical) surrounding world it is a concept highly employed in online based marketing. Online business is seen on so many top used websites, social networks like take for instance (facebook). It is so spread that even the software primary vendors like Microsoft, search engines Google Inc. have already heavily employed the color programming as a basis of their products.

There is another reason why most vendors nowdays issue their physical or 'virtual' products so colorful using all the colors of the rainbow. The reason is the fact that as a kids through animation, cartoons, toys and surrounding environment we have been exposed already even from our very youth age to a kind of color programming through kids toys we've been given by our parents). Hence the young years color programming became a basis for a future time color programming. The colorfulness of our kids years are already sub-consciously stored in our minds, so almost naturally there is a feeling of joy to pop-up once we see something childishly colorful.
 

My 5 cents on our quickly worsening online privacy and anonymity – Facebook your account is temporary locked

Thursday, September 15th, 2011

I needed to use another computer (IPad 2)to add one guy as a future business contact. I was suprised by a message which you see in the screenshot.
Facebook privacy breach again facebook your account is temporary locked
Facebook your account is temporary locked

obviously Facebook are becoming more and more impudent, so now apart from tracking all my activity in facebook and having the copyright rights over all my pictures uploaded, they now want to bind me to use their shitty service only from a single computer.

“We don’t recognize the device you’re using.” is scary to me personally and it shows a very bad direction, we have taken.
Now its supposed that any normal member of society is using his personal personal computer equipment (notebook, desktop, mobile tablet etc.), where the direction is that unification of devices is happening with development of handheld devices, so suddenly, we might soon be forced to only use only one personal device for all kind of activities phone calls, entertainment, checking online … etc. you name it
Then imagine, we might little by little be forced by mass adoption to only use this devices for all kind of communication.
Let me explain a bit thoroughflly what I mean. With the invention of the radio, people part of modern society has little by little started adopting the TVs as a device to retrieve information from various types from a centralized sources.

A time came, where everybody in the developed countries were using the radio, then came the TV and the television as a mass media, people who previously used the radio has comparatively quickly migrated to TVs and little by little, the radios use from the masses died.
Then came the more advanced kind of technologies the computers, first they were used by only choosen “elite” people who were beneficial to live in the developed society where first mainframe computers were invented, the technology was advanced and when the personal computers went out, the decrease of computer price allowed practically almost everyone from the developing or the development world to buy and start using it.
The increased use of computers and the emerge of Internet in the end of ’80s has suddenly shifted the mass use of TV to computer use.
People were crazy about computers, now most of the young and mid aged people from developed societies has almost completely abandoned the TV as a mean to get informed as the computer is doing the same. The emerge of pagers and mobile phones little by little and the development of the mobile phones has lead many people who actively was using a PC to switch to use of mobile or handheld devices and therefore forget compeltely about old desktop computers. These days even laptops use is getting threatened by tables like IPAD or Samsung’s Android tabloid. The trend therefore is that people who actively use their computers switch to tabloids and mobile phones in the next 10 years at worst.
It’s more and more rarely now that people use a random computer device to access the internet or in there daily lives this creates a very severe possible short-coming future issue as its possible we reach the time that most services available online might only be accessible via only certain devices which has “a hardware” (hard or unchangeble way to identify us).
This might sound a bit like a scenario for a sci-fi movie but unfortunately I see it as one very possible scenario.
If the idea of online provided resources and services social networks like twitter,facebook, xing etc. is originally to provide easy access to piece of information from anywhere in the world they shouldn’t definitely try to restrict us on how we use their services (especially if this is not illegal or in contradtion in country’s law.

Facebook is watching you the big brother facebook funny caricature

I really feel my privacy violated by facebook and I’ll probably delete my account there or always access it via a proxy further, I don’t like the idea that facebook is able to detect based on my IP change from country to country, the cookie shit it stores int he browser and browser and OS version of my computer what exactly is my computer and that I’m the only one to use this computer. What would it be if I was in a poorer country where the computer is used by many people, or I have borrowed my sister to travel abroad and use my notebook to access the internet and surrounding daily services she uses.
She might for example used the desktop at home and when travelling outside with my notebook access facebook, its a perfectly possible scenario. I don’t like the idea that I’m currently associated with a single computer really this is too much.The idea of linking my credentials for a shitty website like facebook to my personality is something I really don’t think is right.
If the Cloud Computing and online services should continue, there at least should be a government law to enforce, monopolists in online services to encrypt the user data in order to prevent, some facebook sysadmin or programmer or even the facebook Management board or CEO to have immediate access to privat information one puts in.

Same goes also for google, yahoo msn etc. Having an email account at any of the services and searching online reveals a lot of sensitive personal data, i’m quite sure that google/msn’s information stored for all the mail user accounts using the search engine services contains very sensitive information about a person’s personal private life and likings.
I’m quite sure google and the most of the big elephant companies are spying on their users and do create a thorough personal records for their users.
Scroogle instead of Google, improving browser security to secure, browser leaked personal identity data, Anonymizing ICQ and MSN to route traffic via tor , anonymizing Skype to hide your IP with Tor , Install torbutton to route Firefox browser traffic via Tor or use a combination of all to try to increase the level of anonimity online.
Also with the mass production and deloment of GPS integrated with most modern mobile phones, notebooks, cars etc. its pretty easy for one to be found nomatter where he is.
Its getting almost impossible for us to keep privacy and anoimty. While looking in the future and the latest technology development it appears situation will be getting worser.
Maybe the only way in future times for a man to be free will be completely abandon technology, as every piece of technology nowdays is doing some kind of tracking and leaking information about its user.
The increase of public security on airports, bus stations e.g. in airplanes, buses stregthens general society security, however it does this on account of decrease of personal privacy and makes us humans more and more dependent on “the system”.

All this induces a serious threat especially with the increase of unification of local countries and country adhering societies as a direct cause of globalization.
The globalization also leads to unification and merging of laws in countries around the world. The result from all this is also absollute necesity of internationalion of banking and financing system which is currently happening in front of our eyes.
They say it’s security measure but is it reall, just imagine if Gail, Yahoo or any otherBut let’s be optimistic, maybe I’m over-exaggerating, maybe things will go for good in short future and the “Doom scenario” will not happen 😉