Hacker Newsnew | past | comments | ask | show | jobs | submit | more codezero's favoriteslogin

This is similar to the Uzebox, which also uses a single microcontroller and full software video signal generation.

http://uzebox.org/wiki/Main_Page


Shameless plug: A friend of mine and I made a game[1] for a jam that works the other way around. The goal is to manually fiddle with the coefficients to recreate a given shape.

It gives an easy way to play with the coefficients and hopefully allows the player to gain some intuitions. For example how some combinations of frequencies lead to rotational symmetry and why negative frequencies are necessary.

It's not very polished, though. I made a mistake while writing the algorithm that checks whether the shape is matching. It causes some false negatives in certain situations. There might also be some issues with dragging the controls on Mac OS.

[1] https://coldiv.itch.io/fouriershaper


Tip: If you want to escape from any ssh session you can press this sequence:

1. <Enter> Press Enter.

2. ~ Press Tilde.

3. . Press dot.

This disconnects from the remote host.

If you want more: `man ssh` and look for "ESCAPE CHARACTERS"


This is either something written by GPT-3, or the human equivalent. Zero substantive content, pure regurgitation.

I didn't know you could embed CSS animations in an SVG file.

It's a thing of beauty: https://nyan-sat.com/assets/licensed/orbital_comparison.svg

Be sure to view page source.


Just skimming some of the replies here makes me think you will get better advice on the Bogleheads forum [1]. Despite the minimalist appearance it is actually a great place to get sensible financial advice. I would start with the wiki page on managing a windfall [2], then search through older replies to similar questions. This kind of question gets asked there a lot, so there should be some recent threads.

[1] https://www.bogleheads.org/ [2] https://www.bogleheads.org/wiki/Managing_a_windfall


The memory map hurts.

68000 doesn't have a vector base register like 010+. Instead, the vector base is always 0x0, which here is in ROM, which is too much of a restriction. Installing a 010 instead should allow for getting around this.

Also blatantly missing is a NMI switch.

Still, it always makes me happy when I see open SBC designs based on the 68k family. Retrobrew[0] has a bunch of them, and they are less restrictive, or use 030 instead of 000/010.

[0]: https://www.retrobrewcomputers.org/


The most interesting part of this is how it works, which this article is kinda light on.

It uses the "wave function collapse" procedural generation technique (has been on the frontpage before if I recall correctly) to select fitting tiles when the player clicks on the map to build something.

https://github.com/mxgmn/WaveFunctionCollapse

In the section about notable forks, ports and spin-offs there are some links to Oskar Stalsberg's twitter showing various points along the development of this digital toy.

https://github.com/mxgmn/WaveFunctionCollapse#notable-ports-...

I've been following this for years and it is really inspiring to see this be so successful.

I have the feeling that digital toys will become more common when gamedevs get access to things like GTP-3 seens like a really natural fit to me, supporting the creativity of the player by filling in blanks in a sufficiently advanced way.


Here's a FORTH program to simulate a 7 bit paper tape puncher. Type PTAPE <cr> and then start typing. It will terminate and cut the tape when you type a <null>.

    \ FORTH PAPER TAPE PUNCHER:

    : PT# ( L --- L/2 )
      DUP 1 AND IF 
        ASCII @ 
      ELSE BL THEN
      HOLD
      2/
    ;

    : PT. ( N --- )
      <# PT# PT# PT# 
         ASCII . HOLD
         PT# PT# PT# PT#
      #> TYPE
    ;

    : CUT
      ." -----------" CR
    ;

    : PTAPE
      CUT
      BEGIN
        KEY ?DUP WHILE
        DUP ." |" PT. ." |"  SPACE EMIT CR
      REPEAT
      CUT
    ;
PS: I rewrote PTAPE in PostScript for NeWS, so it makes a window with actual holes punched into it in the shape of a piece of paper tape with the text you pass in as a parameter:

https://www.donhopkins.com/home/archive/news-tape/fun/ptape/...

Can anybody write that for X11 using the SHAPES extension to punch the holes in fewer lines of code? ;)

(The comments about an elliptical canvas and round shape must have been copied from some other old code, because the shape of the window (and icon) it makes is rectangular with lots of round holes punched into it.)


Cool project! You might already know about this, but if you don't, this is an excellent course on implementing an 8-bit computer, and might answer your questions about the instruction set. https://eater.net/8bit

I tried to track down that converter for a retro computing project about 10 years ago and failed; https://stackoverflow.com/questions/2038929/where-can-i-find...

A few months ago I returned to the project and completed it this time; https://github.com/billforsternz/retro-sargon

As I should have realised the first time, you can write your own converter in an afternoon or two :-)


It seems we rediscover Gilbert Ryle's knowing-how vs knowing-that distinction every few years.

https://en.wikipedia.org/wiki/Gilbert_Ryle or if you are so inclined

https://plato.stanford.edu/entries/knowledge-how/

Note: if you have a computer and it can be "told" once and forever remember it, then converting know-that into know-how by teaching it 100s of if-then rules was, at one point, considered a worthy research program.


