1 / 31

Introduction to GUI Programming on Windows with XO

This textbook covers various topics in GUI programming on Windows using the XO framework. It includes chapters on installing Linux in a VM or cloud environment, creating processes with fork and server-client communication, creating threads for error diffusion, process synchronization, CPU scheduling, deadlocks, main memory and virtual memory utilization, mass storage structures using Docker and VMs, file system interfaces and implementations, I/O systems, protection, and security with Kali Linux, Blockchain, Bitcoin, and Libra. The course syllabus and textbooks are provided, along with instructions on how to set up the development environment using Visual Studio and the .NET framework.

greggd
Download Presentation

Introduction to GUI Programming on Windows with XO

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Textbooks Chapter 1: Introductionเขียนโปรแกรมที่มี GUI บน Windows เช่น XO Chapter 2: Operating-System Structures ติดตั้ง Linux ใน vm /cloud /flash drive Chapter 3: Processes สร้าง process ด้วย fork, server-client(socket) Chapter 4: Threads สร้าง thread (error diffusion) Chapter 5: Process Synchronization ลงทะเบียนใช้ AWS Cloud และศึกษาบทเรียนออนไลน์ Chapter 6: CPU Scheduling ลงทะเบียนใช้ AWS Cloud และศึกษาบทเรียนออนไลน์ Chapter 7: Deadlocksแก้ race condition Chapter 8: Main Memoryแก้ deadlock Chapter 9: Virtual Memorymemory utilization ของระบบและแต่ละ process Chapter 10: Mass Storage Structureการใช้ Docker, Container, Hypervisor, VM Chapter 11: File-System Interface RAID / NAS / SAN Chapter 12: File-System Implementation ติดตั้ง Network File System (NFS) Chapter 13: I/O Systems เลือกใช้ File System แบบใดดี Chapter 14: Protection สอบ Linux Commands Chapter 15: SecurityKaliLinux / Blockchain/ Bitcoin / Libra

  2. บังคับใช้ Visual Studio ให้ new project แบบ Windows Forms App (.NET Framework) ให้ใช้ภาษา C# หรือ Visual Basic เวลาส่งงานให้เปิด project จาก Visual Studio กด start debugging (F5)

  3. Course Syllabus http://pioneer.netserv.chula.ac.th/~achatcha/

  4. Textbooks https://drive.google.com/open?id=1hZcKi1pmSGxoQ3mqGr04vgpaBjDtmaAt

  5. VMware Linux Windows Mac OS OS1 OS2 OS3 VM1 VM2 VM3 VMware (user program) userprogram userprogram operating system (Windows) hardware

  6. An alternative to VMware • Oracle VM VirtualBox (host: Windows)http://www.virtualbox.org • Kernel-based virtual machine หรือKVM (host: Linux)http://kvm.qumranet.com • Xen (host: -)http://www.xen.org • ProxmoxVE (host: -)https://www.proxmox.com

  7. Choices of Guest OS • Everyone must install Ubuntu (desktop). • You can make a copy of Ubuntu and distribute it in the class. • Other Linux distributions are welcome. • http://en.wikipedia.org/wiki/Comparison_of_Linux_distributions • Linux is a good practice to understand theory, • please do the following quizzes by yourself.

  8. Quiz: process management Show kernel version Show kernel (file) and its size. Show CPU information. Run a process with lowest priority (least favorable). Run a process (longer 60 seconds), pause, and resume. Run a process (longer 60 seconds) in background, and terminate. Run two processes and connect them using a pipe. Run three processes in background, and bring the second to the front. Run three processes in background, and terminate the first. Show uptime (elapsed time since booting). Note: use the command “sleep” to make a process.

  9. Quiz: memory management Show memory information. Show amount of free and used memory in the system. Quiz: Storage management Make a file, rename, and delete. Make a folder, rename, and delete. Make a file and change permission so that only the owner can read. Make a file and change both owner and group to “root.” Create a symbolic link. Show disk space (harddisk) usage in human-readable format. Show file space usage of “/usr/share/dict/american-english” in human-readable format. Check and repair file system on harddisk. Search for a given filename.

  10. Quiz: User management Change password. Show on-line users. Show current users on the system and what they are doing. Enable administrator (root or superuser) account. Add a new user and remove. Quiz: Network management Remote login to Chula server (pylorus.it.chula.ac.th ของบุคคลากร). Transfer a file from Chula FTP (pylorus.it.chula.ac.th ของบุคคลากร). Send an email to someone. Show IP address of your computer. Show IP address of pylorus.it.chula.ac.th (or other servers). Show MAC address of your host computer. Show connection speed to Google.co.th (or other servers). Download a file through HTTP at 0.00AM (or other times).

  11. Quiz: Utility (1) Show the manual page of “man” command. Make a beep sound using “echo.” Change font color to green and background color to black (at a terminal). Show only the first 10 lines of /etc/passwd (or other text files). Show only the last 10 lines of /etc/passwd (or other text files). Show only the line containing “sys” in /etc/passwd (or other text files). Show only the line ending with “land” in /usr/share/dict/american-english. Count the number of lines in /usr/share/dict/american-english. Open /usr/share/dict/american-english in a text editor, and search for “microcomputer.” Make a text file, put your firstname, save and display each character sequentially in hex. Make a text file, put your firstname, encrypt with password protection. Write a program in C, compile, and execute. Write a program in C, compile, and redirect error message to a file. Run a process that will continue after logout. Shutdown in the next 10 minutes.

  12. Quiz: Utility (2) Make a folder with a file inside and compress it to “foldername.tar.gz.” Make a folder with a file inside and compress it to “foldername.zip” and make a checksum. Make two files (firstname and lastname), put them together using “cat,” “>,” and “>>.” Split /usr/share/dict/american-english into 10 files (x00 to x99). Show only the first column in /etc/passwd. Show printer queue. Show current date & time. Show calendar.

  13. สัดส่วนคะแนนคะแนนเก็บครึ่งเทอมแรก 25%สัดส่วนคะแนนคะแนนเก็บครึ่งเทอมแรก 25% คะแนนสอบกลางภาค 25% คะแนนเก็บครึ่งเทอมหลัง 25% คะแนนสอบปลายภาค25% การประเมินผลการศึกษา >= 85 ได้ A >= 80 ได้ B+ >= 75 ได้ B >= 70 ได้ C+ >= 65 ได้ C >= 60 ได้ D+ >= 55 ได้ D > 55 ได้ F

  14. จุฬาวิชาการ 2563 (2020) https://www.youtube.com/watch?v=6N4fs-2CbrU

  15. จุฬาวิชาการ 2563 (2020) 5233692323 ยิ่งยง เตชะยิ่งยงชัย, 5233691723 เมธิณี อนวัชกุล Cake decoration game for multi-touch screens

  16. จุฬาวิชาการ 2563 (2020) 5633661223 จิรายุ ช่างคิด, 5633667023 ชินวัฒน์ องอาจ Virtual Reality Broom Riding Game 5633684723 นารีรัตน์ พรมสา, 5633680123 ธนาพจน์ อภิรักษ์เสนาMobile Application : The Secret Chamber

  17. Introduction User program User program User program User program Manage resourcesProvide services Operating System CPU Memory Storage I/O devicesetc.

  18. Introduction Types of operating systems No operating systems Batch processing Single-tasking Multi-tasking Time-sharing Operating systems on PCs DOS Windows 3.11 Windows 95, 98, ME, XP, Vista, 7 Unix, Linux (GNU – GNU is Not Unix)

  19. No operating systems Connect the robot to PC. Load a program into robot’s memory. Set program counter (PC) to start address Execute the program. Halt. เครื่องใช้ไฟฟ้าง่ายๆ เช่น ทีวี ตู้เย็นมีโปรแกรมที่ทำงานเพียงโปรแกรมเดียว ไม่จำเป็นต้องมี OS

  20. Batch processing A job operating system (job queue) input (storage) job control (a file) - commands - output (storage, printer) Hardware CPU Memory Storage Printer

  21. Cooperative multi-tasking CPU Single-tasking Time Multi-tasking idle Advantage: reduce I/O waiting. Disadvantage: a long execution can block other processes. idle idle idle

  22. Preemptive multi-tasking(time sharing) 3 jobs (assume no I/O wait) are submitted almost at the same time(first-come, first-serve). CPU Time Time slice Advantage: quick response for all users/processes. This can be done by timer interrupt.

  23. OS 1 3 OS ตั้ง timer interruptแล้วกระโดดไปทำ P1 เกิด timer interruptOS ยึด CPU กลับไปคืน OS ตั้ง timer interruptแล้วกระโดดไปทำ P2 CPU ต้องมีฮาร์ดแวร์ที่เป็น timer interruptเพื่อสนับสนุน OS ที่ทำงานแบบ time sharing P1 2 P2

  24. DOS • single-user, single-task (no multi-tasking) • only text mode, no GUI

  25. Windows 3.1 uses cooperative multitasking - meaning that each application that is in the process of running is instructed to periodically check a message queue to find out if any other application is asking for use of the CPU and, if so, to yield control to that application. However, many Windows 3.1 applications would check the message queue only infrequently, or not at all, and monopolize control of the CPU for as much time as they required. A preemptive multitasking system like Windows 95 will take CPU control away from a running application and distribute it to those that have a higher priority based on the system's needs. • Windows 3.1x • Graphical user interface (GUI) • Cooperative multi-tasking

  26. Windows 95 • preemptive multi-tasking (time sharing) iOS เวอร์ชันแรก ๆ ยังไม่เป็น time-sharing เพลงจะหยุดเล่น เมื่อสลับไปใช้ web browser

  27. Linux • GUI is optional. • preemptive multi-tasking (time sharing)

  28. Process & Thread A process is a program loaded and being executed on computer. A thread is a light-weight process. (เหมือนมี main function หลายๆ อัน) free memory P1 process B process A T1 T2 T3 kernel No memory protections among threads under the same process.A program can produce multiple processes.

More Related