Programming 3217 custom board

I have been trying to build a project using a custom board with a 3217 chip. It also has a 12V to 5V regulator. The board was working in protoboard config. For some reason it is not working. It responds with.

rsp_no_target_power

I am using a jtag2UPDI programmer. Is Vtarget a required input?

Please be more specific. "2317" is ambiguous; several semiconductor devices have that number as part of their product identifier. It's not clear what you're working with.

In general with custom boards it's also helpful to post a schematic and PCB layout.

OP might mean ATTINY3217 ...

Or he might be talking about the ancient H8S/2317. Or maybe he has a circuit with an OPA2317 in there, he somehow got hold of a 2317 bandpass filter, perhaps he omitted a '0' or 'I' and actually means a MCP23017/MCP23I17, he might have a PB2317 speaker element in a circuit, a PLD2317 fiber optic rx/tx module...who's to know, eh?

ATtiny3217 is a reasonable guess - so let's do some more guesses: Arduino IDE? Or some other upload tool? Schematic and board layout, shall we guess at those too?

1 Like

Well, being an Arduino site and under the subject heading of microcontrollers I thought it might have been obvious I was talking about an ATTINY3217. Schematic attached. Also using Arduino IDE.

Also please ignore the note and the transistors, they have been changed to FETS with different biasing.

Since there's no connection to the outside world apart from the "gear" header, I'm not surprised you don't get a response form the programmer.

Btw, seems kind of tricky to use the reset pin on the ATtiny for multiple purposes. Did you check the datasheet if that's ok and if it's guaranteed to be pulled up on startup, and that no external circuitry pulls it down?

I am using the ATtiny3217 on custom boards and have no problems programming them via UPDI. I am actually using the turbo upload option and it is blazingly fast.

I tried to look at your schematic but the resolution is so low I cannot read any pin numbers or connector labels. Could you please replace it with a slightly higher resolution picture?

You are using megaTinyCore?

Willem.

I have the UPDI pin set to GPIO. Using the JTAG2UPDI it supplies a high voltage (12V) pulse to enter programming mode. When programming the only wires connected are Gear_in, which is the the UPDI programming pin, 12V and GND.

I will try and upload a new schematic tonight.

Yes I am using megaTinycore.

Here is the schematic in PDF. Not sure how to insert it.

PIGPI_R3.pdf (144.2 KB)

Thanks for the pdf. Basically I wanted to see what you did with the UPDI pin. You actually answered that in post #9.

Out of curiosity, why do you use the UPDI pin as a GPIO when you have something like 16 other pins available? I actually like the UPDI MCU's because they use a single pin for programming which I can reserve for exactly that.

I add an onboard 470Ohm resistor in series and used a simple USB to serial adapter (based on the CH330 chip) at max speed as a programmer. Zero problems.

Willem

Sorry for the delay in responding, I have been moving house.

The reason for using th UPDI pin is the number of available input pins on the device. I have +12V, GND, 1 analog input and 1 digital output.

As far as I know your suggestion to use the 4K7 resistor will only work if the chip is in UPDI mode.

Hope you are settling into your new place soon.

Not a 4K7 resistor, a 470.

How many input pins do you need? As I said there are 16 addition pins available on you schematic, all either input or output.

Willem.

Settling into a disaster zone....as most who move would be aware.

I have 4 external pins. 12V, GND, Analog in and Digital out. Unfortunately thats all I have available hence the use of the UPDI as a GPIO.

I am not sure why it is not working. The 12V HV pulse is there so it should be setting it into programming mode. I am pretty new to programming but this shouldn't be this hard.

Is the use of the 470R resistor applicable when it is in GPIO mode? If so could you point me to a circuit that you use?

You are using JTAG2UPDI, are you using the HVUPDI add-on that has been confirmed to work?
It has been reported that some ATtiny accepts UPDI commands after giving an HV pulse at an arbitrary timing, and some have to correctly send UPDI commands from the HV pulse at a specific timing.

It is the same programmer I was using on the breadboard prototype and it worked fine. It also worked previously with the custom board. All of a sudden it is coming up with the error. Supposedly the Arduino IDE and the JTAG2UPDI software accounts for the timing.

The programmer I am using is the one designed and built by Dlloyd. I have 2 of them and they are both doing the same thing.

Did you use the same revision as the chip currently on the board in the prototype?
If so, the programmer may not be the cause.
By the way, you can see a bit of the discussion about HVUPDI I mentioned above here.

Yes, the chip is from the same batch.

I have read that before. Not sure why Microchip is making life so hard. Why develop a chip but not provide a programmer (at a decent price) to do the programming.

My understanding is all you should need is PWR, GND and UPDI connected, apply the HV pulse of what ever pulse width and all is good. Something is not gelling here. It might just be me.