Giter Site home page Giter Site logo

pmandin / cleancode Goto Github PK

View Code? Open in Web Editor NEW
8.0 2.0 0.0 548 KB

Example source code for using the Atari hardware using all possible systems functions

License: GNU General Public License v2.0

Makefile 0.77% Assembly 3.96% C 85.12% Shell 9.95% M4 0.20%
atari-st atari-falcon coding-standards tutorial-code m68k

cleancode's People

Contributors

pmandin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

cleancode's Issues

Bug in Mxalloc() detection

atari_mxalloc_avail = ((Sversion()&0xFF)>=0x01) | (Sversion()>=0x1900);
contains quite a suspicious code:

  • it checks for major GEMDOS version 1.x (is there such?)
  • it uses | instead of || for the check but it works by chance because previous condition always (?) fails

Getrez() + 2 is an unreliable way how to detect resolution

As discussed in our email conversation, there are at least two scenarios where I got vdi_vd.ttp crash in Falcon's 640x480@256c:

  • if not using NVDI without AES (i.e. AUTO folder or FreeMiNT console), work_in[0] = Getrez() + 2 doesn't really work on Falcon. Getrez() produces a wrong number, leading VDI to believe that 640x480x8 is 640x400x1 in fact (in its work_out fields).
  • if using NVDI without AES, you can't really write into the screen address. For some reason it seems the screen buffer is smaller than the actual resolution (perhaps related to off-screen bitmaps?). Try to boot into FreeMiNT console and run your vdi_vd.ttp - it will crash, badly (at least in 640x480x8)

In both cases, replacing work_in[0] = Getrez() + 2; with work_in[0] = 1; fixes the issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.