본문 바로가기

IT

(15)
Linux Kernel uImage에 Device Tree를 하나로 만들기 1. System 구성상 uImage와 device tree가 하나의 이미지로 되어야 하는 경우가 있다. 본 문서에 적용한 Linux Kernel은 TI 에서 배포한 Kernel 4.19 이다 2. 참조 싸이트 https://e2e.ti.com/support/processors-group/processors/f/processors-forum/617841/linux-dra750-the-dtb-file-attached-to-the-kernel-image 3. 적용한 Makefile (1) 현재의 ROM 구성상 dtb와 uImage를 하나의 파일로 만들어여 함 (2) uImage에 Device Tree와 같이 빌드 - 앞의 내용을 참조하여 다음과 같이 "arch/arm/boot/Makefile"을 수정 함
Linux kernel AM335X PWM 설정 및 사용 1. PWM 사용법은 하기의 웹사이트 참조 한다. http://software-dl.ti.com/processor-sdk-linux/esd/docs/latest/linux/Foundational_Components/Kernel/Kernel_Drivers/PWM.html 3.2.4.11. PWM — Processor SDK Linux for AM335X Documentation Linux has support for Enhanced Pulse Width Modulator (ePWM) and Auxiliary Pulse Width Modulator (APWM) modules. APWM is Enhanced Capture (eCAP) module configured in PWM mode. These devic..
SQLite Tutorial (9): Online Backup https://developpaper.com/sqlite-tutorial-9-online-backup/ SQLite Tutorial (9): Online Backup - Develop Paper 1. Common backups: The following is a relatively simple and commonly used way to backup the SQLite database. See the following steps:Use SQLite API or shell tools to add shared locks to source database files.Copy database files to backup directories using developpaper.com 1. Common backup..
SQLite Tutorial (14): C Language Programming Example Code (2) https://developpaper.com/sqlite-tutorial-14-c-language-programming-example-code-2/ SQLite Tutorial (14): C Language Programming Example Code (2) - Develop Paper 3. Efficient batch data insertion: Before giving the steps, I will briefly explain the concept of batch insertion to help you read the following sample code. In fact, batch insertion is not a new concept. It provides some support in the ..
SQLite Tutorial (13): C Language Programming Example Code (1) https://developpaper.com/sqlite-tutorial-13-c-language-programming-example-code-1/ SQLite Tutorial (13): C Language Programming Example Code (1) - Develop Paper 1. Get Schema information for tables: 1. Create tables dynamically. 2. According to the API provided by sqlite3, get the information of table fields, such as the number of fields and the type of each field. 3. Delete the table. See the f..
Overflow in datagram type sockets IPC로 Unix Domain Socket를 사용하는 경우, 전송되는 packet은 기본적으로 10개의 데이타가 Queue 된다. 이 값을 변경하고자 하는 경우 아래를 참조하여 /etc/sysctl.conf에 적용 하자. 개인적으로는 TCP나 UCP 또는 UART등의 데이타를 특정 상황에 적용하다 보면 링버퍼나 리스트를 사용하는데 차라이 메세지 큐나 UDS(unix domain socket)를 사용하여 시스템의 queue영역에 저장하는것이 코딩하는데 편리 한듯 하다. busybox 에서 사용 하려면 /etc/sysctl.conf 를 다음과 같이 구성한다. -------------------------------------------------- net.core.rmem_max=256000 net.core..
bcd2bin Linux 커널 트리에 있는 함수 Test #include #include unsigned bcd2bin(unsigned char val) { return (val & 0x0f) + (val >> 4) * 10; } unsigned char bin2bcd(unsigned val) { return ((val / 10) 0x0b/11 bcd2bin(0x19) ==>0x13/19 bcd2bin(0x1a) not BCD ==>0x14/20 bcd2bin(0x20) ==>0x14/20 ==================================== bin2bcd(19) ==>0x19/25 bin2bcd(20) ==>0x20/32
Makefile에서 프로그램의 Build 버전을 자동으로 생성하고 싶을때 1 개요 가) Application을 빌드 할 때 마다, 자동으로 빌드의 숫자가 증가하여, 이를 프로그램에서 사용 할 수 있도록 하는 내용이다. 나) 참조 문서 ① http://www.linuxjournal.com/content/add-auto-incrementing-build-number-your-build-process 2 Number File 가) Application Directory 안에 빌드 넘버를 기록하는 파일을 만들고, make 가 수행 된 후에 이를 자동으로 증가 하게 한다. 나) 참조 문서 1에서는 link 옵션을 사용 하였으며, 문서 2에서는 define를 사용 하였다. ① Define 문을 사용하는 경우는 __DATE__, __TIME__을 사용 할 때와 마찬가지로, 쓰여진 해당 파..