Solved, thanks @Frank_fjs, it was my jury-rigged wiring!
C:\Users\rthorntn>avrdude -c usbasp -p m328p -v -F
avrdude: Version 5.10, compiled on Jan 19 2010 at 10:45:23
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\WinAVR-20100110\bin\avrdude.conf"
Using Port : lpt1
Using Programmer : usbasp
AVR Part : ATMEGA328P
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 65 5 4 0 no 1024 4 0 3600 3600 0xff 0xff
flash 65 6 128 0 yes 32768 128 256 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
efuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
lock 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
calibration 0 0 0 0 no 1 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : usbasp
Description : USBasp, http://www.fischl.de/usbasp/
avrdude: auto set sck period (because given equals null)
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
avrdude: AVR device initialized and ready to accept instructions
avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATMEGA328P is 1E 95 0F
avrdude done. Thank you.
avrdude -c usbasp -p m328p -e -U flash:w:saturn_controller_demux_v0.9.ino.with_bootloader_atmega328p_8000000L.hex -U lfuse:w:0xe2:m
It may be some issue with drivers, or maybe you have messed the fuses of the microcontroller. I use this command in OpenBSD and it works a treat.Thanks @pacoarcade, I tried your command, the m328p isn't being detected anymore, who knows what I've done.
As I said, I was able to successfully program it once with saturn_controller_demux_RMAF_Retro_Bit_Fix.ino_atmega328p_8000000L.hex
It hasn't been detected since.
All versions of the code work on all versions of the PCB. Writing the code to the chip could not cause the behavior that you are seeing. If reset disable was set on the high fuse that would cause the chip not to be written to, otherwise it's probably a problem with your programming setup.@Frank_fjs @Arthrimus @pacoarcade I'm going to take a look at this again today.
Could saturn_controller_demux_RMAF_Retro_Bit_Fix.ino_atmega328p_8000000L.hex be causing it, I built the SMT version, is this version definitely OK for it?
I just used the Frank instructions "FUSE BITS/SETTINGS TAB - Tick the Low Fuse Write checkbox. Type in E2."