Insert Credit Art Jam 2.0 | February 2023 | Machines


[size=30][color=Mediumpurple]_SHORTEST MONTH AND EVEN MORE LATE THAN USUAL_[/color][/size] -

[size=1]i'm sorry[/size]

_**To those new to the concept:**_
A monthly event in where the ever-growing Insert Credit community can come together and create art based on a rotating topic! First created and hosted by @"SuperEffective"#337, now taken over by me. Everyone is welcome to participate and create whatever they consider art. Every possible medium and art discipline is welcomed here. Go wild! Show us your hidden or not so hidden talents!

Here’s the original premise @"SuperEffective"#337 wrote:


This is not necessarily a contest, but more like a weekly monthly art challenge/show-and-tell. The plan is to introduce a new prompt every Sunday the first day of each month to make a piece of art to. To participate, you can simply post anything from a drawing, sculpture, crochet, animation, writing, a sick beat, heck, why not even a cake! You can post whenever you’re finished, and I’m sure none will mind if you’re a bit late as this thread is all in good fun. Heck, if you’re loving the prompt, post more than one! Send any suggestions you think would be fun to do in the next week, if you have any fun ideas!



[size=1000][color=hotpink] **Machines**[/color][/size]


[If you have any prompt ideas, feel free to submit them to this form.](

Once again, shout out to @"antillese"#59 for letting me know that February had already started without me noticing

You can read a more detailed introduction of the Art Jams 2.0 and see the amazing stuff y’all came up based on the previous prompt on the thread(s) linked below:

_**[March 2022 | Support and Cooperation](**_ -

_**[April 2022 | Delicious](**_ -

_**[May 2022 | Zones ](**_ -

_**[June 2022 | Slow ](**_ -

_**[August 2022 | purple (part II) ](**_ -

_**[September 2022 | LOUD!!!!!! ](**_ -

_**[October 2022 | Mysteerie ](**_ -

_**[November 2022 | Windy ](**_ -

_**[December 2022 | BIG ](**_ -

_**[January 2023 | Magic ](**_ -

I have the absolute worst idea for this one.

Nice! This may be the first time I participate.

Of loving grace!?

I never heard a single other song by this band after the crow soundtrack

@“exodus”#p104033 I picked up their “Concentration” album at a thrift shop last year and its very 90's Industrial, which I liked.

[upl-image-preview url=]

I‘m bad for not paying attention to or posting in these threads practically at all, probably because I’m scared of drawing

here's my submission. gotta be one of my favorite machines.

@“treefroggy”#p105589 1. me too, I am also scared 2. all two or three of your drawings I‘ve seen now I’ve loved so I hope you will consider sharing more of them.


@“TracyDMcGrath”#p103126 I have the absolute worst idea for this one.

Turn your headphones down, or, maybe even off for this one:

So what was that terrible idea? I figured the only place to go from making tracker mods natively on an Amiga last month would be to code the next song in machine language, get it? Machine....language, anyway....

No one can write in machine language though, so I did the next best thing, and wrote some 6502 assembly targeting the NES.

As @"antillese"#59 has explained in the context of much better NES songs, the NES has 5 audio channels. 2 pulse channels, a triangle channel, a noise channel, and a sample playback channel. The channels each have 4 bytes of memory mapped to the APU, which actually lives on the NES's modified 6502 CPU, but it gives us discrete bits of things that we can control and it handles most of the hard stuff for us without having to code anything. Most NES games have songs written in some external tool like a tracker, and then a subroutine in the program rom loads in those songs into the APU on a per frame basis from rom, no direct fiddling with the APU required. But I ask you, where's the fun in that?

We're going to write a simple program to load in randomly generated garbage into the APU channels, and then we're going to turn the channels on and off by increasing the APU flag counter at $4015 and then resetting it in a 16 beat cycle. This will create "music" in so far as it will be pitched notes in a repeated order, as music was defined by the [Criminal Justice and Public Order Act 1994]( Ready? Let's jam!

First we're going to set up the iNES header. We don't need anything fancy so we're setting it to the NROM mapper (or lack thereof) that SMB 1 uses.

``` 6502 .segment "HEADER" .byte "NES" .byte $1a .byte 02 ; progrom .byte 01 ; charrom .byte 00 ; nrom mapper .byte 00, 00, 00, 00 .byte 00, 00, 00, 00, 00 ```

Then we're going to declare some variables in the zeropage, the first 256 bytes of memory that's fastest to access

``` 6502 .segment "ZEROPAGE"

frame: .res 1
beat: .res 1
seed: .res 2 ; for randomness

Then we're going to set up our program rom, most of this is boiler plate like setting up memory and waiting for the crt that we're hypothetically plugged into to cycle twice so we know we're ready to rock

``` 6502

.segment “STARTUP”



ldx #%10000000
stx $4017
ldx #$00
stx $4010

ldx #$00

ldx #$00
stx $2000
stx $2001

bit $2002
bpl :-


sta $0000, x
sta $0100, x
sta $0300, x
sta $0400, x
sta $0500, x
sta $0600, x
sta $0700, x
lda #$ff
sta $0200, x
lda #$00
cpx #$00
bne clearmem

bit $2002
bpl :-

lda #$02
sta $4014


lda #%10010000
sta $2000 ; nmi on vblank

lda #%00011110
sta $2001 ; turn on graphics<i>


Now we're going to initialize our counters and our random seed and get ready for our main loop

``` 6502
; initialize counters
lda #$00
sta frame
sta beat

; initialize the seed to non zero or else it will always be 0
lda #$01
sta seed+0
sta seed+1

; turn pulse on to start
lda #$01
sta $4015

    ; loop forever and wait for interupts 
	jmp forever<i>


Now in our main loop we're going to fill our APU with garbage and increase the channel on off flags in $4015 to 00010000 and then loop back to 00000001 for, uh "music". The bits in the byte at $4015 turns on things as follows : nothing nothing nothing sample noise triangle pulse2 pulse1

``` 6502
jsr prng ; set the a register to a random value to store in everything

sta $4000
sta $4001
sta $4002
sta $4003
sta $4004
sta $4005
sta $4006
sta $4007
sta $4008
sta $4009
sta $400a
sta $400b
sta $400c
sta $400d
sta $400e
sta $400f
sta $4010
sta $4011
sta $4012
sta $4013

lda frame
cmp #$1d
bne incframe
lda #$ff ; if we're at 30 prepare to roll over
sta frame
; if we're at 30 increment the beat counter
inc $4015 ; change what's playing every beat
lda beat
cmp #$10
bne incbeat
lda #$ff ; if we're at 16 prepare to roll over
sta beat
   ; if we're at 16 reset the seed
lda #$01
sta seed+0
sta seed+1
sta $4015

inc beat
inc frame

ldy #8
lda seed+0

rol seed+1
bcc :+
eor #$39
bne :–
sta seed+0
cmp #0


Finally set up where the interrupts are and then where our non existent character rom lives:

``` 6502
.segment “VECTORS”
.word nmi
.word reset
.segment “CHARS”


Voila we have.....something that sounds awful. But hey! It's audible!

If you want to fiddle around with NES programming, I learned how to do most of this from the truly exhaustive NES dev wiki here:

@“TracyDMcGrath”#p106113 This rules and is very cool. Thanks as always for sharing! And thanks for teaching me about the Anti EP!

My entry is going to be a few days “late” as if that means anything. Next weekend at the worst so I won’t eat into my time for March.

@TracyDMcGrath is this repeatable/deterministic? I know you’ve got an MP3 recording there, but is the pseudorandom generation stable in that application given the same seed? I doubt it would be on a modern processor, but that A203 isn’t exactly famous for being secure in its RNG!

@“antillese”#p106134 good question and I‘m not sure! I’m using an rng subroutine from the wiki, and while I am resetting the seed to the same thing and the zeropage is relatively stable, I don't understand the rng gen subroutune well enough to know for certain if it will always return the same result for the same seed.

@“TracyDMcGrath”#p106113 This is really neat! It fits with how I was thinking about the prompt this month too, insofar as creating a system that outputs pseudorandom stuff within a range. I need to scan in my drawings, and they‘re honestly not much, but I’d still like to share what I've been scratching at this month.

@treefroggy @connrrr No one is bad at drawing. All you need to be good at drawing is the will to draw.

@“tomjonjon”#p106392 Nah, it‘s not that, I used to draw a lot, got more of a complex surrounding drawing for social media, now I only doodle for pragmatism or when it’s for myself. You could say I‘m all drawled out. That’s why I am posting 10 year old scribbles haha

@“tomjonjon”#p106392 I have tons of baggage from being doted on about it as a kid and also perfectionist tendencies and I'm still working through it lol

@“connrrr”#p106397 Its a tough hurdle to get over, I know, but perfection has no place in art. The imperfections are the style.

@“antillese”#p106117 @TracyDMcGrath That EP is some of my favorite Autechre.

i tried to upload some pics but it ain't working!

@“DavidNoo”#p106501 I am also having this problem. I got a temporary workaround though it might drop the img quality.

edit: I'm not gonna make an account for a new uploader right now. This one is called [_Heartless Machine God_](