Bootloading noob needs some help

Hello friends and foes,

I am using the Arduino IDE(1.6.8 ) to burn the Bootloader onto my 328PB processors, which was successful . Here lies my question, how do I know what bootloader is being put into the 328PB?

Does the IDE just burn one version of the bootloader onto every 328 chip? Or does it depend on which Board you have chosen when burning the Bootloader?

That said bootloader seems to be working well (I have a constant heartbeat on pin 17) but I am not sure what bootloader is going in there. Which leads to my next problem.

When I try to load a program via USB using a CH340Ghttp://www.dnclabs.com/wp-content/uploads/2015/03/Road_Warrior.png

I get an out of sync error.

Also what board should I have chosen when I am loading into a standalone arduino that I have bootleaded? Is it an Uno? Mini? Pro Mini?

I hope that was clear and I'm sure I am missing some information so let me know and I'll provide you with that information!

Thank you have a good day!

Read this discussion: http://www.gammon.com.au/forum/?id=11635

.

For a standalone Arduino - if programming via ISP, it doesn't matter which one you select as long as it's the same speed as the board you're using. If programming via Serial, after bootloading, select whichever board you selected when you bootloaded it.

For ATMega328PB - Consult the documentation for the '328PB core you're using to see what bootloader it put on it. We can't answer that, the IDE doesn't come with any support for the '328pb out of the box, so you must have added a third party hardware definition.

PERFECT exactly what I was looking for. Thank you Larry David! :o

Thank you as well DrAzzy, I assumed that but needed some confirmation!

Hi,

Welcome in the Club :)

Out of Sync means You can NOT reach the PBs Interface. What about installing the driver for the CH340?

Beside of the USB Interface Chip difference I'm sitting on the same problem like You.

EDIT (SOLVED): Anybody knows which file should I change to add support for the PB Chip?

Regards, Maverick

While uploading the program, you should choose the board that you used for bootloading.

With USB connection, have you connect the DTR to 328 pin with a 100nf capacitor? Also from 328P Reset to VCC via 10k resistor.

Arduino TX - USB adapter RX Arduino RX - USB adapter TX USB Adapter GND to common GND

@sarouje If You would read his first post, you would see he have done what you asked

@SuperCartman Which µController are You using? 328P like on Your shematics or the 328PB (which is different from 328P)?

I have actually tried with both but my µController is the 328PB

Hello,

Can You please upload some Images of Your real-life setup? Do You have got a Link to this board?

The standard Arduino IDE installation does NOT support the 328PB chip.

If You have got a bootloader on this chip, you could try UNO.

westfw wrote something about installing 328P bootloader to 328PB chip. As he does not answer questions for some days, You maybe write him a PM to get some response faster.

Regards, Maverick

Yeah so we made a pretty big error, the PB pinout will not match our board so we are moving back to a 328P!

If I test this out on a breadboard should it work? Or will the distances between RX/TX pins be too long and cause some interference?

Hi,

The 328 series of µcontroller are pretty robust, you can allmost not destroy it on 5V setups.

IMHO its pretty complicated to breadboard TQFP type µcontroller. You can try a TQFP to DIP adapter which working very well.

You can use at least 10-15cm cables for RX/TX it's not a problem. Shorter is better.

Regards, Maverick

SuperCartman: If I test this out on a breadboard should it work? Or will the distances between RX/TX pins be too long and cause some interference?

How much distance? If the distance is too long, have a look at RS485 protocol with MAX485 chip.

@sarouje He need a working solution for the 328P chip, not another source for a posibble error/problem...

Regards, Maverick

every one is trying for a working solution, some times to get a working solution need extra miles to go. As I said If the distance is more and cannot handle by normal Serial communication because of noise or whatever reason then go for RS485.

The TO asked if he can use cable which in his case is probably 10-30cm max. 40cm long.

Your "suggestion" is to offer him RS485 industrial solution which is designed for even higher distances up to several 100m and use additional chip.

sarouje: As I said If the distance is more and cannot handle by normal Serial communication because of noise or whatever reason then go for RS485.

Again, the TO wants to connect his µcontroller on a breadboard which is located on his desk on a breadboard. He dont want to connect two devices over 2 road blocks.

I dont know what's his setup is? OP said only long distance, not mentioned any actual distance.

Thanks guys all advice is good advice so no fighting BUT I mean like even 5cm, I have a DIP 328P to work with, I just want to test the logic on my board before designing a new PCB.

So SHOULD it work on a breadboard with Ill keep the cables short as possibla (3cm-10cm kinda thing)

yes serial communication will work in the range you are intending without any other peripherals. I do have several devices talk via serial which are more than 5cm. I use mostly SoftwareSerial, as Hardware serial is not enough for me. Forgot to tell, I am also using 328P. Also in the process of prototyping something in breadboard before moving to PCB.