Monday, July 28, 2014

Raid error when installing windows xp with F6 option

File iaStor.sys cause an unexpected error (4096) at line 2113 in d:\xpsprtm\base\boot\setup\oemdisk.c.


To solve the problem you must extract the archive directly on the floppy drive, not extract to default location and then copy/paste to floppy.
Prior to this I have changed windows cd-s, countless pieces of floppy disks and many hours.

If the motherboard manufacturer does not provide good archive or one that cannot  be extracted directly to floppy you can download from intel downloadcenter by searching the south bridge chipset that you can find on the motherboard manufacturer website.

Intel® ICH9R/ICH9M-E/ICH10R/PCH/PCHM SATA RAID controller  

https://downloadcenter.intel.com/Detail_Desc.aspx?DwnldID=17882 

---------------------------------------------------------------------

Se extrage arhiva cu drivere RAID direct pe disketa si nu in locatia initiala si apoi sa copiezi fisierele pe disketa. Daca producatorul nu ofera o arhiva ce poate fi extrasa direct pe disketa se cauta dupa modelul chipsetului (south bridge) pe site la intel, nvidia etc dupa caz.

Saturday, July 26, 2014

Windows diagnostics and utils


Total system uptime, windows instalation date :

WinAudit - http://winaudit.zymichost.com/index.html
or write in cmd systeminfo|find /i "install"
---------------------
Windows activation :  slui.exe
IF windows fail to activate check the system date to be current date, as the server verification will fail with an older date.
If all else fail you can use automated phone sistem : 0800 822 222 (Romania)
---------------------

Useful programs :

Nirsoft - password recovery - http://www.nirsoft.net/
Sysinternals - various windows diagnostics - http://technet.microsoft.com/en-US/sysinternals


Get Data Back FAT32 NTFS  4.32 - Recover deleted files  (you need paid version to recover)


Java download - http://java.com/en/download/manual.jsp


CD Burner XP - https://cdburnerxp.se/
Magic iso maker - http://www.magiciso.com/download.htm

Daemon tools lite - http://www.disk-tools.com/download/daemon


Unlocker - ( Cannot delete file: Access is denied ) - http://www.emptyloop.com/unlocker/
Easeus Partition Master free ( partition manager ) - http://www.partition-tool.com/personal.htm
---------------------

HDD diagnostics :

