forked from kevinboone/kevinboone.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathC-groupindex.html
165 lines (112 loc) · 23.7 KB
/
C-groupindex.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Kevin Boone: C</title>
<link rel="shortcut icon" href="https://kevinboone.me/img/favicon.ico">
<meta name="msvalidate.01" content="894212EEB3A89CC8B4E92780079B68E9"/>
<meta name="google-site-verification" content="DXS4cMAJ8VKUgK84_-dl0J1hJK9HQdYU4HtimSr_zLE" />
<meta name="description" content="%%DESC%%">
<meta name="author" content="Kevin Boone">
<meta name="viewport" content="width=device-width; initial-scale=1; maximum-scale=1">
<link rel="stylesheet" href="css/main.css">
</head>
<body>
<div id="myname">
Kevin Boone
</div>
<div id="menu">
<a class="menu_entry" href="index.html">Home</a>
<a class="menu_entry" href="contact.html">Contact</a>
<a class="menu_entry" href="cv.html">CV</a>
<a class="menu_entry" href="software.html">Software</a>
<a class="menu_entry" href="articles.html">Articles</a>
<form id="search_form" method="get" action="https://duckduckgo.com/" target="_blank"><input type="text" name="q" placeholder="Search" size="5" id="search_input" /><button type="submit" id="search_submit">🔍</button><input type="hidden" name="sites" value="kevinboone.me" /><input type="hidden" name="kn" value="1" /></form>
</div>
<div id="content">
<h1>C</h1>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="74hc595.html">Using a shift register to control eight digital outputs with three GPIO lines on the Raspberry Pi</a><p>A simple and inexpensive shift register can be used to increase the digital output provision of a Raspberry Pi or microcontroller. This well-know technique is easy to apply, but has some limitations that require careful consideration.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="adc.html">Using an I2C analog-to-digital converter chip with the Raspberry Pi, from the ground up</a><p>This article is about using an I2C analogue-to-digital device for applications like reading sensor values or monitoring backup batteries. With all the technical bits left in.</p><p style="font-size: smaller">Categories: <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a>, <a href="electronics-groupindex.html">electronics</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="adc_thermistor.html">Using an I2C analog-to-digital for temperature measurement on the Raspberry Pi</a><p>This article describes how to do simple temperature measurement with a Raspberry Pi, and I2C analog-to-digital converter, and a thermistor.</p><p style="font-size: smaller">Categories: <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a>, <a href="electronics-groupindex.html">electronics</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/antenna.png"/><a href="amqp-proton.html">Using the Qpid Proton C++ library to understand AMQP</a><p>AMQP is not a trivially-straightforward protocol to understand, but it's necessary to get to grips with it to write effective software that uses the Qpid Proton AMQP library. Perhaps one of the simplest ways to understand AMQP is to use Proton's own packet-tracing features, as this article explains.</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="middleware-groupindex.html">middleware</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/terminal.png"/><a href="console_media_keys.html">Using media keys in a Linux console application</a><p>Mapping keyboard keys to key codes on Linux is well-documented for the graphical desktop. But what about console applications on embedded Linux systems? There's not much documentation in this area.</p><p style="font-size: smaller">Categories: <a href="Linux-groupindex.html">Linux</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/terminal.png"/><a href="cpicom.html">Running CP/M on the Raspberry Pi Pico microcontroller</a><p>This article introduces CPICOM -- an emulator for CP/M 2.2 on the Raspberry Pi microcontroller.</p><p style="font-size: smaller">Categories: <a href="retrocomputing-groupindex.html">retrocomputing</a>, <a href="Pico-groupindex.html">Pico</a>, <a href="C-groupindex.html">C</a>, <a href="Z80-groupindex.html">Z80</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/terminal.png"/><a href="cpm-c.html">Getting back into C programming for CP/M</a><p>This article is about how programming for CP/M, usng a 40-year-old C compiler, differs from modern C development, even for console applications.</p><p style="font-size: smaller">Categories: <a href="retrocomputing-groupindex.html">retrocomputing</a>, <a href="C-groupindex.html">C</a>, <a href="Z80-groupindex.html">Z80</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/terminal.png"/><a href="cpm-c2.html">Getting back into C programming for CP/M -- part 2</a><p>Using the 1989 HI-TECH C compiler on CP/M, and some general observations about CP/M programming with real hardware.</p><p style="font-size: smaller">Categories: <a href="retrocomputing-groupindex.html">retrocomputing</a>, <a href="C-groupindex.html">C</a>, <a href="Z80-groupindex.html">Z80</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/terminal.png"/><a href="cwordle.html">cwordle -- A Wordle-like word-guessing game for CP/M</a><p>Building a CP/M implementation of the notorious Wordle game.</p><p style="font-size: smaller">Categories: <a href="retrocomputing-groupindex.html">retrocomputing</a>, <a href="C-groupindex.html">C</a>, <a href="Z80-groupindex.html">Z80</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/display.png"/><a href="fbtextdemo.html">Using the FreeType library to render text nicely onto a Linux framebuffer</a><p>Writing graphical applications for minimal and embedded Linux systems can present a challenge. One of the problems is producing nicely-rendered text without the facilities that a graphical desktop would provide. This article describes how to use the FreeType library to render text to the Linux framebuffer.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/c-logo.png"/><a href="gcc-embed-data.html">Embedding resources into executables built using GCC</a><p>Sometimes it's helpful to be able to create an executable program that embeds all the data it needs, and provide that data as files. C/C++ do not provide any standard way to do this, but GCC has facilities that the developer can use.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/c-logo.png"/><a href="gcc_bss.html">Why 'int x = 0' is uninitialized data to the GNU C compiler</a><p>An oddity of the GCC C compiler that can lead to strange results, particularly in an embedded application</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/c-logo.png"/><a href="gcc_warnings.html">The importance of enabling compiler warnings in C and C++ programming</a><p>I see too many C (and C++) programs misbehave at runtime, for reasons that could easily have been detected using checks built into all modern compilers. This article describes some common C programming errors, and shows how they would have been spotted easily if the compiler were configured correctly.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/display.png"/><a href="im-font-test.html">Using ImageMagick to generate anti-aliased bitmap fonts for a microcontroller's LCD display</a><p>This article describes how to generate and use compressed, anti-aliased font data, for use in a microcontroller application.</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/terminal.png"/><a href="kcalc-cpm.html">Developing KCalc-CPM -- a scientific calculator utility for CP/M</a><p>My first CP/M program for nearly 40 years -- how, and why, I wrote it.</p><p style="font-size: smaller">Categories: <a href="retrocomputing-groupindex.html">retrocomputing</a>, <a href="C-groupindex.html">C</a>, <a href="Z80-groupindex.html">Z80</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="keyboard11x55.html">Building a custom mechanical keyboard from scratch</a><p>There are many kits and plans available for constructing miniature mechanical keyboards. But what do you do if you want a layout the nobody else seems to use? Build it from scratch.</p><p style="font-size: smaller">Categories: <a href="Arduino-groupindex.html">Arduino</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/life3d_logo.jpg"/><a href="life3d.html">Conway's Game of Life in 3D perspective</a><p>Implementing a program to run Conway's cell population simulation, using a 3D perspective view on the Linux framebuffer.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/display.png"/><a href="linuxfbc.html">Using the Linux framebuffer in C/C++ -- just the essentials</a><p>The absolute minimum information needed to start using the Linux framebuffer as a graphical display in C/C++ applications.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a>, <a href="embedded_computing-groupindex.html">embedded computing</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/display.png"/><a href="linuxfbc2.html">Using the Linux framebuffer in C/C++ -- just the essentials (part 2)</a><p>This article continues my original framebuffer just the essentials article, by describing how to handle less straightforward framebuffer configurations.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a>, <a href="embedded_computing-groupindex.html">embedded computing</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/lua-logo.png"/><a href="lualib.html">Building a Lua extension library for Linux in C/C++</a><p>Lua is an embeddable scripting language, which can be extended in a number of useful ways. This article describes in detail how to create a Lua extension in C (or, with a bit of fiddling, C++) as a loadable (.so) library.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="Lua-groupindex.html">Lua</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/hc-sr04-03.jpg"/><a href="pi-hcsr04.html">Getting reasonably robust proximity measurements from an ultrasonic sensor on the Raspberry Pi</a><p>The HC-SR04 proximity sensor is an inexpensive and widely-used ultrasonic device. Connecting one to an HC-SR04 to a Raspberry Pi is a common educational exercise, but getting accurate, repeatable measurement of distance in a real application is actually quite difficult. This article explains why, and what can be done to improve matters.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pi-ina219.html">Monitoring an INA219 chip in a Raspberry Pi battery-backed power supply</a><p>Many battery-backed power supplies for the Raspberry Pi, and similar systems, use the INA219 current/voltage monitor IC. This device has an I2C interface by which the Pi can determine the battery voltage and current, and estimate the charge level and run-time. This article describes how to write C code that interacts with the INA219.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pi-lcd.html">Using an HD44780 LCD display module with the Raspberry Pi, from the ground up</a><p>In this article I explain how to construct, and program in C, an I<sup>2</sup>C interface to the popular HD44780 LCD display for the Raspberry Pi. Between the article and the accompanying source code, no technical details are concealed: I present the complete hardware design and every line of C code needed to operate it.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/pi.png"/><a href="pi-servo.html">The costs and benefits of software pulse-width modulation on the Raspberry Pi</a><p>The Raspberry Pi doesn't offer much in the way of analog outputs, or even hardware controlled PWM. Software-controlled PWM is an alternative in some applications, but it needs to be used carefully, if inefficiencies are to be avoided.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Raspberry_Pi-groupindex.html">Raspberry Pi</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pico-ds3231.html">Using the Maxim DS3231 I2C real-time clock in C on the Raspberry Pi Pico</a><p>The Maxim DS3231 I2C real-time clock is a reasonably accurate, inexpensive device, that is easy to interface to the Raspberry Pi Pico.</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pico7219.html">Controlling a chain of MAX7219 LED matrices using C on a Raspberry Pi Pico</a><p>The MAX7219 IC is widely used to control an 8x8 matrix of LED, but they can be chained to create much larger displays. This article describes how the chaining works, and how to create a driver for the Raspberry Pi Pico.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pico_run_ram.html">Raspberry Pi Pico: loading code into RAM and running it -- part 1</a><p>This is the first of (at least) two articles on loading and running arbitrary executable code into RAM on the Pico, and running it.</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pico_run_ram2.html">Raspberry Pi Pico: loading code into RAM and running it -- part 2</a><p>This is the second of (at least) two articles on loading and running arbitrary executable code into RAM on the Pico, and running it.</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pico_usb_kbd_lcd.html">Some thoughts on using a USB keyboard with the Raspberry Pi Pico</a><p>The Pi Pico has USB host support, and can work with a USB keyboard. Although there are some programming examples, the general approach to programming USB host operations is not well documented.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="picoflash.html">Using flash memory as non-volatile storage on the Pi Pico microcontroller</a><p>The Pi Pico is an impressive microcontroller for its size and cost, but it lacks specific non-volatile memory. This article explains how to use the program flash ROM for that purpose.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Pico-groupindex.html">Pico</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/pro-micro.jpg"/><a href="pro-micro-blink.html">Using Linux command-line tools for programming the SparkFun Pro Micro microcontroller (and similar)</a><p>Although building and deploying a simple program to an Arduino board is a point-and-click operation using the Arduino IDE, implementing more complex programs requires more robust build tools. This article describes how to build on Linux using command-line tools -- a process that is nowhere near as easy as it should be. If we can build using command-line tools, we can manage a project using Makefiles and similar techniques.</p><p style="font-size: smaller">Categories: <a href="Arduino-groupindex.html">Arduino</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/pro-micro.jpg"/><a href="pro-micro-key-test-1.html">Building and programming a USB keypad from the ground up</a><p>The first step towards designing and building a custom keyboard, from the very first principles, using an Arduino-type microcontroller.</p><p style="font-size: smaller">Categories: <a href="Arduino-groupindex.html">Arduino</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="pro-micro-usb-lcd.html">C-to-parallel IC</a><p>Make an auxiliary LCD display for a computer that displays data sent to it over a USB connection. Ready-made devices of this sort are widely available, but it's more fun to build your own.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="Linux-groupindex.html">Linux</a>, <a href="embedded_computing-groupindex.html">embedded computing</a>, <a href="Arduino-groupindex.html">Arduino</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/gears.png"/><a href="quarkus-native-c.html">Comparing a natively-compiled Java webservice with C</a><p>Implementing a webservice in C and Java, to see which performs better in terms of throughput and resource usage.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="Java-groupindex.html">Java</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/integral.jpg"/><a href="rationalize.html">Converting a floating-point number to a fraction (approximately) using continued fraction expansion</a><p>A detailed description of a method for performing this common numerical conversion, with C source code.</p><p style="font-size: smaller">Categories: <a href="mathematics-groupindex.html">mathematics</a>, <a href="C-groupindex.html">C</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="rc2014-rtc.html">Some thoughts on a DS1302 real-time clock board for RC2014/Z80 and CP/M</a><p>Constructing and programming a real-time clock board for my Z80 CP/M system</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="electronics-groupindex.html">electronics</a>, <a href="Z80-groupindex.html">Z80</a>, <a href="retrocomputing-groupindex.html">retrocomputing</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/chip.png"/><a href="rc2014_files_linux.html">Exchanging files between an SC130 CP/M board and a Linux system</a><p>This article describes a couple of methods for sharing data and code between a CP/M system with RomWBW BIOS and a Linux system.</p><p style="font-size: smaller">Categories: <a href="C-groupindex.html">C</a>, <a href="electronics-groupindex.html">electronics</a>, <a href="Z80-groupindex.html">Z80</a>, <a href="retrocomputing-groupindex.html">retrocomputing</a></p>
</div>
<div class="article-desc"><img class="article-list-image" src="img/gears.png"/><a href="shnolib.html">C development for Linux without a standard library</a><p>There are relatively few good reasons for writing C code without using a standard C library. However, doing so provides valuable insights into how compilers and operating systems work, and is worth doing if only for its educational value.</p><p style="font-size: smaller">Categories: <a href="software_development-groupindex.html">software development</a>, <a href="C-groupindex.html">C</a>, <a href="embedded_computing-groupindex.html">embedded computing</a></p>
</div>
<p><span class="footer-clearance-para"/></p>
</div>
<div id="footer">
<a href="rss.html"><img src="img/rss.png" width="24px" height="24px"/></a>
<span class="last-updated">Last update Nov 05 2024
</span>
</div>
</body>
</html>