The generic drug industry in the US is pretty unique. Thanks to the Waxman-Hatch generic drug bill in 1984, it went from really hard to get a generic drug approved in the US (you had to start from scratch) to really easy (just prove your drug is the same and use the branded drugs data for approval).

As a result, the generic drug industry in the US is very competitive. When a blockbuster drug like Liptior goes generic, you have up to a dozen companies vying to be the first generic approved because that gets you 180 days of exclusivity (you're the only generic, you're cheaper, everyone switches to you). Typically the first generic is priced around 90% of the brand name price (most of it profit), but once other generic companies get approval (after 180 days), the price drop to 5-10% of the branded drug price. This is typically very close to the cost of manufacturing. There are also "generic substitution" laws in most states that require pharmacists to fill prescriptions with the generic. So once the patent runs out, the branded drug loses sales very fast.

As a result, the US usually has lower generic drug prices than the EU or Canada.[1] And generic drugs tend to get approval very quickly after the patent expires in the US.

However, on the flip side, because the market is so competitive, margins are razor thin. If you want to understand the generic drug market, read the book "The First Question" by Andrew Bodnar. He was convicted by the DOJ for anti-competitive practices as a VP at BMS and wrote the book as a part of his sentencing (book is on the public record). The quote that stuck with me was from Barry Sherman of Apotex (massive Canadian generic drug company). It was something along the lines of "I make zero profit off my drugs. All my profit comes from winning settlements from pharma companies".

As a result of the razor thin margins, weird things start to happen. The first is price fixing, as per this article. Nobody wants to compete on price in generic markets (though that's the only differentiator between identical drugs!) because their margins already suck. Allegedly, these companies colluded to not drop prices.

The other thing that happens is companies just say "screw it" and drop out of the market. Why not? The profit margin is near zero. This is especially true with companies selling sterile fill product (i.e. injectables). It's really freakin hard and expensive to run a sterile fill plant, so when something goes wrong, companies often just shut down the line.

What happens? Drug shortages. Prices rises.

Then what happens? Some small company realizes everyone else dropped out of the market. So they quietly get their generic approved and jack the price as high as they can. You'll see a drug that was $0.10 per tablet go to $10 per tablet. Then this attracts other competitors (or sometimes it doesn't), prices drop and the cycle starts again.

[1] Can't find exact study, but here's an FDA study comparing generic drug prices between US and Canada: https://www.fda.gov/drugs/resources-you-drugs/study-us-gener...


Lichtheim edited a 3-volume "Ancient Egyptian Literature" which contains a lot of funerary inscriptions. I'd second wl's post above: if you don't have tolerance for really dull writing, avoid.

Almost all of that "genre" is of the "seen one, seem them all" variety. Most of it's very formulaic—think nicene creed or traditional church hymns, but less interesting. There were a bunch of standard texts that were reproduced on many tombs, and as time went on this body of necessary texts grew, so that's very likely what a lot of this is. Sometimes you'd get some passages of history but those are usually about as dry as the tombs themselves. More often those are on monuments, not buried in tombs, anyway.

"Mirrors for princes" (instruction texts for rulers, often both moral and practical in nature), scribal training texts (yes, really), and their few actual stories that survive, are all way more interesting than the stuff inscribed in tombs, in general. A lot of those don't survive in hieroglyphs, though, but in hieratic or demotic script.


It simulates a simple model of a quantum computer, so that you can implement and test out quantum algorithms, albeit at potentially huge computational cost.

quantum.country is a good introduction to quantum computing for people with no background other than linear algebra. Even if you don't understand linear algebra you could probably skim it and get a sense for what's going on.


I got into machine rebuilding after buying a reasonable 1950's machine shop worth of equipment a few years ago when I started in the auto industry after my master's degree. I happened onto a Craigslist ad of a machine rebuilder going out of business near the office and I picked up basically the whole kit -- cast iron surface plates, power and hand scrapers, bluing medium, etc etc. It took another 6 months before I ran into a guy who was willing to teach me to use all that equipment, up near Flint. He spent a whole career doing fitting and repair for a CNC dealer traveling all over the state and a piece of the rest of the midwest. He was just about the nicest guy I've ever done business with, and he supplies equipment and advice to a huge percentage of the Youtube machinist crowd, plus he saved me the couple grand it would have cost to go take one of Rich King's classes.

All in all, this is a great skill that will persist for a long time, longer than you might think, even if modern machines use replaceable linear rails rather than scraped ways. If you feel like taking it up, watch one of the many Youtube videos from Stefan Gotteswinter or Keith Rucker. Look into the equipment, but think about building your own carbide sharpener, scraper and handle.


I've been working through https://guyinatuxedo.github.io/ while reading "The Shellcoder's Handbook" and Sam Bowne's class notes (https://samsclass.info/127/127_F19.shtml). Highly recommended

I think the beauty of it is the that's it!? feeling you get once you've looked through all ~500 lines --- based on the amount of functionality one would expect it to be much longer; but it is unexpectedly short, yet complete.