HDD - Western Digital Data LifeGuard Diagnostics - WinDlg

    Thursday, July 24, 2014

    FTP mapping + VPN - Windows 7

    FTP mapping - windows explorer

    Open My Computer - Right Click - Select Add a network location - and follow the wizard, you have to provide the address  eg. ftp://ftp.domain.com/ , and select if you want to connect anonymous or with a specific username.



    Setare VPN - Server - Client - Windows 7

    VPN (Virtual Private Network) - allows direct access to a private network from the internet
    Data transferred through a VPN is encrypted

    1. VPN Server - incoming

    Open - Network and SharingChange Adapter Settings
    or Run - control ncpa.cpl


    Create port forwarding on the router for PPTP on port 1723
     
    Or press ALT key
    Click File, and then New Incoming Connection.
    Select the users you'd like to give access
    Select Through the Internet 
    Select TCP/IPv4
    And follow wizard : select a username with password, Through the internet, TCP/IPV4 and File sharing if you want it


    2. VPN client

    Click the Start button. In the search bar, type VPN and then select Set up a virtual private network (VPN) connection.


    OR

    Run - %windir%\system32\xwizard.exe RunWizard {7071EC75-663B-4bc1-A1FA-B97F3B917C55}

    VPN – Virtual Private Network

    When you connect to a public hotspot - free internet - at a hotel, restaurant, pub, airport etc – your data will pass through that local network, and any other users connected to the same network can listen to your data, especially when it is unencrypted - when you can login without a password.

    A vpn - is a virtual private network - but this connection is now encrypted with a Very long password (64 or 128 randome characters) that is almost imposible to break, or the effort is expensive unless you are targeted specifically.
    In most cases hackers just scan the trafic for credit cards or passwords to account.

    There are two ways to do this.

    Method 1

    This is the free mothod. If you own a router at your house with an internet connection, most router nowadays have a vpn server function implemented through openvpn.
    You just have to enable it on your router and and download the configuration file to your mobile phone / laptop.

    If you are using linux you have to install openvpn
    sudo apt install openvpn
    Then you have to start the tunnel as root
    openvpn --config /home/user/OpenVPN-Config-MyRouter.ovpn

    Method 2

    Use a payed service like NordVPN – where you pay around 10 euro per month and have all your data encrypted.
    With this service you also get a few more benefits like being able to change your location so you can access services available only in those countries.
    If you are a involved with webservices you can also test if geolocation works well.

    Monday, July 21, 2014

    SSH tunnel


    SSH tunnel - encrypted data - for public access points or avoiding local firewall rules

    1. Custom firmware  Tomato or DD-WRT  on a router connected to the internet
    2. SSH client eg. PuTTY
    3. SOCKS compatible browser eg. Firefox
    4. Dynamic DNS eg. NoIP



    Create a file eg. tunelssh.bat with the following line (putty exe must be in same folder or in system_path) :

    start /b putty -D 80 -P 22 -ssh xxx.no-ip.biz -l root

    start /b - run in background
    -D xxx - selected port for the tunnel ( 80 default for HTTP )
    -P 22  - ssh listening port on the destination router (default 22)
    xxx.no-ip.biz - public dns address or ip
    -l root  - username for authenticating on ssh server (optional)

    Tuesday, July 15, 2014

    Atmega AVR Programming Basics


    Program an AVR manually


    DDRX = DATA DIRECTION REGISTER X [1=output/0=input] where X is the letter of the register
    eg. DDRC |= _BV(7);    set pin 7 of register C as output

    PORTX = 1;
    eg.  PORTC ^= (1<<1);  set pin 1 of register C to HIGH (5v) until otherwise set

        DDRB = 0b00000110;
      PORTB = 0b00000100;

    Set a bit :

    _BV() is a macro, BV = bit value

    #define _BV(bit)  (1 << (bit))
    _BV(7) = (1<<7)   

    a |= (1<<position) or
    a |=_BV(position)

    example :
    a = 00000000
    a |= (1<<3)  =>  a = a|(1<<3) => a=(0000000)|(00000100) => a=00000100
    a |= _BV(3)

    Set a bit :
    a |= (1<<2);
    a |= _BV(2);

    Clear a bit :
    a &= ~(1<<2);
    a &= ~_BV(2);

    uint8_t (same as: unsigned char)
    int8_t (same as: signed char)

    uint16_t (same as: unsigned int)
    int16_t (same as: int)

    Hello world program in microcontroller world = Blink program :
    #define F_CPU 1000000UL  // set proc speed to 1MHz
    #include <avr/io.h>
    #include <util/delay.h>

    int main (void)
    {
        DDRD |= _BV(6);  // pin D6 set as output
       
        while(1)
        {
            PORTC |=_BV(6);
            _delay_ms(1000);
           PORTC &= ~_BV(6);
          _delay_ms(1000);
        }
    }
    ----
    itoa() - convert integer to string.

    Software :

    For uploading hex data to avr :
    eXtreme Burner - AVR => GUI alternative to avrdude - for uploading hex data to AVR
    http://extremeelectronics.co.in/


    For compiling code to hex :
    WinAVR - Gnu C compiler and AVRLibC -  http://sourceforge.net/projects/winavr/
    AVR Studio - IDE  - aStudio4b589.exe

    Resurse :
    Using LCD module with AVR - http://extremeelectronics.co.in/avr-tutorials/using-lcd-module-with-avrs/
    AVR basic programming - SPI PROGRAMMING BASICS
    Interfacing ps/2 - http://codelake9.wordpress.com/2011/12/10/interfacing-ps2-keyboard-to-atmega128atmega64/

    ADC - analog to digital convertor

       //InitADC
       ADMUX=(1<<REFS0); // For Aref=AVcc;
       ADCSRA=(1<<ADEN)|(7<<ADPS0);

    uint16_t ReadADC(uint8_t ch)
    {
       ch = ch & 0b00000111;
       // clear previous channel selection
       ADMUX &= 0xF8;
       ADMUX |= ch; // add in the new selection bits (REFS0 untouched)

       //Start Single conversion
       ADCSRA|=(1<<ADSC);

       //Wait for conversion to complete
       while((ADCSRA & (1<<ADSC)));

       return(ADC);
    }

         //ReadADC( channel )
         //ADC Channel ch must be 0-7 or what you micro has
          adc_value=ReadADC(7);

    Avr - SPI (Serial Peripheral Interface)

    Using USBASP :

    CONECTIONS : 
    MISO, MOSI, SCK, SS

    CODE :

    #define F_CPU 4000000UL


    char spiData = 0;
    SPCR = (1<<SPE);                   // Enable SPI

    while(!(SPSR & (1 << SPIF)));   // Wait for transmission end
    spiData = SPDR;                      // Read SPI Data Register - 1 byte

    ------------------------------------------------------------------------------------------------