0509

How To Transfer File Using Putty Serial Command

Linux System Administration and Configuration. Related Yo. Linux Configuration and Admin Tutorials. The Linux boot process. Quotas Assign disk resource limits to users or groups. M4GpXZ0c0/TpQJhVGR4MI/AAAAAAAAAU4/V_3mtZJDTEE/s1600/01.png' alt='How To Transfer File Using Putty Serial Command' title='How To Transfer File Using Putty Serial Command' />Blog Entry Using Serial Peripheral Interface SPI with Microchip PIC18 Families Microcontroller September 12, 2010 by rwb, under Microcontroller. Download PuTTY. PuTTY is an SSH and telnet client, developed originally by Simon Tatham for the Windows platform. PuTTY is open source software that is available with. Who should read this book This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and. UPS Network Management Card 2 CLI 1 Command Line Interface CLI How To Log On Overview To access the command line interface, you can use either a local, serial. Just for the records, i could successfully install the driver and use the USBSerial adapter on Mac OS v10. Mountain Lion. The only difference from the tutorial. Connecting external electonics using the serial port. For hobbyists and educators. Managing groups and user security Linux Networking tutorial. DHCP Server tutorial. NIS Server Client configuration tutorial. Configuring an internet web server. Apache, DNS, FTP. Internet Server Security. System optimization System re configuration Commands used to re configure video, keyboard, mouse, datetime, sound card, NIC, Printer. Installing a new kernel RPMYo. Linux Tutorials Index. Monitoring the system Basic command line pstree Processes and parent child relationshipstop Show top processesmpstat Report processors related statistics. Example mpstat AUbuntu install apt get install sysstatdstat generate system resource statistics report. Examples dstat a, dstat fUbuntu install apt get install dstatiostat Report CPU statistics and inputoutput statistics for devices and partitions. Report virtual memory statisticsstat display file or file system status. Example stat f devsda. NFS statisticsUbuntu install apt get install nfs common. Display Linux kernel version in use. Display Red Hat Linux Release. Tell how long the system has been running. Also number of users and systems load average. Show who is logged on and what they are doing. List all currently loaded kernel modules. Same as cat procmodulessbinrunlevel. Displays the systems current runlevel. Displayschanges the systems node name. Must also manually change hostname setting in etcsysconfignetwork. Command will change entry in etchostsservice. Red HatFedora command to display status of system services. Example service status all. Help service help. Also see ntpstat. GUIGraphical gnome system monitor. Lil Vicious Destination Brooklyn Zip. Operating system monitor and usage graphing. Graphical system monitor. Additional RPM package gkrellmps. D load meter. Very cool 3 D graphics. Operating system monitor load, memory, swap, net, disk,. List of tools. Process Management. Processes execute within their own process environment, they have their own memory, current working directory, priority, process ID, parent process ID and the file access privileges of the user ID under which they execute. The basic Linux monitoring commands such as pstree and ps auxw. Sometimes a process must be terminated. Putty2.png' alt='How To Transfer File Using Putty Serial Command' title='How To Transfer File Using Putty Serial Command' />To terminate a process. Identify the process. Welcome to The CHIP Operating System. We made a computer. A 9 computer. And every computer needs an operating system. Ours is The CHIP Operating System. PuTTY is the worlds most popular free SSH and telnet client. Downloads, tutorials, howtos, vulnerabilities. If you want to provide feedback on this manual or on the PuTTY tools themselves, see the Feedback page. PuTTY release 0. 60. OR. ps auxw. OR. Kill the process. This will perform an orderly shutdown of the process. If it hangs give a stronger signal with. This method is not as sanitary and thus less preferred. A signal may be given to the process. Traceable Fonts. The program must be programmed to handle the given signal. See usrincludebitssignum. For example, to restart a process after updating its configuration file. HUP lt process id number. How To Transfer File Using Putty Serial Command' title='How To Transfer File Using Putty Serial Command' />How To Transfer File Using Putty Serial CommandIn the previous example, the HUP signal was sent to the process. The software was written to trap for the signal so that it could respond. If the software command is not written to respond to a particular. Identify all known signals fuser l. Process Monitoring and Management GUI Tools xosview Oldie but goodie. Su. SE. QPS See below. Also see the GUI tool QPS. Handles MOSIX cluster. This tool is outstanding for monitoring, adjusting nice values priorities. RPM available from this site. It is so simple to use, no instructions are necessary. It can monitor a program to make sure it isnt doing something bad. It is also reverse engineer what applications are doing and the environments. I love this tool Note The RPM provided was compiled for Red. Hat 7. x. For Red. Hat 8. 0 one must. QT library RPMs to satisfy dependencies. Xt 2. 3. 1 8. i. Then install qps rpm ivh qps 1. Note Fedora Core 3 rpm ivh qt. These older RH 8. AMD6. 4 Fedora Core 3 x. OS system. Configuring QPS to run applications against a process Select Command Edit Commands. Add Description GDB. Command Line xterm T GDB C e gdb d directory where source code is located pidp. Description gdb. Command Line xterm T gdb c p e gdb procpexe p As issued in RPM. Description strace. Command Line xterm T strace c p e sh c strace f pp sleep 1. Try it with the process qps itself. Show output written by process. T strace c p e sh c strace f q e tracewrite pp sleep 1. Description truss Solaris command. Command Line xterm T truss C p e sh c truss f p p sleep 1. Process Priority Control. Multi tasking operating systems executes processes in a time slice fashion sharing the processing resources base on their current privilege. Privileges are not constant and elevate if they have not received an execution allocation in the processor after a given time. This is to ensure that all processes get executed regardless of priority although a process can get squeezed out of the time allocation alltogether if the system is overloaded. Higher priority processes may get more time allocated on the processor than a lower priority process but it is likely that the lower process will get some processor allocation. Many system process which manage the system environment execute at an elevated priority in order to guarentee that they get executed. User processes can have their priority elevated using the nice command. Nice values have a range from 2. Beware that if the priority is elevated higer than a system process, the behavior of the system may be compromised. Modify process scheduling priority. Lower scheduling priority runs slower and less likely to slow you down. Default for nice n is 1. Show default for any process nice executable. Shows nice value to be used if run. IPCs Semaphores, Shared Memory and Queues. Note that some processes may use Linux Inter. Process Communication or IPC. Identify the semaphores ipcsipcs q List share queues. Shared memory. ipcs s List Semaphores. Remove the semaphores ipcrm s lt ipcs id. Example If you are running Apache, you may see the following. DIR ipcs m Shared Memory Segments key shmid owner perms bytes nattch status 0x. Processes attached to open files or open network ports. The command lsof. List processes attached to a given file lsof filename. DIR lsof varlogmailmanqrunner. REG 3,5 6. 57 4. REG 3,5 6. REG 3,5 6. 57 4. REG 3,5 6. REG 3,5 6. 57 4. REG 3,5 6. REG 3,5 6. 57 4. REG 3,5 6. The process attached to an open file can be killed using the command. List all open files on system lsofLong list. List all files opened by user lsof u user id. The commands netstat punta and socklist will list open network connections. Garmin Mobile Xt For Windows Ce 5.0. Example netstat anp. Use the command lsof i TCP port number to see the processes attached to the port. Example. rootnode DIR lsof i TCP 3. COMMAND PID USER FD TYPE DEVICE SIZE NODE NAME. IPv. 4 7. 56. 00. TCP ldap LISTEN. IPv. TCP ldap LISTEN. IPv. TCP ldap LISTEN. IPv. TCP ldap LISTEN. IPv. TCP ldap LISTEN. This shows that the command slapd running under user id ldap. Restricting user resources ulimit bash shell command. Shell and process resources may be controlled and reported using the. Display the limits of a shell using the bash command. Limits can be set for the number of open files and. View file size limits ulimit f. See limits assigned in etcsecurity discussed below. Using Serial Peripheral Interface SPI with Microchip PIC1. Families Microcontroller. The Serial Peripheral Interface SPI is one of the popular embedded serial communications widely supported by many of todays chip manufacture and it considered as one of the fastest serial data transfer interface for the embedded system. Because of its special inout register configuration, the SPI master device could transfer its data and at the same time it receive a data from the SPI slave device with the clock speed as high as 1. MHz. Beside its superior data transfer speed SPI also use a very simple data transfer protocol compared to the other serial data transfer methods. When the SPI master device want to send the data to the SPI slave device then the SPI master will just simply shifting its own data through a special 8 bits register and at the same time the SPI master will receive the data from the SPI slave into the same register as shown on this following picture With this circular shift register connection between the SPI master and the SPI slave devices, the complete data transfer from both devices will be accomplished in just 8 clock cycles. This means the SPI devices only need about 0. MHz clock. One of the drawbacks using the SPI especially when we use multiple SPI slave device is the SPI slave could not initiate sending its own data to the SPI master device, all the data transfer initiation is always come from the SPI master. The SPI master device has to poll each of the SPI slave devices to know whether the SPI slave device has a data to be sent to the SPI master device or not. Polling the entire SPI slave devices will eventually consumed the SPI master resources when the SPI slave devices to be polled increase, therefore some of the SPI slave device is equipped with the interrupt pin to notify the SPI master device that it has a data to be read. You could read more about how SPI work in my previous posted blog Using Serial Peripheral Interface SPI Master and Slave with Atmel AVR Microcontroller. The PIC1. 8F1. 4K2. Microcontroller On this tutorial I will use the Microchip PIC1. F1. 4K2. 2 microcontroller, this microcontroller is one of my favorite 8 bit 2. PIC1. 8 microcontroller families members as it is equipped with sophisticated advanced peripheral inside such as ADC, USART, ECCP Enhanced CaptureComparePWM, SPI, I2. C and the SR Latch 5. Timer module for capacitive sensing. With 1. 6K bytes flash ram and equipped with the build in circuit debug, this 8 bit 2. The PIC1. 8F1. 4K2. SPI peripheral support both master and slave mode but on this tutorial we will only exposing the PIC1. F1. 4K2. 2 SPI master mode where on the first part we will expand the PIC1. F1. 4K2. 2 microcontroller IO by using the SPI IO expansion chip and the second part we will turn the PIC1. F1. 4K2. 2 microcontroller into a very useful SPI device testing tools that could be used to test and debug most of the SPI device chip available today. Both of these projects will give a good understanding and experience of how the PIC1. F1. 4K2. 2 microcontroller SPI master peripheral works. Now lets list down all the necessary hardware and software needed to accomplished these projects Resistors 3. Ohm 8 and 1. 0K 1LEDS 3 mm Blue LED 8 and 3 mm Red LED 1One momentary push button. One Breadboard and some breadboards jumper cables. PICJazz 2. 0 PIN learning board with Microchip PIC1. F1. 4K2. 2 microcontroller from ermicro. Microchip PICKit. Microchip PICKit. Microchip MPLAB IDE version 8. Microchip C1. 8 Compiler version 3. Microchip Reference Document PIC1. F1. 4K2. 2 datasheet, MCP2. S1. 7 datasheet, and MCP4. Microchip MCP2. 3S1. SPI IO Expander. The Microchip MCP2. S1. 7 SPI IO expander will give you additional of 1. IO ports where all the 2 x 8 bits general purpose IO ports GPIO could be configure both as output or input. The MCP2. 3S1. 7 IODIRA and IODIRB IO direction register is used to control the IO direction for GPA and GPB respectively. One of the unique features of the Microchip MCP2. S1. 7 SPI IO expander is in its configurable address capabilities. By setting the needed address to its address pins A0, A1, and A2 we could configure up to 1. SPI devices or in other world you could put up to 1. MCP2. 3S1. 7 SPI IO expander in the same SPI bus without having to have the separate CS chip select circuit logic for each of the MCP2. S1. 7 SPI IO expander chip. Each of the MCP2. S1. 7 general IO pins also could be configured to generate interrupt when the ports pin changes its state for more information please refers to Microchip MCP2. S1. 7 datasheet. For the purpose of this tutorial we will use the Microchip MCP2. S1. 7 just as the ordinary input and output expander for the PIC1. F1. 4K2. 2 microcontroller. The MCP2. 3S1. 7 is configured to use address 0x. A0,A1, and A2 are connected to the ground and the push button switch connected to GPB0 port will be use as the toggle button to start and stop the chaser LED display attached to the GPA0 to GPA7 ports. The following is the C code to achieve these tasks. File Name picspi. Version 1. 0. Description SPI IO Using Microchip MCP2. S1. 7 1. 6 Bit IO Expander. Author RWB. Target PICJazz 2. PIN Board PIC1. 8F1. K2. 2. Compiler Microchip C1. C Compiler. IDE Microchip MPLAB IDE v. Programmer PICKit. Firmware Suite Version 0. Last Updated 1. Aug 2. PIC1. 8F1. 4K2. 2 Configuration Bit. FOSC IRC Internal RC Oscillator. PLLEN OFF PLL is under software control. PCLKEN ON Primary Clock Enable. FCMEN OFF Fail Safe Clock Monitor disabled. PWRTEN OFF Power Up Timer disabled. BOREN OFF Brown out Reset disabled in hardware and software. WDTEN OFF WDT is controlled by SWDTEN bit of the WDTCON register. MCLRE ON MCLR pin enabled, RE3 input pin disabled. LVP OFF Single Supply ICSP disabled. FOSC IRC, PLLEN OFF, PCLKEN ON. FCMEN OFF, BOREN OFF, PWRTEN OFF. WDTEN OFF, MCLRE ON, LVP OFF MCP2. S1. 7 SPI Slave Device. SPISLAVEID 0x. SPISLAVEADDR 0x. A20,A10,A00. define SPISLAVEWRITE 0x. SPISLAVEREAD 0x. MCP2. S1. 7 Registers Definition for BANK0 default. IODIRA 0x. 00. define IODIRB 0x. IOCONA 0x. 0A. define GPPUA 0x. C. define GPPUB 0x. D. define GPIOA 0x. GPIOB 0x. 13static rom unsigned char ledpatern3. Delay in 1 ms approximately for 1. MHz Internal Clock. Delay. 1KTCYx4. SPIWriteunsigned char addr,unsigned char data. Activate the SS SPI Select pin. PORTCbits. RC6 0 Start MCP2. S1. 7 Op. Code transmission. SSPBUF SPISLAVEID SPISLAVEADDR lt lt 1 0x. E SPISLAVEWRITE Wait for Data TransmitReceipt complete. SSPSTATbits. BF Start MCP2. S1. 7 Register Address transmission. SSPBUF addr Wait for Data TransmitReceipt complete. SSPSTATbits. BF. Start Data transmission. SSPBUF data Wait for Data TransmitReceipt complete. SSPSTATbits. BF CS pin is not active. PORTCbits. RC6 1. SPIReadunsigned char addr. Activate the SS SPI Select pin. PORTCbits. RC6 0 Start MCP2. S1. 7 Op. Code transmission. SSPBUF SPISLAVEID SPISLAVEADDR lt lt 1 0x. E SPISLAVEREAD Wait for Data TransmitReceipt complete. SSPSTATbits. BF Start MCP2. S1. 7 Address transmission. SSPBUF addr Wait for Data TransmitReceipt complete.