Project

General

Profile

Another issue programming JN Micro

Added by bystander over 5 years ago

Hi folks,
I could not find anything related to this problem:
Win 7, Arduino 1.5.5, USBtinyISP programmer, jcw/ide-hardware installed, JN Micro selected in the Board list in IDE, USBtiny is selected in the Programmers list.
When trying to upload radioBlip2 sketch - it builds fine, produces a hex file, but then spits out this error:

Board at Com1 is not available

I am able to read/write fuses with avrdude from command line, did not try to upload a sketch, but it should work I guess. Something in the IDE is not set up properly. Any ideas please?


Replies (22)

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

Odd, which COM port is your programmer linked to? Do you have a terminal program connected to the programmer?

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

I don’t think the default Jee setup allows selection of the programmer - I see you are using USBtinyISP - I hope you have your voltages sorted.

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

Take a look at “C:–1.5.4r2\sketchbook\hardware\jeelabs\avr\boards.txt”

@ -1,6 +1,6@
jnmicro.name=JeeNode Micro
jnmicro.upload.tool=avrdude
-jnmicro.upload.protocol=arduino
+# jnmicro.upload.protocol=arduino // to permit programmer selection using Arduino IDE
jnmicro.upload.maximum_size=8192
jnmicro.upload.speed=19200

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO wrote:
> I don’t think the default Jee setup allows selection of the programmer - I see you are using USBtinyISP - I hope you have your voltages sorted.

  • voltages are ok I think as avrdude has no problem reading and writing

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO wrote:
> Take a look at “C:–1.5.4r2\sketchbook\hardware\jeelabs\avr\boards.txt”
>
> @ -1,6 +1,6@
> jnmicro.name=JeeNode Micro
> jnmicro.upload.tool=avrdude
> -jnmicro.upload.protocol=arduino
> +# jnmicro.upload.protocol=arduino // to permit programmer selection using Arduino IDE
> jnmicro.upload.maximum_size=8192
> jnmicro.upload.speed=19200

thanks for the pointer, I will check that tonight and report back

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO wrote:
> Odd, which COM port is your programmer linked to? Do you have a terminal program connected to the programmer?

not sure how to check the COM port; when firing avrdude commands I use something like bus-0:.0-0001—0x1781-0x0c9f to specify the port.
and no - I am not running a terminal program…

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

Mine is broken now, must be my recent move to 1.54r2.

I’m impressed that avrdude knows about bus-0:.0-0001—0x1781-0x0c9f.

UPDATE
I have added:
tools.avrdude.upload.pattern="{path}/{cmd}" "{serial.port}" "{build.path}/{build.project_name}.hex"
to my “C:–1.5.4r2\sketchbook\hardware\jeelabs\avr\platform.txt” file and now my USBASP is working again.

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

My voltage concern relates to the power arrangements on the USBTinyISP. At least on my USBTinyISP it is awkward to make sure that 5v doesn’t hit the RFM12B.

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO wrote:
> My voltage concern relates to the power arrangements on the USBTinyISP. At least on my USBTinyISP it is awkward to make sure that 5v doesn’t hit the RFM12B.

I think it does not. Power is supplied from USBtiny (power jumper set) via a diode to a Boost version of JN Micro. PWR voltage measured on JN is 4.5V. +3V measured on the board is 3.04V. So, everything looks tidy to me as far as electrons go… And avrdude can talk to the board.

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO,

I have commented out the line jnmicro.upload.protocol=arduino and it did not help. See attached screenshots.
I found some discrepancy between what .txt says and my environment:

After extracting, the following two files should exist…
C:.txt
C:84\empty.hex
- nope, I only have .txt and no bootloaders folder at all.

It seems like the git version https://github.com/jcw/ide-hardware is not in sync with the readme.txt.
Do I need to rename “attiny” folder to “tiny”? Where can I get the “bootloades” folder?

Thank you for your help so far!

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

Just verified - I can upload sketch manually via avrdude command line, so it is indeed the IDE not configured properly.
Could someone successfully running Arduino 1.5.x upload your C:folder?

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

Hi bystander, is your set-up as per http://jeelabs.org/2013/03/21/programming-the-jn%C2%B5-at-last/

In my experience the standard Jee setup doesn’t permit selection of different programmers and on Windows at least doesn’t allow compilations exceeding 4k (this issue isn’t Jee specific). You have my tweaks to be able the selection of a programmer which works for my USBASP but is not tested on USBTinyISP. My tweaks for the 4k problem are here: http://jeelabs.net/projects/hardware/wiki/JeeNode\_Micro in the section ‘Setting up the Tool Chain on Windows’.

I enclose my hardware directory but my path is: “C:–1.5.4r2\sketchbook\hardware”. I don’t store sketches in this path but it is the sketch path configured in the IDE. I do this to keep my Tiny extensions linked to my Arduino version.

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

P.S. com1 is the default serial port in avrdude.conf. I realise now that USBTinyISP and USBASP don’t actually use a virtual serial port they are just USB devices. Which prompts me to ask have you been able to select USBTinyISP from the IDE tools/programmer?

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO wrote:
> P.S. com1 is the default serial port in avrdude.conf. I realise now that USBTinyISP and USBASP don’t actually use a virtual serial port they are just USB devices. Which prompts me to ask have you been able to select USBTinyISP from the IDE tools/programmer?

Yes - I selected USBtiny from the IDE - see the screenshot above “JNM-3.png”

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

JohnO wrote:
—skip—
> I enclose my hardware directory but my path is: “C:–1.5.4r2\sketchbook\hardware”. I don’t store sketches in this path but it is the sketch path configured in the IDE. I do this to keep my Tiny extensions linked to my Arduino version.

Thank you, I will give it a try and see if this helps!

RE: Another issue programming JN Micro - Added by JohnO over 5 years ago

I’m surprised that your programmer and serial port options are not greyed out. Mine were and my serial still is greyed out. Perhaps it related to 1.55 IDE. I am using 1.54 release 2.

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

@JohnO - your hardware folder did not help, same error message.
Well, I will keep digging or just resort to command line upload when out of ideas…

RE: Another issue programming JN Micro - Added by wolfpackmars2 over 5 years ago

bystander - are you using shift+ctrl+U to upload your sketches from the IDE? (File->Upload using programmer)

If the ISP does not use a COM port to communicate, does it require drivers? Sorry, I don’t have experience with this device so this is the extent of my advice..

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

Yes, I use File > Upload using programmer. And I have USBtinyISP driver installed see attached screenshot.

RE: Another issue programming JN Micro - Added by wolfpackmars2 over 5 years ago

Do you have File->Preferences->Show verbose output during:upload checked? This would show the avrdude command the IDE attempts to use, along with the output (errors) produced by avrdude.

RE: Another issue programming JN Micro - Added by bystander over 5 years ago

Yes, I have both verbose checkboxes selected. However, logging stops after compilation - see the screenshot below.
I cannot figure out what avrdude is trying to execute.

RE: Another issue programming JN Micro - Added by wolfpackmars2 over 5 years ago

I’m out of ideas. What I found online from people having similar issues was resolved when the user started using “Upload Using Programmer”. The only other thing I could say to try is to test with Arduino IDE 1.0.5, to see if perhaps there is a problem between the beta IDE and using USBTinyISP

    (1-22/22)