For a just-as-interesting "sequel", look at C4x86: https://github.com/EarlGray/c4


If you're looking for a modern compilers class -- including the theory of why this stuff works -- I highly recommend Matt Might's [0]. All of the notes, slides, and code are online.

I audited Might's "Compilers" this spring. He live-coded a parser that parsed with derivatives, returning all possible parse trees whenever there were ambiguities in the grammar. [1] (Try getting that from yacc, or basically any other tool in existence right now.)

All of his coding was done in Racket scheme. At the beginning he told us we could use whatever for the projects, but doing certain things in C++ / Java / Python / some imperative language was "like bringing a knife to a gun-fight."

The final project was a working Python -> C translator.

Really badass class.

[0] http://matt.might.net/teaching/compilers/spring-2013/

[1] http://matt.might.net/articles/parsing-with-derivatives/


50 Things that Made the Modern Economy is one of my favorite podcasts!

For anyone who finds this article (slash podcast episode) interesting, I'd also recommend the episode on the Hollerith punch card, which is kinda relevant to the history of the computing field :)

Hollerith punch card episode page: https://www.bbc.co.uk/programmes/w3csz2x7

The article for this episode (i.e. same format as main link): https://www.bbc.com/news/business-50578234


PBS Space Time have done a number of episodes on the holographic principle[1]

I strongly recommend anyone interested in physics check out the channel

[1] https://www.youtube.com/watch?v=klpDHn8viX8


META-II is a paper worth reading. I wrote a self-hosting parser generator in Forth based on that paper[0].

[0] https://github.com/siraben/meta-yacc/blob/master/meta.fs


A similar probably more well presented site: https://float.exposed/0x40490fdb

That probably depends more on the listener than on the story!

I played MUDs for several years, at the same time that I was learning the ins and outs of programming. I developed some plugins for a popular third-party client called MUSHclient. The game I played also had a somewhat proprietary first-party client, and they used a spare Telnet option (one left unassigned by IANA [1]) to pass data from the server to the client to drive some extra graphical widgets on their client. I got involved in developing plugins that made use of that data, which led me to learning how to negotiate that option with the server and get the data I wanted.

I eventually started developing my own MUD client, which is where the Telnet stack came in. Now, writing a Telnet stack is just something I do when I learn a new language. It's just large enough of a project to exercise some architectural and API-level concerns.

[1] If you're curious, all of the formally allocated Telnet options are documented here: https://www.iana.org/assignments/telnet-options/telnet-optio...


As someone with a PineTime Dev Kit on their desk in front of them, I would say that “just not sealed/glued shut” is not the entire story. Sure, you could glue it shut. But you would be stuck with somewhat bog standard software that is neither exciting nor updateable unless you hook the device up via Serial Wire Debug (SWD) to flash it – which requires yet another piece of kit to achieve. PINE64 are not joking around when they state that: “The PineTime Dev Kit [is] aimed solely for development purpose only, this is not for end user[s] who [are] looking for [a] ready to wear Smart Watch. More specifically, [we] only intend for these units to find their way into the hands of developer[s] with extensive embedded OS experience and an interest in Smart Watch development.” [1].

That being said, I have had a lot of fun learning embedded systems over the holidays and highly recommend getting a dev kit if you want a rewarding hobby that is likely to contribute to this watch coming out “for real” with a lot of fun software some time next year. Admittedly my reading list is very Rust biased, so feel free to ignore parts of it. But I highly recommend the embedded Rust “Discovery Book” [2] and “The Embedded Rust Book” [3]. Also, anything written by Lup Yuen Lee (李立源) so far has had the highest quality of all writing related to PineTime development. The only downside is that it is on Medium (yuck!), but do start with the one where he breaks his PineTime open for the first time and go from there [4]. There is also of course the PineTime sub forum [5]. Lastly, if you are new to embedded systems (such as myself) it may also be worth getting the development board that corresponds to what is inside the PineTime [6]. Happy reading and hacking!

[1]: https://store.pine64.org/?product=pinetime-dev-kit

[2]: https://docs.rust-embedded.org/discovery

[3]: https://docs.rust-embedded.org/book

[4]: https://medium.com/swlh/sneak-peek-of-pinetime-smart-watch-a...

[5]: https://forum.pine64.org/forumdisplay.php?fid=134

[6]: https://www.nordicsemi.com/Software-and-Tools/Development-Ki...


One of my best friends did his Masters work designing a programming language that can be modified on the fly; I'd highly recommend the paper:

https://dspace.mit.edu/bitstream/handle/1721.1/113144/101799...


Very, very nice.

His presentation library is available as well!

https://codesurfer.pomb.us/

https://github.com/pomber/code-surfer/blob/code-surfer-v2/re...



A nice article to quickly understand Tcl defining features is "Tcl the Misunderstood": http://antirez.com/articoli/tclmisunderstood.html

And some previous HN discussion on the article:

https://news.ycombinator.com/item?id=7069642

https://news.ycombinator.com/item?id=4920831

Edit: grammar



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: