Hi. Samsung provides a .ppd file. But when you try to use this a error occures. You must install "rastertosamsungspl" is written. To do this you must copy a file from the downloaded driver.
sudo cp ./cdroot/Linux/x86_64/at_root/usr/lib64/cups/filter/rastertosamsungspl /usr/lib/cups/filter/
I found the solution here: http://ubuntuforums.org/showthread.php?p=8926494
Here you find my solutions to diffrent technical problems. Secret comes from that it required much search on Google and much testing to acquire the solutions.
söndag 9 maj 2010
lördag 8 maj 2010
Completely remove mysql on ubuntu
Hi! I have had some problems with an broken mysql installation. After much searching I found a way to completely delete the installation and start from the begining. The following command did the trick:
sudo apt-get --purge remove mysql-server mysql-common mysql-client libmysqlclient15-dev
sudo apt-get --purge remove mysql-server mysql-common mysql-client libmysqlclient15-dev
How to fix 4.1 Ubuntu 10.04
Hi. As you've probably noticed you can choose 4.1 in the GUI for configuration of the sound. However for me it didn't work. When I choose 4.1 the subwoofer channel won't get any audio. To solve this I must remap!
Open /etc/pulse/default.pa (sudo gedit /etc/pulse/default.pa)
Add the following lines at the bottom
load-module module-alsa-sink device=hw:1,0 sink_name=working channels=5 channel_map=front-left,front-right,rear-left,rear-right,lfe
load-module module-remap-sink sink_name=realWorking master=working channels=5 master_channel_map=front-left,front-right,rear-left,rear-right,center channel_map=front-left,front-right,rear-left,rear-right,lfe
These lines remaps the LFE-channel to the center channel (which is 50% left, 50% right if you don't have one). My 4.1 system doesn't have a LFE input (so it isn't a real 4.1 in my opinion, but it's called so by the manufacturer). The system (amplifier in speaker) takes LF-signals from the front and redirects to the subwoofer.
NOTE that "device=hw:1,0" in the remap is specific for my setup. You might get some help from running "aplay -l" or just experiment. First case to test is "device=hw:0,0"
When you're done restart pulseaudio simply by writing "pulseaudio -k" (not sudo). When you kill pulseaudio it starts by itself.
Open /etc/pulse/default.pa (sudo gedit /etc/pulse/default.pa)
Add the following lines at the bottom
load-module module-alsa-sink device=hw:1,0 sink_name=working channels=5 channel_map=front-left,front-right,rear-left,rear-right,lfe
load-module module-remap-sink sink_name=realWorking master=working channels=5 master_channel_map=front-left,front-right,rear-left,rear-right,center channel_map=front-left,front-right,rear-left,rear-right,lfe
These lines remaps the LFE-channel to the center channel (which is 50% left, 50% right if you don't have one). My 4.1 system doesn't have a LFE input (so it isn't a real 4.1 in my opinion, but it's called so by the manufacturer). The system (amplifier in speaker) takes LF-signals from the front and redirects to the subwoofer.
NOTE that "device=hw:1,0" in the remap is specific for my setup. You might get some help from running "aplay -l" or just experiment. First case to test is "device=hw:0,0"
When you're done restart pulseaudio simply by writing "pulseaudio -k" (not sudo). When you kill pulseaudio it starts by itself.
onsdag 7 april 2010
Start up with Ubuntu server!
Hi! Here's a short article of how to get going with Ubuntu server (9.10+, maybe works on older).
1. Download Ubuntu server http://www.ubuntu.com/getubuntu/download-server
2. Install, you may burn it on a CD or create an startup-USB with http://unetbootin.sourceforge.net/
3. Install! It's easy, just boot and chose install.
4. Update everything! Write the following in terminal:
sudo apt-get update
sudo apt-get upgrade
Now you're up and running! However it's not that fun to have an empty server! It's easy to install stuff however. For example, install apache, php and mysql: write "tasksel install lamp-server" in terminal. And phpmyadmin, write "sudo apt-get install phpmyadmin". Don't forget ssh-server, so you can login remotely: "sudo apt-get install openssh-server".
Why use Ubuntu (or other linux based server)? Well it's free, it's stable, it's secure and it ain't that hard. All info you need can be found on the internet, and the quality of diffrent tutorials and guides or just being better and better! Give it a try!
1. Download Ubuntu server http://www.ubuntu.com/getubuntu/download-server
2. Install, you may burn it on a CD or create an startup-USB with http://unetbootin.sourceforge.net/
3. Install! It's easy, just boot and chose install.
4. Update everything! Write the following in terminal:
sudo apt-get update
sudo apt-get upgrade
Now you're up and running! However it's not that fun to have an empty server! It's easy to install stuff however. For example, install apache, php and mysql: write "tasksel install lamp-server" in terminal. And phpmyadmin, write "sudo apt-get install phpmyadmin". Don't forget ssh-server, so you can login remotely: "sudo apt-get install openssh-server".
Why use Ubuntu (or other linux based server)? Well it's free, it's stable, it's secure and it ain't that hard. All info you need can be found on the internet, and the quality of diffrent tutorials and guides or just being better and better! Give it a try!
torsdag 1 april 2010
PHP 5.3 problems with references
Hi! I have recently updated to Ubuntu Lucid. With this I also got PHP 5.3.2. I thought it would be no problems updating PHP, but now after some hours for debugging I know I was wrong.
First I got a mysql SQLException (My own exception telling my about syntax error). And an warning:
Warning: Parameter 2 to mysqli_stmt::bind_param() expected to be a reference, value given in /var/www/bla/lib/classes/Database/MysqliStmt.class.php on line 68
This was confusing as SQL-syntax shouldn't change. It hadn't. I found that the SQLException was due to another query that returned nothing, and by this causing the other query to fail. The other problem with the warning was trickier. I have built an Database abstraction layer, and I'm using "call_user_func_array(array(&$stmt, 'bind_param'), $params);" in my mysqli-driver, on line 68.
This error was new, I have used my database abstraction layer several times on diffrent servers without any errors. I first tried to solve the problem by changing how $params is created.
From:
foreach($values as $value) {
$params[] = $value;
}
to:
foreach($values as $value) {
$params[] = &$value;
}
Problem solved, if my only aim was to get rid of warnings at least. I didn't get any results from my querys earlier, but now I still didn't get results but no errors or warnings either. When I printed out $params I could see that all values where the same, the last put into the array $params. Then after a while I realized what I was doing. "foreach" copies a value from $values to $value. If PHP is working with references (which 5.3.2 seems to do more), then I'm just placing references into $params to $value. And $value changes on every loop. This explains why all values in $params had the same value, the last entered into $params. The solution was to use this code:
for($i = 0; $i < $max; $i++) {
$params[$i+1] = &$values[$i];
}
Here I go thorugh $values. For each value in $values I put an reference into $params. The reference is pointing into the right position in the array $values.
First I got a mysql SQLException (My own exception telling my about syntax error). And an warning:
Warning: Parameter 2 to mysqli_stmt::bind_param() expected to be a reference, value given in /var/www/bla/lib/classes/Database/MysqliStmt.class.php on line 68
This was confusing as SQL-syntax shouldn't change. It hadn't. I found that the SQLException was due to another query that returned nothing, and by this causing the other query to fail. The other problem with the warning was trickier. I have built an Database abstraction layer, and I'm using "call_user_func_array(array(&$stmt, 'bind_param'), $params);" in my mysqli-driver, on line 68.
This error was new, I have used my database abstraction layer several times on diffrent servers without any errors. I first tried to solve the problem by changing how $params is created.
From:
foreach($values as $value) {
$params[] = $value;
}
to:
foreach($values as $value) {
$params[] = &$value;
}
Problem solved, if my only aim was to get rid of warnings at least. I didn't get any results from my querys earlier, but now I still didn't get results but no errors or warnings either. When I printed out $params I could see that all values where the same, the last put into the array $params. Then after a while I realized what I was doing. "foreach" copies a value from $values to $value. If PHP is working with references (which 5.3.2 seems to do more), then I'm just placing references into $params to $value. And $value changes on every loop. This explains why all values in $params had the same value, the last entered into $params. The solution was to use this code:
for($i = 0; $i < $max; $i++) {
$params[$i+1] = &$values[$i];
}
Here I go thorugh $values. For each value in $values I put an reference into $params. The reference is pointing into the right position in the array $values.
fredag 11 december 2009
Pulseaudio
Hi, I'm been testing different settings in pulseaudio. I wanted to disable upmixing from stereo to 4.1 as my amplifier does this. I also been investigating how the LFE channel works. I only have two stereo cables from my soundcard (meaning 4channels). So I wanted to route all bass to front-speakers, as my amplifier then automatically sends it to the subwoofer (at least it seems so).
I didn't succeed with what I wanted, but I did learn some things about pulseaudio. And got my audio to work pretty good, even if not exactly as I wanted. Now my system does remix audio from stereo to 4 channels (front-left,front-right,rear-left,rear-right). But the reason why this is enabled is that it also routes the center channel to front speakers.
Here's a summary of stuff that I want to remember next time I work with pulseaudio:
I didn't succeed with what I wanted, but I did learn some things about pulseaudio. And got my audio to work pretty good, even if not exactly as I wanted. Now my system does remix audio from stereo to 4 channels (front-left,front-right,rear-left,rear-right). But the reason why this is enabled is that it also routes the center channel to front speakers.
Here's a summary of stuff that I want to remember next time I work with pulseaudio:
- pavumeter:
- paman:
- /etc/pulse/daemon.conf: ... remix, channels (example)
- /etc/pulse/client.conf: ...autospawn...
- /etc/pulse/default.pa: ... sink, remap
- pulseaudio -k && pulseaudio --start
lördag 5 december 2009
Spaces in /etc/fstab
Hi! I just had a problem with spaces in a mountpoints name. While searching for solutions I found others who had problems with this, but in their case while trying to mount a network share. The solution can be found in the manual page for fstab (write "man fstab" in terminal).
Here's the text from fstabs manual:
And here's a working example that mounts "/dev/sdb1" (ntfs) into "/media/drive 2"
Here's the text from fstabs manual:
The second field, (fs_file), describes the mount point for the filesys‐
tem. For swap partitions, this field should be specified as `none'. If
the name of the mount point contains spaces these can be escaped as
`\040'.
And here's a working example that mounts "/dev/sdb1" (ntfs) into "/media/drive 2"
/dev/sdb1 /media/drive\0402 ntfs nls=iso8859-1,umask=000 0 0
Prenumerera på:
Inlägg (Atom)