<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[008 Universal  Dev Learning || By 008 Universal]]></title><description><![CDATA[Master modern software development with 008 Universal Dev Learning by 008 Universal. Learn coding skills, web dev tools, and best practices today!]]></description><link>https://008universal.hashnode.dev</link><image><url>https://cdn.hashnode.com/uploads/logos/6acb51ac6e4cbce9179c844f/e9f2e570-72b3-4e37-a4c3-95d96e1fb6f8.png</url><title>008 Universal  Dev Learning || By 008 Universal</title><link>https://008universal.hashnode.dev</link></image><generator>RSS for Node</generator><lastBuildDate>Tue, 03 Nov 2026 04:39:14 GMT</lastBuildDate><atom:link href="https://008universal.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Magnific AI Review: The Tool That Makes Blurry AI Images Look Real]]></title><description><![CDATA[Magnific AI isn't a generator, it's an upscaler that adds real-looking detail to AI art. See how it works, what it costs and who should use it.]]></description><link>https://008universal.hashnode.dev/magnific-ai-review</link><guid isPermaLink="true">https://008universal.hashnode.dev/magnific-ai-review</guid><category><![CDATA[Magnific AI is an upscaler]]></category><category><![CDATA[Magnific AI is an upscaler, not a generator.]]></category><category><![CDATA[Magnific AI]]></category><category><![CDATA[Magnific AI review]]></category><category><![CDATA[ai image upscaler]]></category><category><![CDATA[upscale AI images]]></category><category><![CDATA[Magnific AI pricing]]></category><dc:creator><![CDATA[gudduroy1122334]]></dc:creator><pubDate>Sat, 24 Oct 2026 17:02:48 GMT</pubDate><enclosure url="https://cdn.hashnode.com/uploads/covers/6acb51ac6e4cbce9179c844f/97fdbf1d-99a2-436d-83b2-63b88f304255.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>If you’ve ever made something in Midjourney that looked great on screen and then fell apart when you zoomed in, this tool is for you.</p>
<h3>So what does it actually do?</h3>
<p>Normal upscalers just stretch pixels, and the result looks soft and waxy. Magnific does something different. Where other tools try to recover likely detail, Magnific invents it, hallucinating pores, threads, foliage and surface grain. Sometimes that looks stunning. Sometimes it rewrites your picture completely, and that depends on how far you push it.</p>
<p>You control this with a “creativity” slider. Keep it low and the image stays close to the original. Push it high and the tool starts making its own decisions. Some people love that and some hate it, so I’d say try it on a test image before you commit anything important.</p>
<h3>A quick bit of history</h3>
<p>Magnific was built by two Spanish founders, Javi Lopez and Emilio Nicolas, and was founded in 2023 and acquired by Freepik in May 2024. Since then things have moved around a lot. According to one 2026 roundup, its billing, credits and AI tools now run through the Freepik account system. Another source says Freepik itself rebranded as Magnific in 2026, and a third says the old Freepik-era docs now redirect to <a href="http://magnific.com">magnific.com</a>. The naming is confusing, I know. If you’re searching for the tool, expect to land on either site.</p>
<h3>Where it works best</h3>
<p>From what I’ve seen and read, it shines in a few places:</p>
<ul>
<li>AI art from Midjourney or similar tools that looks flat or smooth</li>
<li>Illustrations and game assets</li>
<li>3D renders and architecture visuals</li>
<li>Old, low-resolution photos you want to rescue</li>
</ul>
<p>It’s weaker when you need faithful results. If you’re working with a logo, a product photo, or a screenshot with text, the invented detail can change things you didn’t want changed. For that, one comparison notes the Precision mode preserves text, logos and UI pixels faithfully, while Creative mode is the one that gets artistic with it. Pick the mode based on whether changed pixels would be a problem for you.</p>
<h3>How big can you go?</h3>
<p>Marketing says up to 16x. In real use, one reviewer puts the practical limit closer to 8x. Honestly, you rarely need more than 4x for most work. Past a certain point you’re just asking the AI to imagine things.</p>
<h3>What does it cost?</h3>
<p>This is the part that stings a bit. Magnific isn’t cheap. Access through Freepik has been tied to the Premium+ plan at $39 per month, and one review lists the cost at roughly $0.05 to $0.20 per upscale, depending on size and settings. Prices change often, so check the current page before you subscribe. If you only upscale a few images a month, the subscription is hard to justify.</p>
<h3>A few tips if you try it</h3>
<ol>
<li>Start with the creativity slider low, then raise it slowly.</li>
<li>Use the prompt box. A short note like “fine painterly texture” can steer the result.</li>
<li>Don’t upscale to the maximum just because you can.</li>
<li>Always compare against the original. Zoom in and look at faces and hands first, since that’s where weird surprises hide.</li>
</ol>
<h3>The honest verdict</h3>
<p>Magnific is the best option I know of for adding believable detail to AI art. It’s also pricey, a bit unpredictable, and not what you want for anything that has to stay exact. If your work is creative, it’s worth a month’s trial. If your work is product shots or documents, a faithful upscaler like Topaz Gigapixel will probably serve you better.</p>
<p>Keywords: Magnific AI, Magnific AI review, AI image upscaler, upscale AI images, Magnific AI pricing, Freepik Magnific, AI image enhancer, Midjourney upscaler</p>
]]></content:encoded></item><item><title><![CDATA[Open AI Models You Can Run Yourself, and the Agent Security Problem Nobody Wants to Talk About]]></title><description><![CDATA[Meta, NVIDIA and others just dropped new AI models, and some are open for anyone to run. Here’s what it means for you, in plain English.]]></description><link>https://008universal.hashnode.dev/ai-news-october-2026-open-models-agent-security</link><guid isPermaLink="true">https://008universal.hashnode.dev/ai-news-october-2026-open-models-agent-security</guid><category><![CDATA[AI news this week]]></category><category><![CDATA[open weight AI models,]]></category><category><![CDATA[run AI locally,]]></category><category><![CDATA[Meta Muse Spark Open]]></category><category><![CDATA[AI agent security]]></category><category><![CDATA[Nemotron 3.5]]></category><dc:creator><![CDATA[gudduroy1122334]]></dc:creator><pubDate>Mon, 19 Oct 2026 09:29:08 GMT</pubDate><enclosure url="https://cdn.hashnode.com/uploads/covers/6acb51ac6e4cbce9179c844f/ef5335b3-7fb1-4158-8272-1ee272103055.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h3>1. Meta just released a big model you can actually download</h3>
<p>The headline for me was Meta’s <strong>Muse Spark Open</strong>. Meta released it on October 15, with 816 billion total parameters, 42 billion active parameters and a one-million-token context window</p>
<p>Those numbers sound abstract, so here’s what they mean:</p>
<ul>
<li><p><strong>Open weights</strong> means developers can download the model, not just rent access to it through an API.</p>
</li>
<li><p><strong>Active parameters</strong> are the part of the model doing the work at any moment. Only a slice runs at a time, which keeps it efficient.</p>
</li>
<li><p><strong>A million-token context window</strong> means you can feed it a huge codebase or a pile of documents in one go.</p>
</li>
</ul>
<p>This comes alongside Meta’s other launch this week. Muse Wonder and Muse Wonder Full were announced on October 12. Open weights are a separate track from those.</p>
<p><strong>Why you should care:</strong> if you build websites, apps or tools, you now have more choices than “pay per token to one company.” You can test locally, keep your data on your own machine, and control costs.</p>
<h3>2. NVIDIA is going after specialised agents</h3>
<p>NVIDIA also made a move. Its October 15 release introduced Nemotron 3.5 Super VL, a 120-billion-parameter visual model with 12 billion active per token. It’s aimed at specialised agents, meaning AI that doesn’t just chat but looks at screens, images and documents and then does something with them.</p>
<h3>3. Local AI is now a gadget category</h3>
<p>AI hardware is getting personal. Amazon announced Bee Frontier, a wearable personal AI device, and Bee Eclipse, a magnetic phone attachment. Whether people will wear these every day is still an open question, but the direction is clear: AI that sits with you all day instead of living in a browser tab.</p>
<p>If you want to see this stuff in person, the Open Intelligence Foundation is running Open Source AI Week across the San Francisco Bay Area from October 16 to 25, with more than 60 community events, including an on-device AI hackathon. Many of these events are worth following online even if you can’t attend.</p>
<h3>4. The uncomfortable part: agents are being used for attacks</h3>
<p>Here’s where the news gets serious. Gambit Security detailed fully automated hacking services that use open-source AI tools to continuously attack hundreds of sites for relatively low per-attack costs. In plain words, attacks that once needed skilled people can now be run on autopilot, cheaply and at scale.</p>
<p>Companies are reacting. Security teams are rushing out playbooks, and a new RSA platform aims to discover, protect and govern AI agents in heavily regulated organisations. One startup, Opsin, raised a growth round to expand its product that maps agent ownership, permissions and runtime actions.</p>
<p><strong>What this means for regular users and small site owners:</strong></p>
<ol>
<li><p><strong>Update everything</strong>: CMS, plugins, frameworks. Automated attackers love old versions.</p>
</li>
<li><p><strong>Use strong, unique passwords and 2FA</strong>, because credential theft is the easy target.</p>
</li>
<li><p><strong>Give AI tools the minimum access they need.</strong> If an agent doesn’t need your email, don’t connect it.</p>
</li>
<li><p><strong>Check your logs now and then.</strong> Odd traffic spikes are often the first sign.</p>
</li>
</ol>
<h3>5. Big Tech is spending like never before</h3>
<p>One more number puts all this in context. Coverage from October 18 cites roughly $750 billion of 2026 capex, per Bloomberg Businessweek, from the largest tech companies. The same roundup reports that Microsoft dropped a deal to rent 23,000 Nvidia chips at a UK site run by Nscale. Even at this scale, compute is the scarce resource, and the companies are still shuffling who gets it.</p>
<h3>So what should you do this week?</h3>
<ul>
<li><p><strong>Learners and students:</strong> try a small open model locally. Running one yourself teaches you more about how AI works than any article.</p>
</li>
<li><p><strong>Developers:</strong> look at open weights for projects where privacy or cost matters, but treat agent permissions as a security issue from day one.</p>
</li>
<li><p><strong>Site owners:</strong> patch, back up and turn on 2FA. It’s boring advice that works.</p>
</li>
<li><p><strong>Everyone else:</strong> be a little skeptical of “AI will do it all for you” claims, and stay curious.</p>
</li>
</ul>
<h3>Final thoughts</h3>
<p>This week showed two sides of the same trend. Open and local AI is giving ordinary people and small teams real power. The same openness is lowering the cost of automated attacks. The people who do well will be the ones who learn the tools and also take safety seriously.</p>
<p><em>What was your favourite AI story this week? Let me know in the comments.</em></p>
]]></content:encoded></item><item><title><![CDATA[Tech News This Week (October 2026): Windows 11 26H2, Apple HomeView, Faster Chrome and AI Coding Agents]]></title><description><![CDATA[Latest tech news for developers and beginners: Windows 11 26H2, Apple HomeView, faster Chrome updates and AI coding agents, explained simply.]]></description><link>https://008universal.hashnode.dev/tech-news-october-2026-windows-11-26h2-apple-homeview</link><guid isPermaLink="true">https://008universal.hashnode.dev/tech-news-october-2026-windows-11-26h2-apple-homeview</guid><category><![CDATA[Developer]]></category><category><![CDATA[engineering]]></category><category><![CDATA[software development]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Google]]></category><category><![CDATA[Windows]]></category><dc:creator><![CDATA[gudduroy1122334]]></dc:creator><pubDate>Sun, 18 Oct 2026 08:02:57 GMT</pubDate><enclosure url="https://cdn.hashnode.com/uploads/covers/6acb51ac6e4cbce9179c844f/b7861d1b-bdca-4c29-945e-5ad1975b680a.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h2>1. Windows 11 26H2 Is Now Available</h2>
<p>Microsoft released <strong>Windows 11 version 26H2</strong> (also called the <strong>Windows 11 2026 Update</strong>) on September 29, 2026. It is a small update, not a big redesign. It arrives as an "enablement package" (KB5121794), so installing it feels like a normal monthly update: a small download and a restart.</p>
<p><strong>Key facts:</strong></p>
<ul>
<li><p>It works on PCs that already run Windows 11 version 25H2 or 24H2.</p>
</li>
<li><p>PCs running version 26H1 cannot install it, because 26H1 is built on a newer platform.</p>
</li>
<li><p>Installing it restarts the support clock. Reports say you get about 24 months of support on home editions and 36 months on business editions.</p>
</li>
</ul>
<p><strong>Why it matters for developers:</strong> If you build or test software on Windows, you do not need to worry about big compatibility problems. Microsoft describes this release as predictable and low-disruption. It is still smart to test on one machine first before updating all of your computers.</p>
<h2>2. Apple HomeView: A $299 Smart Display With the New Siri</h2>
<p>On October 13, 2026, Apple announced <strong>HomeView</strong>, a smart home display with a 7-inch touchscreen on a speaker base. It costs <strong>$299 in the US</strong> and goes on sale on <strong>November 13</strong>. There is a tabletop version and a wall-mounted version.</p>
<p><strong>What it does:</strong></p>
<ul>
<li><p>Controls lights, locks, thermostats and cameras.</p>
</li>
<li><p>Makes FaceTime calls, plays music and video, and works as a digital photo frame.</p>
</li>
<li><p>Uses face recognition so each family member sees their own home screen and widgets.</p>
</li>
<li><p>Works with Matter and Thread smart home devices.</p>
</li>
<li><p>Runs the new, more conversational "Siri AI". According to AFP, it is built on Google Gemini technology.</p>
</li>
</ul>
<p>This is also one of the first big launches under Apple's new CEO John Ternus, who took over from Tim Cook on September 1.</p>
<p><strong>Why it matters for designers and developers:</strong> HomeView shows a new kind of screen. The interface changes depending on how far away the person is standing, and it adapts to who is looking at it. If you study UI/UX, this is a great example of designing for different distances, different users and voice plus touch together.</p>
<h2>3. AI Coding Agents Are Moving Into Your Daily Tools</h2>
<p>AI coding helpers are no longer just chat boxes that suggest a line of code. They are becoming "agents" that can take a task, work on it and send back finished changes for you to review.</p>
<ul>
<li><p>At Microsoft Build 2026, GitHub introduced the <strong>GitHub Copilot app</strong>, a desktop app where developers can start, watch and guide several AI coding agents at once, then review and merge their work through normal pull requests.</p>
</li>
<li><p>Earlier in 2026, GitHub added <strong>Claude and OpenAI Codex</strong> to its <strong>Agent HQ</strong> feature, so developers can choose different agents inside GitHub and VS Code.</p>
</li>
</ul>
<p><strong>Beginner advice:</strong> AI can write code fast, but it can also make mistakes. Learn the basics first (HTML, CSS, JavaScript, Git, how a backend works). Then use AI as an assistant, and always read and test the code before you trust it.</p>
<h2>4. Chrome Now Updates Every Two Weeks</h2>
<p>Google Chrome moved to a <strong>two-week release cycle</strong> starting with Chrome 153 on September 8, 2026. Before this, new versions came about every four weeks. This means web developers get new features faster.</p>
<p><strong>Recent web platform features include:</strong></p>
<ul>
<li><p>Single-axis scroll containers (Chrome 153).</p>
</li>
<li><p>Capability elements for camera and microphone (Chrome 153).</p>
</li>
<li><p>Joint Iteration in JavaScript (Chrome 153).</p>
</li>
<li><p>The Prompt API, which lets websites use on-device Gemini Nano, arrived earlier in Chrome 148.</p>
</li>
</ul>
<p>Also, the last Manifest V2 extension listings were removed from the Chrome Web Store on August 31, 2026. If you build Chrome extensions, they must use Manifest V3.</p>
<p><strong>Tip for web developers:</strong> Before using a brand-new feature, check browser support on MDN or Can I Use so your site works for everyone.</p>
<p>What These Updates Mean for Beginners</p>
<ol>
<li><p>Learn fundamentals first. Tools change every month, but HTML, CSS, JavaScript, Git and basic system design stay useful.</p>
</li>
<li><p>Use AI as a helper, not a replacement. Review everything it writes.</p>
</li>
<li><p>Think beyond the phone screen. Smart displays, wall screens and voice interfaces need new UX thinking.</p>
</li>
<li><p>Keep up with browser updates. Faster Chrome releases mean new web features arrive sooner.</p>
</li>
<li><p>Test before you update. Even "small" OS updates can affect your tools.</p>
</li>
</ol>
<h2><strong>Frequently Asked Questions</strong></h2>
<p><strong>Is Windows 11 26H2 a big update?</strong> No. It is a small enablement-package update that turns on features already delivered during the year and refreshes the support period.</p>
<p><strong>When can I buy Apple HomeView?</strong> Apple says it goes on sale in the US on November 13, 2026 for $299.</p>
<p><strong>Do AI coding agents replace developers?</strong> No. They handle tasks like bug fixes and refactoring, but developers still plan, review, test and decide what to ship.</p>
<p><strong>How often does Chrome release new versions now?</strong> Since Chrome 153 (September 8, 2026), about every two weeks.</p>
<h2>Conclusion</h2>
<p>This week's tech news shows three big trends: AI is becoming part of everyday developer tools, hardware is becoming smarter and more personal, and the web platform is moving faster. Keep learning, keep building, and check back next week for more updates.</p>
<p><em>Sources: Windows Central, Microsoft Windows documentation, AFP, Good Morning America, Dexerto, Pulse 2.0, ChannelLife, Chrome for Developers, Supercharge</em></p>
]]></content:encoded></item><item><title><![CDATA[Tech This Week: AI Gets More Agentic, Cybersecurity Gets More Urgent, and the World Rebuilds Its Digital Rules]]></title><description><![CDATA[Latest global tech news: AI agents, cyberattacks, smart devices, AI wearables, and the biggest technology trends shaping 2026.]]></description><link>https://008universal.hashnode.dev/tech-this-week-ai-gets-more-agentic-cybersecurity-gets-more-urgent-and-the-world-rebuilds-its-digital-rules</link><guid isPermaLink="true">https://008universal.hashnode.dev/tech-this-week-ai-gets-more-agentic-cybersecurity-gets-more-urgent-and-the-world-rebuilds-its-digital-rules</guid><category><![CDATA[AI]]></category><category><![CDATA[Developer]]></category><category><![CDATA[news]]></category><category><![CDATA[blog]]></category><category><![CDATA[web dev]]></category><category><![CDATA[frotend]]></category><category><![CDATA[backend]]></category><dc:creator><![CDATA[gudduroy1122334]]></dc:creator><pubDate>Fri, 16 Oct 2026 11:20:11 GMT</pubDate><enclosure url="https://cdn.hashnode.com/uploads/covers/6acb51ac6e4cbce9179c844f/2f3fb98d-a9a2-4bcf-b75d-d05d4e3c5509.jpg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Technology is moving faster than most organizations can secure it. This week’s biggest stories converge around one theme: powerful AI is becoming embedded in everyday products, while governments and security teams scramble to manage the risks.</p>
<h2>AI moves from chatbot to operating layer</h2>
<p>AI is no longer just answering questions in a browser. OpenAI has expanded its GPT-6 family with cheaper models, while Google is building laptops around Gemini and Apple and Meta are reportedly working together to bring a major open-weight AI model to high-end Macs.</p>
<p>The shift is toward <strong>AI as an interface for computing</strong>: writing code, managing apps, interpreting context, and acting across services. The Verge reports that ChatGPT can now view Chrome tabs, a small feature that signals a much larger change—AI assistants are beginning to operate inside the user’s digital workspace rather than waiting in a separate chat window.</p>
<p>But capability is outpacing control. Anthropic has warned that self-replicating AI-powered malware could eventually spread through connected smart-home devices, raising concerns that ordinary IoT products could become part of a larger attack chain.</p>
<h2>Cybersecurity becomes a global infrastructure problem</h2>
<p>The most urgent tech story this week is not a flashy product launch—it is the growing fragility of digital infrastructure.</p>
<p>A cyberattack on contractor BAE Systems disrupted the notice system used by U.S. federal bankruptcy courts, showing how attacks on a single supplier can ripple into public services. Microsoft’s October Patch Tuesday fixed 1,411 vulnerabilities, including three zero-days, while BeyondTrust disclosed a critical Remote Support flaw that has been exploited since August.</p>
<p>For businesses, the lesson is simple: <strong>vendor risk is now enterprise risk</strong>. Security teams need to track not only their own software, but also the contractors, cloud services, remote-support tools, and connected devices in their supply chain.</p>
<h2>Smart homes enter the threat model</h2>
<p>Smart devices were once treated as convenience gadgets. They are now part of critical infrastructure.</p>
<p>In France, attackers reportedly tampered with supermarket refrigeration systems, causing temperatures to rise as high as 50°C, spoiling food and creating fire and equipment risks. CERT-FR initially linked the incidents to compromised remote-control systems made by Danfoss.</p>
<p>This matters because smart homes, retail refrigeration, building controls, and industrial IoT often share the same weakness: remote access. As AI agents gain more autonomy, attackers may use them to scan, adapt, and spread across networks faster than traditional defenses can respond.</p>
<h2>Governments redraw the rules of the internet</h2>
<p>Regulators are also moving quickly.</p>
<p>The European Union has proposed strict age limits for social media, games, and AI assistants, including a ban on social media for children under 13 and limited supervised access until age 15. Australia’s government has introduced digital duty-of-care legislation that would give users an “off switch” for recommender algorithms.</p>
<p>Meanwhile, AI copyright remains a global flashpoint. OpenAI and Anthropic have pressed Australia to reconsider its restrictions on training AI models with the country’s creative content, arguing that a narrow exemption could protect artists while attracting investment.</p>
<p>The emerging global pattern is clear: countries want innovation, but they increasingly want <strong>sovereignty, safety, and accountability</strong> built into the technology stack.</p>
<h2>Hardware and consumer tech: the AI PC era expands</h2>
<p>Consumer hardware is also being reshaped by AI.</p>
<ul>
<li><p>Google has begun taking pre-orders for “Googlebook,” a new laptop category built around Gemini and aimed at Android users.</p>
</li>
<li><p>Apple has started rolling out iOS 27, including its long-delayed Siri AI overhaul.</p>
</li>
<li><p>Amazon is showing new “Bee” personal AI wearables that listen to conversations and suggest actions—products that immediately raise privacy questions.</p>
</li>
<li><p>Tesla finally revealed its next-generation Roadster after nearly a decade of delays, amid speculation about deeper Tesla–SpaceX integration.</p>
</li>
</ul>
<p>The common thread is that hardware is becoming a delivery mechanism for AI services. That creates convenience, but it also means more microphones, sensors, cameras, and behavioral data in people’s homes and pockets.</p>
<h2>What to watch next</h2>
<ol>
<li><p><strong>AI agent safety</strong> — Expect more scrutiny of models that can browse, use tools, and take actions without constant human approval.</p>
</li>
<li><p><strong>Supply-chain security</strong> — The BAE Systems incident and widespread zero-day exploitation show why third-party risk management is now board-level work.</p>
</li>
<li><p><strong>AI regulation</strong> — Age limits, copyright rules, algorithmic transparency, and AI safety laws will define the next phase of the internet.</p>
</li>
<li><p><strong>Privacy-first AI devices</strong> — Wearables and smart-home products will face pressure to prove that “always listening” does not mean “always recording.”</p>
</li>
</ol>
]]></content:encoded></item><item><title><![CDATA[Fundamentals of creating an 8-bit homebrew OS]]></title><description><![CDATA[The code in your homebrew computer’s ROM probably contains all kinds of useful functions. But how do you get to them?]]></description><link>https://008universal.hashnode.dev/fundamentals-of-creating-an-8-bit-homebrew-os</link><guid isPermaLink="true">https://008universal.hashnode.dev/fundamentals-of-creating-an-8-bit-homebrew-os</guid><category><![CDATA[coding]]></category><dc:creator><![CDATA[gudduroy1122334]]></dc:creator><pubDate>Mon, 12 Oct 2026 09:38:15 GMT</pubDate><enclosure url="https://cdn.hashnode.com/uploads/covers/6acb51ac6e4cbce9179c844f/0f026a56-c408-4514-a945-c55004c5d3f6.webp" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Building your own 8-bit homebrew computer typically goes something like this: you get the clock, CPU, RAM and some address decoding up and running; you hardcode some simple instructions to test that it works, but then quickly advance to burning that code — and much more — into an EEPROM; and then you finally get to the point where you want to load user code into RAM and run it. But this presents an issue.</p>
<p>The code in your ROM (which is what we’ll call the EEPROM to save me some typing) is responsible for all the fundamental stuff that is crucial to the operation of the computer. It is essentially an operating system. This code includes I/O — reading input and writing output to whatever sources and destinations you have — perhaps some maths routines, and a whole host of functions that most, if not all, of your user programs need. You can always relegate some less-critical functions to library files that you include into your program code. But putting the code in the ROM has the benefit of not wasting valuable RAM. It’s always available — all you have to do is call it. But that’s the snag.</p>
<p>Before we go on, however, a word of warning. I have no idea how you write an operating system. What you’re about to read is how I did it. And it works, which is encouraging. However, I’m not claiming this is the best way to do it.</p>
<h3><strong>Changing locations</strong></h3>
<p>My personal homebrew computer, the <a href="https://medium.com/machina-speculatrix/subpage/0b8cf602629b">Zolatron</a>, is built around the 65C02 CPU, so all the example code here is going to be 6502 assembly — specifically for the Beebasm assembler. But the concepts should transfer to pretty much anything.</p>
<p>What we’re going to be dealing with here are functions (aka subroutines). With the 6502, you call them with <code>jsr &lt;address&gt;</code> (jump to subroutine followed by its 16-bit address in the memory map). The function ends with <code>rts</code>, the equivalent, more or less, to the <code>return</code> keyword in higher level languages.</p>
<p>The problem we have is that address. What is it?</p>
<p>Let’s say you have a function in the ROM that reads a byte from the input stream (in the Zolatron’s case, that’s a serial port) and the function for doing that is at address $DCC8 in the ROM. So our user program code just needs to use the line:</p>
<p>jsr $DCC8</p>
<p>When the code returns from that function, the byte will be in the accumulator. Job done. So where’s the problem?</p>
<p>Yes, the function is at $DCC8 — for now. But if I make a change to the ROM code and burn a new copy, it’s entirely possible, and even quite likely, that the location of that routine will have changed. Now all my user programs are broken.</p>
<p>And trying to remember, even with the aid of pencil and paper, the addresses of all the OS functions is a nightmare, as well as asking for trouble. Sure, you could keep documentation telling you where the functions live, but that’s an additional maintenance chore and one subject to error.</p>
<h3><strong>The benefits of labels</strong></h3>
<p>Within a specific program, we get around this annoying habit through the cunning use of labels. Let’s take a look at the code for that ‘read byte’ function:</p>
<p>.read_byte</p>
<p>.read_byte stz FUNC_RESULT stz FUNC_ERR ldx STDIN_IDX .read_byte_next lda STDIN_BUF,X beq read_byte_EOB ; 0 means end of buffered text sta FUNC_RESULT inx ; For next time stx STDIN_IDX jmp read_byte_end .read_byte_EOB ; At the end of the buffer lda #ERR_EOB sta FUNC_ERR lda STDIN_STATUS_REG ; Clear the STDIN flags in the status reg and #STDIN_CLEAR_FLAGS sta STDIN_STATUS_REG stz STDIN_IDX ; Reset index stz STDIN_BUF .read_byte_end rts</p>
<p>(By the way, if you want to follow along, all the code for this project is in the Zolatron GitHub repository. You’ll find the above code in the ROM / include / funcs_io.asm file.)</p>
<p>Note the .read_byte label at the start. During assembly, this label will contain the address of the first instruction of the routine (stz in this case). Elsewhere in the ROM code, to call this function we just use jsr read_byte. The assembler handles the task of replacing the label with the appropriate address.</p>
<p>The catch is that this convenience is restricted to other code in the same program. Any other program you write will have absolutely no idea what you mean by read_byte.</p>
<p>If we want to call that handy subroutine that’s in the ROM from user code, how do we do that? The answer is, indirectly.</p>
<p>Jump tables The first step is to build a jump table. This is a list of jump instructions and we place these instructions at locations in the ROM code that won’t change. We’ll also assign the addresses of these instructions to constants that we can include in our user code. (As they are just constants used to insert values at assembly time they don’t increase the size of the resulting machine code.)</p>
<p>I’ll admit I was slightly influenced by the BBC Micro when I chose names for these constants. The one I adopted for the ‘read byte’ function is OSRDBYTE and we’ll be following this throughout the article. You can call the constants anything you want.</p>
<p>Let’s set up our list of constants for various OS calls. I decided to put my jump table at address $FF00 (again, it’s your choice although they do need to be in the ROM space). The following definitions are in a file (LIB / cfg_main.asm) that gets included into every user program and well as the ROM code.</p>
<p>\ OS Function Address Table OSGETKEY = \(FF00 ; Get char, waits for user to enter a key &amp; return OSGETINP = OSGETKEY + 3 ; Create input loop OSRDASC = OSGETINP + 3 ; Get next printable char from STDIN_BUF OSRDBYTE = OSRDASC + 3 ; Read next byte from STDIN_BUF OSRDCH = OSRDBYTE + 3 ; Get next non-space printable char from STDIN_BUF OSRDHBYTE = OSRDCH + 3 ; Read 2 hex chars, convert to 8-bit int OSRDHADDR = OSRDHBYTE + 3 ; Read 4 hex chars, convert to 16-bit int OSRDINT16 = OSRDHADDR + 3 ; Read a 16-bit decimal ineteged from STDIN_BUF OSRDFNAME = OSRDINT16 + 3 ; Read string from STDIN_BUF; check valid filename OSRDSTR = OSRDFNAME + 3 ; Read string from STDIN_BUF \ ... and so on ... Now, jsr OSRDBYTE is the same as jsr \)FF09, but a lot easier to read and remember. And OSRDBYTE will alwaysbe at $FF09.</p>
<p>You’ll notice that the addresses assigned are three bytes apart. That’s because the code we’re going to put at each of those addresses consists of a jump (jmp) instruction, which is one byte long, and a two-byte address.</p>
<p>Next, we set up the jump table itself. This lives only in the ROM code and in my case is in the main program file (z64-main.asm). We set the origin to $FF00, then have a list of jmpinstructions each of which points to a corresponding vector address (more on that in a moment). Again, we're just using constants for those addresses, not direct values.</p>
<p>\ OS Call Jump Table ORG \(FF00 jmp (OSGETKEY_VEC) jmp (OSGETINP_VEC) jmp (OSRDASC_VEC) jmp (OSRDBYTE_VEC) jmp (OSRDCH_VEC) jmp (OSRDHBYTE_VEC) jmp (OSRDHADDR_VEC) jmp (OSRDINT16_VEC) jmp (OSRDFNAME_VEC) jmp (OSRDSTR_VEC) \ ... and so on ... This table has to be in the exact same order as the one above and have the same number of entries. That’s because this whole technique works by using offsets. For example, the constant OSRDBYTE is the fourth item in the first list, and so will automatically pick up the address \)FF09. The corresponding instruction in the jump table is also the fourth item. And this is a theme we’ll come back to.</p>
<p>What’s the vector victor? So far, when you use the instruction jsr OSRDBYTE the assembler knows this means jsr $FF09 so goes to that address and picks up the next instruction which is jmp (OSRDBYTE_VEC). Like I said, it's just another constant holding the value of an address. But it's not the address of the function we're trying to reach. Or it is, but in a roundabout way.</p>
<p>This instruction is using indirection, or vectors if you prefer.</p>
<p>For this new list of addresses, I’ve used the same name as the previous list but just appended ‘_VEC’. Here’s the start of this bit of code which, again, gets included in all program code (the Zolatron file is LIB / cfg_page_2.asm):</p>
<p>\ OS Vector Location Table OSGETKEY_VEC = $0200 OSGETINP_VEC = OSGETKEY_VEC + 2 OSRDASC_VEC = OSGETINP_VEC + 2 OSRDBYTE_VEC = OSRDASC_VEC + 2 OSRDCH_VEC = OSRDBYTE_VEC + 2 OSRDHBYTE_VEC = OSRDCH_VEC + 2 OSRDHADDR_VEC = OSRDHBYTE_VEC + 2 OSRDINT16_VEC = OSRDHADDR_VEC + 2 OSRDFNAME_VEC = OSRDINT16_VEC + 2 OSRDSTR_VEC = OSRDFNAME_VEC + 2 \ ... and so on ... Again, we need to have the same number of entries in the same order as the previous tables.</p>
<p>I chose to have these addresses in Page 2 of the memory map, which is in RAM.You can choose any convenient area in RAM, but RAM it must be. This time, the addresses the constants point to are two bytes apart because what’s going to be found at each address is just another 16-bit address.</p>
<p>In the case of our OSRDBYTE call, the jmp (OSRDBYTE_VEC) is interpreted by the assembler as jmp ($0206). But $0206 is not the address to which execution actually jumps. Those parentheses indicate that this in an indirection. What actually happens is that the processor checks what values are stored in locations $0206 and $0207 and uses those as the target address.</p>
<p>Remember that our read_byte function is at address $DCC8, and that the 6502 is little endian. To complete the process, we need to have stored the value $C8 at address $0206 and $DC at $0207. The processor constructs the address $DCC8 and jumps to that.</p>
<p>You may have noticed that, so far, we have set up two tables of constants and the jump table with values that need never change.</p>
<p>Actual addresses Finally, we get to the bit where we tell a program where the ROM functions exist. The required code is part of the ROM’s initialisation routine. Each OS call gets an entry looking something like this:</p>
<p>lda #&lt;read_byte ; OSRDBYTE sta OSRDBYTE_VEC lda #&gt;read_byte sta OSRDBYTE_VEC + 1 This code takes the low byte of the address of the OS function and writes it to the vector address. Then it takes the high byte and writes it to the vector address + 1. Remember that this is ROM code, so when you assemble the ROM firmware it knows the location of functions such as read_byte and can replace the labels with appropriate addresses. The same goes for the constants. So the assembler actually sees this code as:</p>
<p>lda #&lt;DCC8 ; OSRDBYTE sta $0206 lda #&gt;DCC8 sta $0206 + 1 You can see why using constants and labels is much easier.</p>
<p>I’ve shown the entry just for the read_byte function, even though you need an routine like this for every OS call, because the order in which you set them up isn't important. There's no offsetting like before.But keeping them in the same order as the other tables makes sense from a code maintenance perspective.</p>
<p>How it works Let’s do a run-through of how all of this comes together.</p>
<p>When the machine is booted, the ROM code runs and, one by one, reads the addresses of OS functions and stores them in a table in Page 2 of RAM.</p>
<p>When you run a user program, if it includes the instruction jsr OSRDBYTE, the processor reads this as jsr $FF09(because we gave it that list of constants). So it jumps to $FF09 thinking it's going to find the OS function. But it actually encounters the instruction jmp (OSRDBYTE_VEC), which it interprets as jmp ($0206). It looks to see what values are stored in locations $0206 and $0207, which happen to be $C8 and $DC and subsequently makes a jump to $DCC8, where it finally encounters the ROM's read_byte function.</p>
<p>Press enter or click to view image in full size Diagram showing how looking up the address of a ROM function works. Note that all these OS functions must end with rts (return from subroutine) because we started this journey with jsr.</p>
<p>This might seem convoluted. But because it’s all based around labels and constants, there’s no need to keep track of (or even know) the actual addresses of functions or the OS calls.</p>
<p>As the three main tables all have corresponding entries in the same order, we’re effectively just using offsets into tables (a bit like offsets into arrays). In our code, we just use the constants for the OS calls and let the assembler take care of the details. If you edit the code so that the actual address of the OS function changes, this method automatically takes care of that.</p>
<p>Much jumping If this all feels like a lot of jumping around, I can understand, but it really isn’t.</p>
<p>Other than the original jsr instruction in the user code (which you need anyway), there is just one additional jump to get to the function code. Of the four blocks of code we've examined that make up this process, two are just definitions of constants, one is a table of addresses that is created automatically on boot-up and the jump table is the only one that contains actual (indirect) jump commands.</p>
<p>There is, by the way, another benefit from doing it this way. As we saw, that final jump instruction lives in RAM. Your user program could actually change the address to which this OS call indirects, replacing it with its own routine. All it has to do is modify the address stored in $0206 and $0207.</p>
<p>When writing a user program, I just need to include the two files with the constant declarations. It looks like this:</p>
<p>INCLUDE "../../LIB/cfg_main.asm" INCLUDE "../../LIB/cfg_page_2.asm" ; OS Indirection Table Now, all the OS functions are available from any user program. Just remember to keep an eye on the order of those first three tables. And if you add a new OS function in ROM, you need to update all four of the code blocks. But you never need to worry about where OSRDBYTE is hiding.</p>
<p>You can find all the stories related to this project on the Zolatron feature page.</p>
<p>There is also a GitHub Zolatron repo with the code, datasheets and other documents.</p>
]]></content:encoded></item></channel></rss>