17 posts Posts by mpolaczyk

T-SQL Reusability

In this article, I want to share my thoughts about writing SQL scripts. Those experiences are taken from about 3 years of developing and deploying .NET applications, that store their data in MS SQL Server. This article is divided into three parts: Definition – Definition of “SQL Reusability”. Schema Reusability – Examples of how to change database schema in a good way. Data Reusability – Examples of how to change data in a good way. …

Continue reading →

Raspberry Pi Series – Samba share

Raspberry Pi Series – Samba share

This short article is an answer to the question: “How to write code on PC, and execute in on Raspberry ?”. It’s useful especially, when you have your Raspberry Pi connected only to the network, without screen nor monitor. Then the goal is to: Write code on PC. Save code in pi’s home folder (/home/pi). Execute code on Raspberry (SSH). My big shortcut is based on: http://elinux.org/R-Pi_NAS#Install_the_samba_software Installation Execute: sudo apt-get install samba samba-common-bin Configuration …

Continue reading →

Raspberry Pi Series – Mono C# USB Joystick Handler

Raspberry Pi Series – Mono C# USB Joystick Handler

This article presents joystick handler. It is based on analysis that was made before – here. Finally I’ve decided to use C# Mono technology because C# is my favourite and this code can be used on both Linux and Windows platforms. To execute it on your Raspberry Pi, you have to: Connect your joystick. Find device file. cd /dev/input; ls Install Mono and compile program. sudo apt-get install mono-complete mkdir ~/jstest-mono cd ~/jstest-mono joe jstest-mono.cs …

Continue reading →

Raspberry Pi Series – Joystick USB Communication Protocol Reverse Engineering

Raspberry Pi Series – Joystick USB Communication Protocol Reverse Engineering

Reverse engineering is a method of discovering how device works, just by observing how does it communicate, how it was build or which parts it contains. We are not going to disassemble anything, but it could be great fun to observe communication protocol. Of course we have to have proper tools and some time. In this article, I will show how simple reverse engineering could be done. Tested devices are Logitech Extreme 3D Pro and …

Continue reading →

Raspberry Pi Series – SSH Public Key Authentication

Raspberry Pi Series – SSH Public Key Authentication

Raspberry Pi is a very powerful device, especially if you are going to use it to control some other hardware like home automation or robotics. The best way to configure and use Raspberry Pi is to connect remotely through SSH and execute some commands. Because SSH allows to take control over the whole device – this connection should be as secure as possible. Basically, there is password authentication enabled, but this is not the best …

Continue reading →

7zip

7-ZIP – Compression program. Usage: 7za […] <archive_name> [<file_names>…] [<@listfiles…>] Solid mode: Solid mode allows to compress files as one block when turn on. This means that updating single compressed file will not be possible. -ms=on – Enable solid mode. All files are compressed as one (unable to update, and only for 7z format). Default behaviour. -ms=off – Disable solid mode. Commands: a – Archive, add. Puts files into an archive. (7za a -t7z files.7z …

Continue reading →

psftp

psftp.exe – Putty SFTP (Secure File Transfer Protocol) Client Usage: psftp <commands> <host> Commands: -l [username] – Connects to server using username. -P [password] – Connscts to server using password. -i [path to file] – Connects to server using key file. -b [file] – Use specified commands file. -bc – Output batch file. -v – Show verbose messages. -P [port] – Use specified port. -C – Enable compression. -batch – Disable all interactive prompts. -agent …

Continue reading →